<Koin custom lifetime of service> I am trying to s...
# stackoverflow
u
Koin custom lifetime of service I am trying to setup/extend Koin so that it respects the lifetime of a Ktor request. I would like to inject a new service instance per request and share it throughout, but destroy it at request end. Has anyone already tried this? Is it possible to extend Koin to handle this scenario or should I just build something on my own? Ideally I'm looking to create something like this: single { CoolServiceImpl() } factory { CoolerServiceImpl() } request { CoolestServiceImpl() } // THIS