提交 fd3ec008 authored 作者: 董吉利's avatar 董吉利

Merge branch 'dev' of D:\IDEAworkspace\aroad with conflicts.

上级 dc11f388
......@@ -27,6 +27,11 @@
<!--<groupId>org.springframework.boot</groupId>-->
<!--<artifactId>spring-boot-starter-amqp</artifactId>-->
<!--</dependency>-->
<dependency>
<groupId> org.springframework.boot </groupId>
<artifactId>spring-boot-configuration-processor </artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-redis</artifactId>
......
......@@ -908,9 +908,9 @@ public class EsUtil_fanshe {
* @Author: dongjili
* @Date: 2019/5/14 0014
*/
public static List<Basehighwayalldata> queryHighWayFiler(String lxbh,double zh, String type) throws Exception {
public static List<Basehighwayalldata> queryHighWayFiler(String lxbh,double zh, String index, String type, int start, int row) throws Exception {
//搜索数据
SearchRequestBuilder searchRequestBuilder = getClient().prepareSearch("basehighwayalldata").setTypes(type).setFrom(0).setSize(1);
SearchRequestBuilder searchRequestBuilder = getClient().prepareSearch(index).setTypes(type).setFrom(start).setSize(row);
//isNotBlank(str) 等价于 str != null && str.length > 0 && str.trim().length> 0(去掉字符串两端的多余的空格的长度)
if (org.apache.commons.lang.StringUtils.isNotBlank(lxbh)) {
//multiMatchQuery多个字段匹配某一个值
......
......@@ -35,7 +35,7 @@ public class ReadElasticsearch {
System.out.println(basehighwayalldata);
}*/
//通过路线编号匹配,查询字段在起点桩号和止点桩号之间范围查询
List<Basehighwayalldata> basehighwayalldataArrayList = EsUtil_fanshe.queryHighWayFiler("G342", 405, "2018");
List<Basehighwayalldata> basehighwayalldataArrayList = EsUtil_fanshe.queryHighWayFiler("G342", 405, "basehighwayalldata", "2018", 0, 2000000000);
for (Basehighwayalldata basehighwayalldata : basehighwayalldataArrayList) {
System.out.println(basehighwayalldata);
}
......
......@@ -2,3 +2,8 @@
spring:
profiles:
active: dev
connect:
host1: 192.168.7.200
host2: 192.168.7.210
host3: 192.168.7.220
port: 9300
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论