Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Enhancement] Add more data obtained through rcon #89

Open
Minecraftschurli opened this issue Jun 22, 2024 · 4 comments
Open

[Enhancement] Add more data obtained through rcon #89

Minecraftschurli opened this issue Jun 22, 2024 · 4 comments

Comments

@Minecraftschurli
Copy link

Currently this tool relies solely on querying the server to provide stats. My idea is to add functionality to obtain additional metrics when rcon access is available. Although this would require either configuration or detection of the server brand and version to know what commands to use this could be useful for having tps and mspt stats.

@itzg
Copy link
Owner

itzg commented Jun 22, 2024

Thanks, this is an interesting enhancement idea.

...however, RCON responds with unstructured text and worse still doesn't even include newline delimiters.

I'll have to give this some more thought, but off hand I'm not comfortable with introducing RCON here since the design of mc-monitor is focused on the official structured protocol responses.

I would prefer to see a separate tool introduced that uses rcon and is extensible in a way that it knows how to parse the text responses for the respective commands, and export those accordingly.

@Minecraftschurli
Copy link
Author

Looking at the code NeoForge and Forge have a fix in place for the missing newlines and looking at another prometheus data provider for minecraft it can be retrieved via the tps command (/forge tps / /neoforge tps) and parsed via regex (see: https://github.com/dirien/minecraft-prometheus-exporter/blob/main/pkg/exporter/exporter.go#L160)

@itzg
Copy link
Owner

itzg commented Jun 23, 2024

Thanks for the extra info -- that's really good to know.

I was going to say, another tool probably provides what you need. Why not just use that?

@Minecraftschurli
Copy link
Author

the problem is that those tools are all currently missing neoforge support and expose way more metrics than I need which could put strain on the server always running the commands

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants