Add a way to specify no-tracking in query time to prevent caching when not needed
Closed this issue · 0 comments
MikeAlhayek commented
Sometimes, we may want to query large data. We know that this data is for special purposes like reporting. So it does not need any internal caching. Internal caching can be very expensive when dealing with a large data set.
adding
public class QueryContext
{
public bool WithNoTracking { get; set; }
}
and passing this to the query can allow us to exclude the data from being cached.