Works with Mongo database (named "acolyte") resolved using given driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
Works with Mongo database (named "acolyte") resolved using given driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
a previously initialized connection
the function applied to initialized Mongo DB
import reactivemongo.api.DB import acolyte.reactivemongo.AcolyteDSL // handler: ConnectionHandler val s: Future[String] = AcolyteDSL withConnection(handler) { con => AcolyteDSL withDB(con) { db => val d: DefaultDB = db "Result" } }
withFlatDB[T]
AcolyteDSL.withConnection
Works with Mongo database (named "acolyte") resolved using given driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
Works with Mongo database (named "acolyte") resolved using given driver
initialized using Acolyte for ReactiveMongo
(should not be used with other driver instances).
Driver and associated resources are released
after the function f
the result Future
is completed.
the connection manager parameter (see ConnectionManager)
the function applied to initialized Mongo DB
import reactivemongo.api.DB import acolyte.reactivemongo.AcolyteDSL // handler: ConnectionHandler val s: Future[String] = AcolyteDSL withDB(handler) { db => val d: DB = db "Result" }
withFlatDB[A,B]
AcolyteDSL.withConnection
Works with Mongo database (named "acolyte") resolved using given driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
Works with Mongo database (named "acolyte") resolved using given driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
a previously initialized connection
the function applied to initialized Mongo DB
import reactivemongo.api.DB import acolyte.reactivemongo.AcolyteDSL // handler: ConnectionHandler val s: Future[String] = AcolyteDSL withConnection(handler) { con => AcolyteDSL withDB(con) { db => val d: DefaultDB = db Future.successful("Result") } }
withFlatDB[T]
AcolyteDSL.withConnection
Works with Mongo database (named "acolyte") resolved using given driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
Works with Mongo database (named "acolyte") resolved using given driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
the connection manager parameter (see ConnectionManager)
the function applied to initialized Mongo DB
import reactivemongo.api.DB import acolyte.reactivemongo.AcolyteDSL // handler: ConnectionHandler val s: Future[String] = AcolyteDSL withFlatDB(handler) { db => val d: DefaultDB = db Future.successful("Result") }
withDB[A,B]
AcolyteDSL.withFlatConnection
Functions to work with MongoDB (provided driver functions).