KMongo

object KMongo

Creates MongoClient instances of the official MongoDB Kotlin coroutine driver, configured with the KMongo object mapping.

Functions

Link copied to clipboard
fun createClient(): MongoClient

Creates a MongoClient instance with default connection string (localhost).

fun createClient(connectionString: ConnectionString): MongoClient
fun createClient(connectionString: String): MongoClient

Creates a MongoClient with the given connection string.

fun createClient(settings: MongoClientSettings): MongoClient

Creates a MongoClient with the given settings (the codec registry is updated with KMongo mapping).