I have several Repository classes that are mapped as InRequestScope so that they are cached for the lifetime of the request.
These Repository classes are injected with a CacheClass that is mapped as InSingletonScope.
It seems that because the Repository class references an object that is in the InSingletonScope, the Repository class is also considered as being in the InSingletonScope, despite it being mapped as InRequestScope.
How can I force Ninject to dispose of the Repository classes at the end of the Request whilst also keeping the CacheClass in cache for injection into the next Repository class created during the next request?
Seems like this should be simple to do but I can't get my head around it.