Reputation: 539
In the docs, it states,
The @JdbcRepository annotation accepts an optional string value which represents the name of the connection or datasource in a multiple datasource scenario. By default Micronaut Data will look for the default datasource.
However, I don't see any such value parameter within this annotation - only the dialect. Is this an error or am I missing something?
Upvotes: 2
Views: 475
Reputation: 5739
Here is a complete snippet, using dialect & datasource:
@Repository(value = "inventoryDataSource")
@JdbcRepository(dialect = Dialect.ORACLE)
public interface PhoneRepository extends CrudRepository<Phone, Integer> {
Optional<Phone> findByAssetId(@NotNull Integer assetId);
}
A patch/pull request has been submitted with correction to the documentation.
Upvotes: 1
Reputation: 27220
Is this an error or am I missing something?
I think it is the former. If you file an issue at https://github.com/micronaut-projects/micronaut-data/issues we can take care of that.
Thanks for the feedback!
Upvotes: 1