@ -22,6 +22,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass ;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean ;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty ;
import org.springframework.boot.autoconfigure.jdbc.DataSourceTransactionManagerAutoConfiguration ;
import org.springframework.boot.autoconfigure.jdbc.JdbcTemplateAutoConfiguration ;
import org.springframework.context.annotation.Configuration ;
import org.springframework.context.annotation.Import ;
@ -30,6 +31,7 @@ import org.springframework.data.jdbc.repository.config.EnableJdbcRepositories;
import org.springframework.data.jdbc.repository.config.JdbcConfiguration ;
import org.springframework.data.jdbc.repository.config.JdbcRepositoryConfigExtension ;
import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations ;
import org.springframework.transaction.PlatformTransactionManager ;
/ * *
* { @link EnableAutoConfiguration Auto - configuration } for Spring Data ' s JDBC Repositories .
@ -39,16 +41,17 @@ import org.springframework.jdbc.core.namedparam.NamedParameterJdbcOperations;
* providing an { @link AbstractJdbcConfiguration } subclass .
*
* @author Andy Wilkinson
* @author Stephane Nicoll
* @since 2.1 .0
* @see EnableJdbcRepositories
* /
@SuppressWarnings ( "deprecation" )
@Configuration ( proxyBeanMethods = false )
@ConditionalOnBean ( NamedParameterJdbcOperations . class )
@ConditionalOnBean ( { NamedParameterJdbcOperations . class , PlatformTransactionManager . class } )
@ConditionalOnClass ( { NamedParameterJdbcOperations . class , AbstractJdbcConfiguration . class } )
@ConditionalOnProperty ( prefix = "spring.data.jdbc.repositories" , name = "enabled" , havingValue = "true" ,
matchIfMissing = true )
@AutoConfigureAfter ( JdbcTemplateAutoConfiguration . class )
@AutoConfigureAfter ( { JdbcTemplateAutoConfiguration . class , DataSourceTransactionManagerAutoConfiguration . class } )
public class JdbcRepositoriesAutoConfiguration {
@Configuration ( proxyBeanMethods = false )