-
Notifications
You must be signed in to change notification settings - Fork 377
DATAJDBC-100 Namespaces / @EnableJdbcRepositories #6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Adds the @EnableJdbcRepositories annotation, which when used on a Spring configuration enables scanning packages for JDBC-repositories.
|
|
||
| private NamedParameterJdbcOperations findOrCreateJdbcOperations() { | ||
|
|
||
| return getNamedParameterJdbcOperations() // |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove nesting by using Optionals.firstNonEmpty(…)-
| } | ||
|
|
||
| private Optional<NamedParameterJdbcOperations> getNamedParameterJdbcOperations() { | ||
| return getBean(NamedParameterJdbcOperations.class, "namedParameterJdbcOperations"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Names as constants. Align with Boot defaults, i.e. Operations -> Template. Types should stay with Operations.
| /* | ||
| * (non-Javadoc | ||
| * @see * @see org.springframework.data.repository.config | ||
| .RepositoryConfigurationExtensionSupport#getRepositoryFactoryBeanClassName() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Weird line break.
Changed bean names to those used by Boot. Extracted constants for bean names (in the production classes and test classes separately). Renamed an existing constant to avoid confusion. Fixed some garbled non-javadoc comments.
Adds the @EnableJdbcRepositories annotation, which when used on a Spring configuration enables scanning packages for JDBC repositories. Original pull request: #6.
|
That's merged. |
Adds the @EnableJdbcRepositories annotation, which when used on a Spring configuration enables scanning packages for JDBC-repositories.
Issue: https://jira.spring.io/browse/DATAJDBC-100