mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-12 07:04:52 +09:00
Every RCON command makes an auto paused Factorio server run one tick, so subspace_storage's 1 s inventory update and 5 s ping, plus a statistics_exporter gather on every Prometheus scrape, kept a server with nobody online running at about 1.3 ticks per second. The instance now records the auto_pause server setting it was started with and exposes autoPaused, true while that setting is on and no players are online, along with an autoPauseChanged hook. subspace_storage skips its timers while paused and sends a ping and inventory as soon as a player joins. statistics_exporter gathers once after the game pauses and keeps serving those values until it resumes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Clusterio Statistics Exporter Plugin
Plugin exporting item production, fluid production, kill count, entity build and pollution statistics to the Prometheus integration to Clusterio.
Installation
Run the following commands in the folder Clusterio is installed to:
npm install @clusterio/plugin-statistics_exporter
npx clusteriocontroller plugin add @clusterio/plugin-statistics_exporter
Substitute clusteriocontroller with clusteriohost or clusterioctl if this a dedicate host or ctl installation respectively.
Instance Configuration
statistics_exporter.command_timeout
Timeout in seconds to wait for the statitics gathering command to the Factorio server return the result. If the timeout is exceeded the previous collected results are returned instead. Normally the command returns immediatly with the data, but if the RCON interface is overloaded then the command may take too long to timely answer the metrics collection request.
Defaults to 1.