Merge remote-tracking branch 'origin/pr/1460'

master
Andrew DeMaria 4 years ago
commit 3a98471f74
No known key found for this signature in database
GPG Key ID: 0A3F5E91F8364EDF
  1. 3
      airsonic-main/src/main/java/org/airsonic/player/spring/DatabaseConfiguration.java

@ -10,6 +10,7 @@ import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.DependsOn;
import org.springframework.context.annotation.Profile;
import org.springframework.jdbc.datasource.DataSourceTransactionManager;
import org.springframework.jdbc.datasource.DriverManagerDataSource;
@ -33,12 +34,14 @@ public class DatabaseConfiguration {
@Bean
@Profile("legacy")
@DependsOn("liquibase")
public DaoHelper legacyDaoHelper(DataSource dataSource) {
return new LegacyHsqlDaoHelper(dataSource);
}
@Bean
@ConditionalOnMissingBean
@DependsOn("liquibase")
public DaoHelper daoHelper(DataSource dataSource) {
return new GenericDaoHelper(dataSource);
}

Loading…
Cancel
Save