Files
factorio-clusterio/plugins/statistics_exporter
bbassieandClaude Fable 5 a25f8c8611 Fix lua lint warnings reported by emmylua
The largest source was compat.lua returning the setmetatable call
directly, which made emmylua infer the module type from the metatable
rather than the LibCompat class, hiding every field from consumers.

The remaining fixes are nil guards on gui element and character
accesses, type annotations for research_sync's script data and
player_auth's rcon arguments, casts where the api's read/write union
types are wider than the values at runtime, and scoped diagnostic
disables for the vendored json.lua and the version fallback code that
touches apis removed from the current typedefs.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-27 22:25:24 +00:00
..
2023-02-22 15:30:51 +01:00

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.