https://kotlinlang.org logo
#ktor
Title
# ktor
d

David Marko

07/09/2018, 8:16 PM
Hello, what is a proper concept of DI in ktor? For example I’m using kmongo ... how to make database as a singleton object and share it within entire application, all modules etc?
d

Deactivated User

07/09/2018, 8:23 PM
Ktor doesn’t force you to use dependency injection. Buy you can use it. There is a sample using guice here: https://github.com/ktorio/ktor-samples/tree/master/feature/guice
n

Nikky

07/10/2018, 9:14 AM
3 Views