Categorygithub.com/Scalingo/go-utils/mongo
modulepackage
1.4.0
Repository: https://github.com/scalingo/go-utils.git
Documentation: pkg.go.dev

# README

Package mongo v1.4.0

Useful tools around MongoDB.

mongo.DefaultDatabaseName = "default-database"
mongo.Session(logger.Default())

Create a new session based on MONGO_URL, connection will be initialized only once, so you can call it everytime your need a session.

Will wait until database is available.

If no MONGO_URL is defined, will use mongodb://localhost:27017/ + DefaultDatabaseName

# Packages

No description provided by the author
No description provided by the author

# Functions

No description provided by the author
Session tries to open a session against a MongoDB database in a loop.

# Variables

No description provided by the author