Performance lag when injecting high-frequency script data?

Hi everyone!
I’m currently working on a custom MODX Revolution project where I’m building a specialized “Manager” dashboard to track mobile gaming analytics. I’m essentially trying to use MODX as a backend to log and visualize live data packets from an iOS environment.

I’ve been using a delta exec tool to handle the client-side script execution on the mobile device, which then pushes data via a custom Snippet I’ve set up as a REST endpoint. The scripts are running great on the device, but I’ve hit a bit of a bottleneck on the server side. Whenever the delta exec tool starts firing off high-velocity updates, the MODX parser seems to struggle with the concurrent database writes, and I’m seeing my server’s CPU usage spike into the red.

Has anyone here dealt with resource management when connecting high-frequency external tools to a MODX backend? I’m trying to figure out if there’s a better way to “buffer” these incoming requests—perhaps using a custom table instead of standard modResource objects—to keep the manager responsive while the scripts are active. I’m also a bit concerned about whether the way the delta exec tool handles its networking headers might be clashing with MODX’s internal CSRF protection or session handling. I’d love to hear if any of the power users here have experience with integrating mobile-side automation with MODX without the frontend becoming sluggish!

I’m struggling to understand the exact setup.
Could you elaborate more about the process you implemented?

  • What data gets sent from the mobile devices?
    Does it contain any information (like a cookie) that requires a MODX instance to make permission checks?
  • So you save the data in a resource now? Where exactly? Or do you create a new resource for every “high-frequency update” from the mobile devices?
    (Without knowing the details here, it seems to me that a custom database table would definitively be better suited for this.)
  • How and when does the MODX dashboard widget update the data that it’s showing?
  • Where in this whole process is the MODX parser involved?