Base solution for your next web application
Open Closed

UserTokenExpirationWorker not cleaning AbpUserTokens table #7887


User avatar
0
timmackey created

per ABP.NET Boilerplate documentation User token removal period the following code should remove expired tokens from the AbpUserTokens table within a minute of app startup if I understand correctly.

    public override void PreInitialize()
    {
        Configuration.BackgroundJobs.CleanUserTokenPeriod = 1000 * 60 ; // 1 minute
    }

However, the table contains hundreds of rows with ExpireDate more than a month old after the website has been running for more than 1 minute.


4 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team

    hi timmackey

    What is your abp version? The features you mentioned need abp≥v4.7.0 Make sure that Background Jobs is not disabled.

  • User Avatar
    0
    timmackey created

    Abp v4.9.0 ANZ v7.2.3 Core/Angular Background jobs are not disabled. I use them in my app.

  • User Avatar
    0
    maliming created
    Support Team

    It seems that UserTokenExpirationWorker needs to disable the multi-tenant filter, otherwise it is impossible to delete the data with the TenantId. I will fix it, thank you for your feedback.

    https://github.com/aspnetboilerplate/aspnetboilerplate/issues/4957

  • User Avatar
    0
    ismcagdas created
    Support Team

    This issue is closed because it has not had recent activity for a long time.