Skip to content

Commit 5a8fca6

Browse files
committed
添加druid连接池,Flyway 数据库版本控制,及单元测试实例
1 parent 4191e34 commit 5a8fca6

File tree

20 files changed

+499
-118
lines changed

20 files changed

+499
-118
lines changed

common-utils/pom.xml

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@
4040
<groupId>org.springframework.boot</groupId>
4141
<artifactId>spring-boot-starter-data-redis</artifactId>
4242
</dependency>
43-
<dependency>
43+
<!-- <dependency>
4444
<groupId>org.springframework.boot</groupId>
4545
<artifactId>spring-boot-starter-data-elasticsearch</artifactId>
4646
<optional>true</optional>
47-
</dependency>
47+
</dependency>-->
4848
<dependency>
4949
<groupId>org.yaml</groupId>
5050
<artifactId>snakeyaml</artifactId>
@@ -95,13 +95,6 @@
9595
<artifactId>spring-web</artifactId>
9696
<scope>compile</scope>
9797
</dependency>
98-
<dependency>
99-
<groupId>org.elasticsearch</groupId>
100-
<artifactId>elasticsearch</artifactId>
101-
<version>5.6.8</version>
102-
<optional>true</optional>
103-
</dependency>
104-
10598
<dependency>
10699
<groupId>org.apache.commons</groupId>
107100
<artifactId>commons-lang3</artifactId>
@@ -122,6 +115,20 @@
122115
<artifactId>spring-kafka</artifactId>
123116
<version>2.1.10.RELEASE</version>
124117
</dependency>
118+
<dependency>
119+
<groupId>org.apache.httpcomponents</groupId>
120+
<artifactId>httpcore</artifactId>
121+
<version>4.4.9</version>
122+
</dependency>
123+
<dependency>
124+
<groupId>org.apache.httpcomponents</groupId>
125+
<artifactId>httpclient</artifactId>
126+
<version>4.5.5</version>
127+
</dependency>
128+
<dependency>
129+
<groupId>org.apache.httpcomponents</groupId>
130+
<artifactId>httpasyncclient</artifactId>
131+
</dependency>
125132
<!-- kafka end -->
126133
</dependencies>
127134
<distributionManagement>
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
1+
/*
12
package com.cskit.utils.esutils;
23
34
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;
45
56
import java.io.Serializable;
67
8+
*/
79
/**
810
* @author Micro
911
* @Title: ES操作
1012
* @Package com.cskit.utils.esutils
1113
* @Description: ES操作
1214
* @date 2018/7/20 16:47
13-
*/
15+
*//*
16+
1417
public interface EsTemplateService<T extends Serializable, ID extends Serializable> extends ElasticsearchRepository<T, ID> {
1518
}
19+
*/

controlplat-service/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,11 @@
4141
<artifactId>persistence-api</artifactId>
4242
<version>1.0.2</version>
4343
</dependency>
44-
<dependency>
44+
<!--<dependency>
4545
<groupId>org.springframework.data</groupId>
4646
<artifactId>spring-data-elasticsearch</artifactId>
4747
<version>2.1.1.RELEASE</version>
48-
</dependency>
48+
</dependency>-->
4949
</dependencies>
5050
<repositories>
5151
<repository>

controlplat-service/src/main/java/com/cskit/controlplatservice/interfaces/UserInfoProvider.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package com.cskit.controlplatservice.interfaces;
22

3-
import com.cskit.controlplatservice.models.CtrlAccountModel;
3+
//import com.cskit.controlplatservice.models.CtrlAccountModel;
44
import com.cskit.controlplatservice.models.UserInfo;
55
import com.cskit.utils.responseinfo.PageInfo;
66
import com.cskit.utils.responseinfo.ResponseData;
@@ -68,13 +68,13 @@ public interface UserInfoProvider {
6868
@GetMapping("/getuserinfobypage")
6969
ResponseData<PageInfo<UserInfo>> getUserInfoByPage(@RequestParam(value = "pageno", defaultValue = "1", required = false) int pageno, @RequestParam(value = "pagesize", defaultValue = "5") int pagesize);
7070

71-
@ApiOperation(value = "ES获取单个信息", notes = "ES获取单个信息", tags = {"ElasticSearch"})
72-
@GetMapping("/getaccountfromes")
73-
ResponseData<CtrlAccountModel> getAccountFromES(@RequestParam(value = "ctrlaccountid", defaultValue = "7", required = true) Long ctrlaccountid);
71+
// @ApiOperation(value = "ES获取单个信息", notes = "ES获取单个信息", tags = {"ElasticSearch"})
72+
// @GetMapping("/getaccountfromes")
73+
// ResponseData<CtrlAccountModel> getAccountFromES(@RequestParam(value = "ctrlaccountid", defaultValue = "7", required = true) Long ctrlaccountid);
7474

75-
@ApiOperation(value = "获取ES分页数据", notes = "演示ES分页示例", tags = {"ElasticSearch"})
76-
@GetMapping("/getpageaccountfromes")
77-
PageInfo<CtrlAccountModel> getPageAccountFromES(@RequestParam(value = "pagenum", defaultValue = "0") int pagenum, @RequestParam(value = "pagesize", defaultValue = "2") int pagesize);
75+
// @ApiOperation(value = "获取ES分页数据", notes = "演示ES分页示例", tags = {"ElasticSearch"})
76+
// @GetMapping("/getpageaccountfromes")
77+
// PageInfo<CtrlAccountModel> getPageAccountFromES(@RequestParam(value = "pagenum", defaultValue = "0") int pagenum, @RequestParam(value = "pagesize", defaultValue = "2") int pagesize);
7878

7979
@ApiOperation(value = "接收内容", notes = "接收内容", tags = {"kafka"})
8080
@GetMapping("/kafkareceive")

0 commit comments

Comments
 (0)