ToolsResource Health Monitor

Resource Health Monitor

The Resource Health Monitor helps server administrators keep a close eye on script performance, memory usage, and restart trends across every QBCore resource. Use it to proactively detect runaway scripts, identify bottlenecks, and keep uptime stable during peak player hours.

What the monitor tracks

  • Runtime performance – CPU time, tick rate, and execution spikes for each resource.
  • Memory footprint – Track growth over time and receive alerts for potential leaks.
  • Restart history – Automatic restart counts, reasons, and player impact summaries.
  • Anomaly detection – Highlight resources that behave differently after updates or new configuration changes.

This tool is designed for production servers that want automated insights without manual log digging.

Dashboard overview

WidgetDescription
Live Metrics StreamReal-time CPU and memory usage with configurable thresholds.
Resource LeaderboardSort resources by highest load, restart count, or memory delta.
Incident TimelineVisual history of warnings, soft restarts, and manual interventions.
Optimization TipsCurated guidance based on the metrics collected for each resource.

Setting up the monitor

  1. Install the agent – Deploy the lightweight collector to your server’s resources folder.
  2. Grant permissions – Ensure it can read resource states via GetNumResources() and QBCore exports.
  3. Configure alerts – Choose Discord webhooks or in-game notifications for threshold breaches.
  4. Define maintenance windows – Let the tool know when automated restarts are allowed.
Config.ResourceHealth = {
  enableAgent = true,
  sampleInterval = 5000,
  cpuThreshold = 70,
  memoryThreshold = 120,
  alertWebhook = 'https://discord.com/api/webhooks/...',
  maintenanceWindow = {
    start = '04:00',
    stop = '05:00',
    timezone = 'UTC'
  }
}

Workflow examples

Stabilize a crashing script

  1. Review the Incident Timeline to find repeated restarts.
  2. Open the affected resource to compare CPU and memory graphs.
  3. Enable safe mode restarts so the script reloads with reduced tick rate while you patch it.
  4. Export the report to share with your development team.

Prepare for a content update

  • Benchmark new resources on a staging server.
  • Compare baseline metrics with production data to identify regressions.
  • Use the Optimization Tips to adjust timers, loops, and caching strategies before go-live.

Integrations

  • Discord notifications for instant awareness of high-impact issues.
  • Prometheus compatible metrics endpoint for long-term storage.
  • Maintenance Planner link to schedule downtime directly from flagged incidents.

Keeping resources healthy is the backbone of a reliable QBCore server. The Resource Health Monitor gives you the visibility needed to react before players notice problems.