Tenant Routing Info performance optimization
This commit is contained in:
parent
31124311a3
commit
2c8b938540
@ -42,9 +42,8 @@ public class DefaultTenantRoutingInfoService implements TenantRoutingInfoService
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public TenantRoutingInfo getRoutingInfo(TenantId tenantId) {
|
public TenantRoutingInfo getRoutingInfo(TenantId tenantId) {
|
||||||
Tenant tenant = tenantService.findTenantById(tenantId);
|
TenantProfile tenantProfile = tenantProfileCache.get(tenantId);
|
||||||
if (tenant != null) {
|
if (tenantProfile != null) {
|
||||||
TenantProfile tenantProfile = tenantProfileCache.get(tenant.getTenantProfileId());
|
|
||||||
return new TenantRoutingInfo(tenantId, tenantProfile.isIsolatedTbRuleEngine());
|
return new TenantRoutingInfo(tenantId, tenantProfile.isIsolatedTbRuleEngine());
|
||||||
} else {
|
} else {
|
||||||
throw new RuntimeException("Tenant not found!");
|
throw new RuntimeException("Tenant not found!");
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user