Skip to content

Commit 8dfee0a

Browse files
committed
DATAES-373 - bump elasticsearch version to 5.5.0
1 parent ffdc573 commit 8dfee0a

File tree

8 files changed

+13
-16
lines changed

8 files changed

+13
-16
lines changed

pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<properties>
2020
<commonscollections>3.2.1</commonscollections>
2121
<commonslang>2.6</commonslang>
22-
<elasticsearch>5.4.0</elasticsearch>
22+
<elasticsearch>5.5.0</elasticsearch>
2323
<springdata.commons>2.0.0.BUILD-SNAPSHOT</springdata.commons>
2424
</properties>
2525

@@ -91,7 +91,7 @@
9191
<dependency>
9292
<groupId>org.apache.logging.log4j</groupId>
9393
<artifactId>log4j-core</artifactId>
94-
<version>2.6.2</version>
94+
<version>2.8.2</version>
9595
</dependency>
9696

9797
<!-- Jackson JSON Mapper -->

src/test/java/org/springframework/data/elasticsearch/core/DefaultResultMapperTests.java

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@
4141
import org.springframework.data.elasticsearch.core.aggregation.AggregatedPage;
4242
import org.springframework.data.elasticsearch.core.mapping.SimpleElasticsearchMappingContext;
4343
import org.springframework.data.elasticsearch.entities.Car;
44+
45+
import static java.util.Arrays.asList;
4446
import static org.hamcrest.Matchers.*;
4547
import static org.junit.Assert.*;
4648
import static org.mockito.Mockito.*;
@@ -72,12 +74,7 @@ public void shouldMapAggregationsToPage() {
7274
when(searchHits.iterator()).thenReturn(new ArrayIterator(hits));
7375
when(response.getHits()).thenReturn(searchHits);
7476

75-
Aggregation aggregationToReturn = createCarAggregation();
76-
Aggregations aggregations = mock(Aggregations.class);
77-
Iterator<Aggregation> iter = Collections.singletonList(aggregationToReturn).iterator();
78-
79-
when(aggregations.iterator()).thenReturn(iter).thenReturn(iter);
80-
when(aggregations.get("engine")).thenReturn(aggregationToReturn);
77+
Aggregations aggregations = new Aggregations(asList(createCarAggregation()));
8178
when(response.getAggregations()).thenReturn(aggregations);
8279

8380
//When
@@ -86,7 +83,7 @@ public void shouldMapAggregationsToPage() {
8683
//Then
8784
page.hasFacets();
8885
assertThat(page.hasAggregations(), is(true));
89-
assertThat(page.getAggregation("engine").getName(), is("Diesel"));
86+
assertThat(page.getAggregation("Diesel").getName(), is("Diesel"));
9087
}
9188

9289
@Test
@@ -185,8 +182,8 @@ private String createJsonCar(String name, String model) {
185182

186183
private Map<String, SearchHitField> createCarFields(String name, String model) {
187184
Map<String, SearchHitField> result = new HashMap<>();
188-
result.put("name", new SearchHitField("name", Arrays.asList(name)));
189-
result.put("model", new SearchHitField("model", Arrays.asList(model)));
185+
result.put("name", new SearchHitField("name", asList(name)));
186+
result.put("model", new SearchHitField("model", asList(model)));
190187
return result;
191188
}
192189

src/test/java/org/springframework/data/elasticsearch/core/ElasticsearchTemplateParentChildTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
package org.springframework.data.elasticsearch.core;
1717

1818
import static org.elasticsearch.common.xcontent.XContentFactory.*;
19-
import static org.elasticsearch.index.query.QueryBuilders.*;
19+
import static org.elasticsearch.join.query.JoinQueryBuilders.hasChildQuery;
2020
import static org.hamcrest.Matchers.*;
2121
import static org.junit.Assert.*;
2222

src/test/resources/test-home-dir/modules/lang-expression/plugin-descriptor.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
description=Lucene expressions integration for Elasticsearch
2323
#
2424
# 'version': plugin's version
25-
version=5.4.0
25+
version=5.5.0
2626
#
2727
# 'name': the plugin name
2828
name=lang-expression
@@ -37,7 +37,7 @@ classname=org.elasticsearch.script.expression.ExpressionPlugin
3737
java.version=1.8
3838
#
3939
# 'elasticsearch.version': version of elasticsearch compiled against
40-
elasticsearch.version=5.4.0
40+
elasticsearch.version=5.5.0
4141
### optional elements for plugins:
4242
#
4343
# 'has.native.controller': whether or not the plugin has a native controller

src/test/resources/test-home-dir/modules/lang-groovy/plugin-descriptor.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
description=Groovy scripting integration for Elasticsearch
2323
#
2424
# 'version': plugin's version
25-
version=5.4.0
25+
version=5.5.0
2626
#
2727
# 'name': the plugin name
2828
name=lang-groovy
@@ -37,7 +37,7 @@ classname=org.elasticsearch.script.groovy.GroovyPlugin
3737
java.version=1.8
3838
#
3939
# 'elasticsearch.version': version of elasticsearch compiled against
40-
elasticsearch.version=5.4.0
40+
elasticsearch.version=5.5.0
4141
### optional elements for plugins:
4242
#
4343
# 'has.native.controller': whether or not the plugin has a native controller

0 commit comments

Comments
 (0)