florentchauveau / freeswitch_exporter

Prometheus exporter for FreeSWITCH
MIT License
24 stars 6 forks source link

Freeswitch registration count #1

Open AvinashAnchula opened 2 years ago

AvinashAnchula commented 2 years ago

Does the exporter collects freeswitch registration count? Looks like currently it doesn't.

florentchauveau commented 2 years ago

Hello,

It does not at the moment, but it could be added easily.

Which command are you using on the CLI to fetch that information?

AvinashAnchula commented 2 years ago

This is the command fs_cli -x "show registrations". Do we need to add another entry in the collector.go same as below.

image
florentchauveau commented 2 years ago

Yes, but the output needs to be parsed properly.

Could you provide me some samples? With different results. One with no results, one with some results and another one with different results.

Thanks

AvinashAnchula commented 1 year ago

Command : fs_cli -x "show registrations" Output fields : reg_user,realm,token,url,expires,network_ip,network_port,network_proto,hostname,metadata

Output is present in this format and metadata field is the "count of registrations" at the end.