Returns unmanaged driver.
Returns unmanaged driver. You will have to close it by yourself.
Works with connection with options appropriate for a driver initialized using Acolyte for ReactiveMongo (should not be used with other driver instances).
Works with connection with options appropriate for a driver
initialized using Acolyte for ReactiveMongo
(should not be used with other driver instances).
Connection is closed after the result Future
is completed.
the connection manager parameter (see ConnectionManager)
the function applied to initialized driver
import reactivemongo.api.MongoConnection import acolyte.reactivemongo.AcolyteDSL // handler: ConnectionHandler val s: Future[String] = AcolyteDSL.withConnection(handler) { con => val c: MongoConnection = con "Result" }
Works with MongoDB driver configured with Acolyte handlers.
Works with MongoDB driver configured with Acolyte handlers.
Driver and associated resources are released
after the function f
the result Future
is completed.
the function applied to initialized driver
// handler: ConnectionHandler val s: Future[String] = withDriver { d => val initedDriver: MongoDriver = d "Result" }
Functions to work with driver.