question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

I can't use Second Level Cache with ABP

See original GitHub issue

I cannot implement the Second Level Cache library because it needs to use the service provider and it is not available in the method that configures the DbContext Configuration.Modules.AbpEfCore().AddDBContext<MyDbContext>(options => ....... ..

And something like this is needed Configuration.Modules.AbpEfCore().AddDBContext<MyDbContext>((serviceProvider, options) => .......

Can you please help me to find a solution so inside the configurer I can implement this builder.UseSqlServer(connectionString).AddInterceptors(serviceProvider.GetRequiredService<SecondLevelCacheInterceptor>());

Issue Analytics

  • State:open
  • Created 6 months ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
ismcagdascommented, Jun 23, 2023

Yes, it is not same.

1reaction
ismcagdascommented, Jun 1, 2023

I will try to prepare a sample but it might take some time.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Second level cache not working in Hibernate + Spring + ...
The second level cache is not working because you are not fetching data by ID (see this link When and how to use...
Read more >
Caching | Documentation Center | ABP.IO
NET Core's documentation to see how to switch to Redis or another cache provider. ... You can use the CacheName attribute on the...
Read more >
Hibernate Second-Level Cache
A guide to the Hibernate second-level cache and how to use it in practice.
Read more >
Hibernate EHCache - Hibernate Second Level Cache
Hibernate Second Level cache providers include EHCache and Infinispan, but EHCache is more popular and we will use it for our example project....
Read more >
Hibernate - Enable and Implement First and Second Level ...
In your code, enable the first level cache for a specific session by calling the setCacheable(true)method on the Query object before executing ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found