Class RoutingDataSource<SEED>

  • All Implemented Interfaces:
    Wrapper, CommonDataSource, DataSource, org.springframework.beans.factory.InitializingBean

    public class RoutingDataSource<SEED>
    extends org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource
    DataSource implementation that routes AbstractRoutingDataSource.getConnection() calls to one of various target DataSources based on a lookup key.
    Since:
    2022-08-16
    Version:
    1.0.6
    Author:
    fantasticmao
    See Also:
    AbstractRoutingDataSource.determineTargetDataSource(), RoutingSeed
    • Method Detail

      • determineCurrentLookupKey

        @Nullable
        protected Object determineCurrentLookupKey()
        Specified by:
        determineCurrentLookupKey in class org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource