percona / mongodb_exporter

A Prometheus exporter for MongoDB including sharding, replication and storage engines
Apache License 2.0
1.19k stars 424 forks source link

added respective .go files for setup.sh and init-shard.sh #727

Open RISHIKESHk07 opened 1 year ago

RISHIKESHk07 commented 1 year ago

PMM-XXXX (optional, if ticket reported)


Once all checks pass and the code is ready for review, please add pmm-review-exporters team as the reviewer. That would assign people from the review team automatically. Report any issues on our Forum.

RISHIKESHk07 commented 1 year ago

@BupycHuk any additional changes ?

BupycHuk commented 1 year ago

Hi @RISHIKESHk07 build script are failing with following errors:

Error: docker/scripts/setup.go:28:20: undefined: mongo.Cmd
Error: docker/scripts/setup.go:29:3: missing type in composite literal
Error: docker/scripts/setup.go:43:20: undefined: mongo.Cmd
Error: docker/scripts/setup.go:44:3: missing type in composite literal
Error: docker/scripts/setup.go:57:58: undefined: mongo.Cmd
Error: docker/scripts/setup.go:62:6: main redeclared in this block
Error:  docker/scripts/init-shard.go:20:6: other declaration of main
Error: docker/scripts/init-shard.go:63:2: mongodb31Resolved declared but not used
Error: docker/scripts/init-shard.go:64:2: mongodb32Resolved declared but not used
Error: docker/scripts/init-shard.go:65:2: mongodb33Resolved declared but not used
Error: docker/scripts/init-shard.go:88:12: cmd.Stdin.Write undefined (type io.Reader has no field or method Write)
Error: docker/scripts/setup.go:57:58: too many errors

We need to put these two apps to separate folders and fix imports.