【8.3.4】【tenant】增加一个不进行租户切换的逻辑

master
stylefeng 2025-05-05 23:04:20 +08:00
parent c32ca70ffa
commit 58beeaf0e6
2 changed files with 13 additions and 0 deletions

View File

@ -44,4 +44,12 @@ public interface TenantSwitchApi {
*/ */
<T> T changeTenant(TenantSwitchInfo tenantSwitchInfo, Supplier<T> action); <T> T changeTenant(TenantSwitchInfo tenantSwitchInfo, Supplier<T> action);
/**
*
*
* @author fengshuonan
* @since 2025/5/5 23:02
*/
<T> T doNoTenantChange(Supplier<T> action);
} }

View File

@ -28,4 +28,9 @@ public class DefaultTenantSwitchImpl implements TenantSwitchApi {
return action.get(); return action.get();
} }
@Override
public <T> T doNoTenantChange(Supplier<T> action) {
return action.get();
}
} }