0
sumitshah created
Hi,
We need to completely disable the background jobs in our project. we have tried :
Configuration.BackgroundJobs.IsJobExecutionEnabled = false;
in the WebCoreModule.cs, Core Project >> CoreModule.cs but checking the queries in the SQL profiler, the below query is getting fired almost every 2 seconds
exec sp_executesql N'SELECT TOP(@__p_1) [t].[Id], [t].[CreationTime], [t].[CreatorUserId], [t].[IsAbandoned], [t].[JobArgs], [t].[JobType], [t].[LastTryTime], [t].[NextTryTime], [t].[Priority], [t].[TryCount]
FROM [AbpBackgroundJobs] AS [t]
WHERE ([t].[IsAbandoned] = 0) AND ([t].[NextTryTime] <= @__Now_0)
ORDER BY [t].[Priority] DESC, [t].[TryCount], [t].[NextTryTime]',N'@__p_1 int,@__Now_0 datetime2(7)',@__p_1=1000,@__Now_0='2019-12-09 16:21:02.3694549'
could you please let us know how to completely stop these background jobs.
2 Answer(s)
-
0
Did you override IBackgroundJobStore? Because it should be replaced with NullBackgroundJobStore If IsJobExecutionEnabled=false
https://github.com/aspnetboilerplate/aspnetboilerplate/blob/c33224544a18b00512162a489bc55c3ca194431f/src/Abp/AbpKernelModule.cs#L216-L223
-
0
Thank you, we were able to successfully disable the job