add a prometheus-text-file-exporter parameter
Have you checked borgbackup docs, FAQ, and open GitHub issues?
Yes
Is this a BUG / ISSUE report or a QUESTION?
Feature request
Describe the problem you're observing.
when running borg it is only possible to parse the output from --stats to get a more deeper look into metrics.
It would be nice to have an parameter --prometheus-exporter <file> to write all the metrics to the file. This way we do not need to run any additional command and have it persistent on the disk.
Some commands also have json output capability, so maybe you can use that.
That is a good idea. Maybe I can use the json-exporter for this. Not sure how good the metrics are, but I will have a look.
Does that mean you don't want to provide it in the first place, but would rather suggest the use of other tools?
Yes, guess we rather provide generic exporting (like json) than supporting misc. more specialised formats (? no idea about what prometheus need) directly.
I am very fine with json, but could we add an parameter like --json-export file.json so I have the normal output of the stats ind the job and my monitoring will use the json.
IIRC, if you use --log-json, you'll get all log output as json.
Some commands have a --json (or --json-lines) option, so their (non-logging) output is made in json format.
yes, but then I would have either the stats in a nice format or json, but never both.
If you do not like my suggestion, please go ahead an close it. I am ok with the current situation.