mpihlak / mongoproxy

Lightweight proxy to collect MongoDb client metrics
MIT License
42 stars 8 forks source link

Fix replicaset parsing for newer versions of MongoDB #32

Closed alekseiplotnikov closed 1 year ago

alekseiplotnikov commented 1 year ago

Fix replica set parsing for MongoDB versions 5.0+, which have helloOk "operation" instead of hosts as in previous versions. Currently replicaset is not parsed correctly and label is empty. After the change mongoproxy is confirmed to be working as expected in our test environment, replicaset label is populated.