public class DynamicDataSource
extends org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource
| 构造器和说明 |
|---|
DynamicDataSource() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
afterPropertiesSet() |
void |
bindDataSourceToTenant(java.lang.String tenant,
javax.sql.DataSource ds) |
protected java.lang.Object |
determineCurrentLookupKey() |
static java.lang.String |
getDataSourceKey() |
determineTargetDataSource, getConnection, getConnection, isWrapperFor, resolveSpecifiedDataSource, resolveSpecifiedLookupKey, setDataSourceLookup, setDefaultTargetDataSource, setLenientFallback, setTargetDataSources, unwrappublic void afterPropertiesSet()
afterPropertiesSet 在接口中 org.springframework.beans.factory.InitializingBeanafterPropertiesSet 在类中 org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSourceprotected java.lang.Object determineCurrentLookupKey()
determineCurrentLookupKey 在类中 org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSourcepublic static java.lang.String getDataSourceKey()
public void bindDataSourceToTenant(java.lang.String tenant,
javax.sql.DataSource ds)
throws DynamicDataSourceException,
java.sql.SQLException
DynamicDataSourceExceptionjava.sql.SQLException