Replies: 1 comment 2 replies
-
In this case, you can resolve |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have a project where I need different instances of
DomainService
implementations to manage different configurations.At first, I used an injected
IServiceProvider
to generate my instance when needed. It worked.After a refactor, I decided to use the provided property
Volo.Abp.Domain.Services.DomainService.ServiceProvider
to avoid having to inject aIServiceProvider
. This provided property is howeverObsolete
and tells we need to useLazyServiceProvider
.But
LazyServiceProvider
uses a cache (AbpLazyServiceProvider : CachedServiceProviderBase
). Why does it use a cache, I can't get different instance of the same service to manage different data. If it is by design, why is there no alternative to avoid using a cache?Beta Was this translation helpful? Give feedback.
All reactions