Open Closed

No tenant found after updating to 8.1 #7020


User avatar
0
rivz created
  • ABP Framework version: v8.1.0
  • UI Type: Blazor Server
  • Database System: EF Core (PostgreSQL)
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes
  • Exception message and full stack trace:
  • Steps to reproduce the issue: after updating from 8.0.3 to 8.1 i have issues with loging in with tenant. When i log in with default admin with no tenant, i can log in and do everything. When i go to the SaaS - tenants menu and try to "log in with tenant" i get the following error :
10:08:30 WRN] Tenant not found!
Volo.Abp.BusinessException: Tenant not found!
   at Volo.Abp.MultiTenancy.TenantConfigurationProvider.GetAsync(Boolean saveResolveResult)
   at Volo.Abp.AspNetCore.MultiTenancy.MultiTenancyMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
[10:08:30 WRN] Code:Volo.AbpIo.MultiTenancy:010001
[10:08:30 WRN] Details:There is no tenant with the tenant id or name: 3a091d98-a19f-e032-bf9e-327aeaeb6099

Same thing happens when i try to log in from the login page. The tenant is in database (SaasTenants and AbpTenats(since i stareted with framework but changed to commercial)), redis cahce cleared, cookies cleared. It looks like the authserver finds all the login info needed, but somehow sends the wrong info to blazorserver and fails. (There is no tenant with the tenant id or name: 3a091d98-a19f-e032-bf9e-327aeaeb6099)

as you can see, authserver accepts that this tenant exists, but when i try to log in, i get the error.

when using locally with safari i get different error, doesent happen when i use it in docker, then i will get the no tenant error.

[14:37:29 WRN]'.AspNetCore.Correlation.z52e57ZZkOyZbkXJmmQ4btSergAyQ9GbJUYKr5PXDzU' cookie not found.
[14:37:29 INF] Error from RemoteAuthentication: Correlation failed..
[14:37:29 ERR] An unhandled exception has occurred while executing the request.
Microsoft.AspNetCore.Authentication.AuthenticationFailureException: An error was encountered while handling the remote login.
 ---> Microsoft.AspNetCore.Authentication.AuthenticationFailureException: Correlation failed.
   --- End of inner exception stack trace ---
   at Microsoft.AspNetCore.Authentication.RemoteAuthenticationHandler`1.HandleRequestAsync()
   at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
   at Volo.Abp.AspNetCore.Security.AbpSecurityHeadersMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
   at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.<>c__DisplayClass2_0.<<CreateMiddleware>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at Volo.Abp.AspNetCore.Tracing.AbpCorrelationIdMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
   at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.<>c__DisplayClass2_0.<<CreateMiddleware>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at Microsoft.AspNetCore.Localization.RequestLocalizationMiddleware.Invoke(HttpContext context)
   at Microsoft.AspNetCore.RequestLocalization.AbpRequestLocalizationMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
   at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.InterfaceMiddlewareBinder.<>c__DisplayClass2_0.<<CreateMiddleware>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context)

i think i did the migration correctly


13 Answer(s)
  • User Avatar
    0
    Anjali_Musmade created
    Support Team Support Team Member

    Hello,

    please check the migration guide https://docs.abp.io/en/abp/latest/Migration-Guides/Abp-8_1

    thanks

  • User Avatar
    0
    rivz created

    yes i have done that, its something else.

  • User Avatar
    0
    Anjali_Musmade created
    Support Team Support Team Member

    Hello,

    Have you check in Incognito mode?

  • User Avatar
    0
    rivz created

    Yes, i have cleared caches, tried incognito mode, different browsers, everything basic you can think of.

  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    Can you share a simple project that can reproduce the problem with me? shiwei.liang@volosoft.com

    I will check it. thanks.

  • User Avatar
    0
    rivz created

    I cant share my project with you and i think i cant recreate it also since at first we used abp framework but migrated to commercial about a month ago, also the project is older than a year with many different additions, so its nearly impossible to recreate it. Is there anything else i can provide? All was working well with 8.0.3 and after "abp update latest" to 8.1, cant login with tenants.

  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    Can you change the log level to debug, then clean the logs and try again? Share the logs(authserver, httpapi.host, blazorserver) with me. thanks

  • User Avatar
    0
    rivz created

    Since they are long, i will send them do your email

  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    Hi,

    I didn't find the cause. Can I check it remotely via Zoom?

  • User Avatar
    0
    rivz created

    yes you can check it trough zoom

  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    Hi,

    Join the meeting https://us05web.zoom.us/j/5929668302?pwd=UXl2M2RUeG5PazVSY2ZCOW1NMUxtZz09

  • User Avatar
    0
    liangshiwei created
    Support Team Fullstack Developer

    This is because of the cache prefix key. You need to use the same key for the projects.

  • User Avatar
    0
    rivz created

    Thank you very much! Appreciate it

Made with ❤️ on ABP v9.1.0-preview. Updated on December 10, 2024, 06:38