To connect our apps into MongoDB Atlas with simple golang apps using mgo library and adding CRUD feature as a simple performance test
- Change config file inside
configs/configs.json
with appropriate information about your MongoDB Atlas URI and other info uri
is connection string used to connect into your MongoDB Atlas databaseperformancetest
will do simple CRUD to your mongoDB Atlas database if you set this value astrue
showresult
will show a result for each CRUD function if you set this value astrue
collectiontest
is your collection name to test CRUD feature- To test it just run
go run main.go
or with file config specifiedgo run main.go -config yourconfigfilelocation
.