Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

EF CoreFilters + AbpSession.Use #7647


User avatar
0
kworkme created

I am using AbpSession.UserId inside EF Core filter. However, I am trying to use impersonation with AbpSession.Use, but with no luck.

My current understanding is that EF Core filters are created at start of session. UserId gets read and stored in the filter at that time. When I use AbpSession.Use(2,2) method, I can see AbpSession.UserId is updated. However, it would seem EF Core filter does not re-retrieve the UserId.

How can I make EF Core filters update with the most recent UserId?


2 Answer(s)