diff options
author | Alexander Alexeev | 2016-12-13 02:31:29 +0700 |
---|---|---|
committer | Alexander Alexeev | 2016-12-13 02:31:29 +0700 |
commit | f1384a874ee415bccba77c8218dbfe63ec67f1bd (patch) | |
tree | 2b41a2053aaf8b4981f6c0b0381d288721213a63 /juick-server/src/main/java/com/juick/configuration | |
parent | 9e00161260a402cf322f4b964956bb72d20cd4ef (diff) |
mysql updater
Diffstat (limited to 'juick-server/src/main/java/com/juick/configuration')
-rw-r--r-- | juick-server/src/main/java/com/juick/configuration/DataConfiguration.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/juick-server/src/main/java/com/juick/configuration/DataConfiguration.java b/juick-server/src/main/java/com/juick/configuration/DataConfiguration.java index 535755c2..d9ef7d38 100644 --- a/juick-server/src/main/java/com/juick/configuration/DataConfiguration.java +++ b/juick-server/src/main/java/com/juick/configuration/DataConfiguration.java @@ -1,5 +1,6 @@ package com.juick.configuration; +import com.juick.database.MySqlUpdater; import com.juick.service.search.SearchService; import org.apache.commons.dbcp2.BasicDataSource; import org.springframework.context.annotation.*; @@ -58,6 +59,14 @@ public class DataConfiguration implements TransactionManagementConfigurer { } @Bean + public MySqlUpdater updater() { + return new MySqlUpdater( + jdbcTemplate(), + transactionManager(), + "update.sql"); + } + + @Bean public SearchService emptySearchService() { return new SearchService() { @Override |