- ABP Framework version: v3.3.2
- UI type: Angular
- DB provider: EF Core
- Tiered (MVC) or Identity Server Separated (Angular): yes
- Exception message and stack trace:
- Steps to reproduce the issue:"
Hi, I got tenant Id not found error when working on a module project:
[21:13:26 INF] Request starting HTTP/2.0 OPTIONS https://localhost:44343/api/partners-buddy/category-groups?skipCount=0&maxResultCount=10
[21:13:26 INF] CORS policy execution successful.
[21:13:26 INF] Request finished in 3.2625ms 204
[21:13:26 INF] Request starting HTTP/2.0 GET https://localhost:44343/api/partners-buddy/category-groups?skipCount=0&maxResultCount=10
[21:13:26 INF] CORS policy execution successful.
[21:13:26 INF] Successfully validated the token.
[21:13:26 ERR] Connection ID "18230571301796315688", Request ID "80000229-0002-fd00-b63f-84710c7967bb": An unhandled exception was thrown by the application.
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)
at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass5_1.<<UseMiddlewareInterface>b__1>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at Volo.Abp.AspNetCore.Security.Claims.AbpClaimsMapMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass5_1.<<UseMiddlewareInterface>b__1>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context)
at Volo.Abp.AspNetCore.Tracing.AbpCorrelationIdMiddleware.InvokeAsync(HttpContext context, RequestDelegate next)
at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass5_1.<<UseMiddlewareInterface>b__1>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at Microsoft.AspNetCore.Server.IIS.Core.IISHttpContextOfT`1.ProcessRequestAsync()
[21:13:26 INF] Request finished in 10.4021ms 500
Steps to reproduces:
- Create a module project template
- Create a list with Abp Suite
- set the Multi-Tenancy to true
- create a new tenant and login to that tenant
- Access the list view just created above
public static class MultiTenancyConsts
{
/* Enable/disable multi-tenancy in a single point
* to test your module with multi-tenancy.
*/
public const bool IsEnabled = true;
}
I also tried login with incognito mode, got the same issue, so cache/cookies is not the root cause
Could you please help us take a look?
12 Answer(s)
-
0
Hi nhontran
You're on an outdated version currently. Can you please try on newer versions?
You can follow Migrations Guides: https://docs.abp.io/en/abp/latest/Migration-Guides/Index
-
0
Hi @enisn, we could not upgrade the version for now.
Is there a work around to fix this issue on the version 3.3.2?
-
0
Can we check it remotely?
https://zoom.us/j/97802929466?pwd=NUNMaFNZeUJaY3liZkpRc0N6clhQZz09
-
0
Hi @maliming, sure
-
0
I will test it locally and tell you the result.
-
0
hi nhontran
Can you share your project with me? liming.ma@volosoft.com
-
0
Hi @maliming, sure, let me zip and send it to you
-
0
Hi @maliming, Sent.
-
0
hi
I have confirmed the problem. Thanks
-
0
hi nhontran
Try to add
SaasEntityFrameworkCoreModule
to yourSHDP.PartnersBuddy.HttpApi.Host
<PackageReference Include="Volo.Abp.SettingManagement.EntityFrameworkCore" Version="3.3.2" /> typeof(SaasEntityFrameworkCoreModule)
-
0
https://github.com/abpframework/abp/pull/11076
-
0
Hi @maliming, the issue has been resolved :)
Thanks a lot for your support.