As kong option parser doesn't have an option not to split quoted arguments by comma and just strips all quotes from arguments, there is no chance to specify comma-containing cluster URIs as they will be treated as separated multiple targets ( https://github.com/percona/mongodb_exporter/pull/653#issuecomment-1894399492 ).
This version improves URI splitting algorythm as folows:
URI prefixed my mongodb:// or mongodb+srv:// can contain comma-separated hosts without schema part and will be treated as a cluster. Any other separated host or a cluster must by prefixed by mongodb:// to be treated as a separate target.
If no one host in the line is prefixed by scheme part, all they will be treated as separate targets
As kong option parser doesn't have an option not to split quoted arguments by comma and just strips all quotes from arguments, there is no chance to specify comma-containing cluster URIs as they will be treated as separated multiple targets ( https://github.com/percona/mongodb_exporter/pull/653#issuecomment-1894399492 ).
This version improves URI splitting algorythm as folows:
URI prefixed my mongodb:// or mongodb+srv:// can contain comma-separated hosts without schema part and will be treated as a cluster. Any other separated host or a cluster must by prefixed by mongodb:// to be treated as a separate target.
If no one host in the line is prefixed by scheme part, all they will be treated as separate targets
[ ] Links to related pull requests (optional).