![JAR search and dependency download from the Maven repository](/logo.png)
io.github.dhi13man.spring.datasource.annotations.TargetSecondaryDataSources Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of spring-multi-data-source Show documentation
Show all versions of spring-multi-data-source Show documentation
To mitigate Spring's limitations with multiple data sources in a single service, this
library provides two custom annotations in Java that automatically generate all the required
bean definition configurations and package-segregated repositories, for each data source.
The newest version!
package io.github.dhi13man.spring.datasource.annotations;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* Annotation to create copies of the repositories in the relevant packages, and autoconfigure them
* to use the relevant secondary data sources.
*
* Will generate all relevant boilerplate code and beans.
*/
@Target({ElementType.METHOD})
@Retention(RetentionPolicy.CLASS)
public @interface TargetSecondaryDataSources {
/**
* The array of {@link TargetSecondaryDataSource} annotations.
*
* @return the array of {@link TargetSecondaryDataSource} annotations
*/
TargetSecondaryDataSource[] value();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy