Amazon AWS Elasticsearch Integration Test failures

Description

  1. Create an AWS Elasticsearch domain

  2. Set the environment property for tests to point at the AWS URL

  3. Run the tests. I ran them from the command line

I can attach the test results if someone needs those. Or, they can run the tests and see the results.

You also see "Previously opened session wasn't closed"

Environment

Windows 10, Java 8, Amazon Elasticsearch, t2.micro, also tested with m3.medium, Single VM cluster

Activity

Show:
Joe
March 30, 2016, 2:06 AM
Edited

Results :

Failed tests:
DeleteByQueryIT.canDeleteByQuery:104 unexpected element(s):<['Galore', 'Kidd']> in <['Brand', 'Hergesheimer', 'Galore', 'Kidd']>
DeleteByQueryMultiTenancyIT.deleteByQueryOnlyAffectsEntitiesOfCurrentTenant:151 unexpected element(s):<['Kidd', 'Galore']> in <['Brand', 'Kidd', 'Galore', 'Hergesheimer']>
PolymorphicAssociationTest.testPolymorphicAssociation:37->changeLevel3Name:73 expected:<1> but was:<3>

Tests in error:
DeleteByQueryIT.deleteTestData:67->SearchTestBase.openSession:81 » IllegalState
ElasticsearchAnalyzerIT>SearchTestBase.setUp:46 » Search Could not create mapp...
ElasticsearchAnalyzerIT>SearchTestBase.setUp:46 » Search Could not create mapp...
ElasticsearchAnalyzerIT>SearchTestBase.setUp:46 » Search Could not create mapp...
ElasticsearchAnalyzerIT>SearchTestBase.setUp:46 » Search Could not create mapp...
ElasticsearchAnalyzerIT>SearchTestBase.setUp:46 » Search Could not create mapp...
ElasticsearchAnalyzerIT>SearchTestBase.setUp:46 » Search Could not create mapp...
ElasticsearchSpatialIT.testBoundingBoxQuery:139 » Search HSEARCH400007: Elasti...
ElasticsearchSpatialIT.deleteTestData:58->SearchTestBase.openSession:81 » IllegalState
ElasticsearchSpatialIT.testGeoDistanceQuery:102 » Search HSEARCH400007: Elasti...
ElasticsearchSpatialIT.deleteTestData:58->SearchTestBase.openSession:81 » IllegalState
SpatialQueryingJPATest.testDoubleIndexedDistanceProjection:302 » Persistence o...
SpatialQueryingJPATest.testDistanceSort:128 » Persistence org.hibernate.search...
SpatialQueryingJPATest.testDistanceSortWithMaxResult:250 » Persistence org.hib...
SpatialQueryingJPATest.testDistanceProjection:70 » Persistence org.hibernate.s...
SpatialQueryingJPATest.testDistanceSort2:194 » Persistence org.hibernate.searc...
DSLTest.testBoolean:376 » Search HSEARCH400007: Elasticsearch request failed.
...
DSLTest.testBooleanWithOnlyNegationQueries:438 » Search HSEARCH400007: Elastic...
DSLTest.testBooleanWithoutScoring:410 » Search HSEARCH400007: Elasticsearch re...
SpatialDSLTest.testSpatialHashQueries:98 » Search HSEARCH400007: Elasticsearch...
SpatialDSLTest.testSpatialRangeQueries:65 » Search HSEARCH400007: Elasticsearc...
FacetFilteringTest.testDiscreteFacetDrillDown:56 » Search HSEARCH400007: Elast...
FacetFilteringTest.testDiscreteFacetDrillDownWithMultiFacetSelect:180 » Search
FacetFilteringTest.testMultipleFacetDrillDown:98 » Search HSEARCH400007: Elast...
FacetFilteringTest.testRangeFacetDrillDown:150 » Search HSEARCH400007: Elastic...
RangeFacetingTest.testDateRangeFaceting:314 » Search HSEARCH400007: Elasticsea...
RangeFacetingTest.testRangeBelowWithFacetSelection:215 » Search HSEARCH400007:...
WebShopTest.testSimulateClient:71 » Search HSEARCH400007: Elasticsearch reques...
SortTest.setUp:71->SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsear...
SortTest.tearDown:88 » Session Session is closed!
SortTest.setUp:71->SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsear...
SortTest.tearDown:88 » Session Session is closed!
FilterOnDirectoryTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elastics...
MassIndexTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch re...
MassIndexTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch re...
MassIndexTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch re...
MassIndexUsingManualFlushTest>SearchTestBase.setUp:46 » Search HSEARCH400007: ...
OptimizeTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch req...
SessionTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch requ...
SessionTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch requ...
SessionTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch requ...
DynamicShardingTest.testDeletion:120->insertAnimals:154 » AssertionFailure Exc...
DynamicShardingTest>SearchTestBase.tearDown:51 » Search HSEARCH400007: Elastic...
DynamicShardingTest.setUp:55->SearchTestBase.setUp:46 » IllegalState there sho...
DynamicShardingTest.testDynamicShardsAreTargetingInQuery:93->insertAnimals:154 » AssertionFailure
DynamicShardingTest>SearchTestBase.tearDown:51 » Search HSEARCH400007: Elastic...
DynamicShardingTest.setUp:55->SearchTestBase.setUp:46 » IllegalState there sho...
ShardsTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch reque...
ShardsTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch reque...
ShardsTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsearch reque...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialIndexingTest>SearchTestBase.setUp:46 » Search HSEARCH400007: Elasticsea...
SpatialSearchSortByDistanceAndPagingTest.setUp:92->SearchTestBase.setUp:46 » Search
SpatialSearchSortByDistanceAndPagingTest.setUp:92->SearchTestBase.setUp:46 » Search
SpatialSearchSortByDistanceAndPagingTest.setUp:92->SearchTestBase.setUp:46 » Search
SpatialSearchSortByDistanceAndPagingTest.setUp:92->SearchTestBase.setUp:46 » Search
SpatialSearchSortByDistanceAndPagingTest.setUp:92->SearchTestBase.setUp:46 » Search

Tests run: 442, Failures: 3, Errors: 72, Skipped: 1

Sanne Grinovero
March 30, 2016, 10:07 AM

Our testsuite expects that:

  • there's no schema defined yet

  • there's no data

From a quick glance on the error messages, I suspect that this might have run on a non-clean Elasticsearch node? For example you might have run the testsuite twice on the same instance?
Could you try to rest it.

Joe
March 30, 2016, 12:18 PM

Howdy,

The above test was against a fresh AWS elasticsearch instance. In order to verify....

I just ran the following steps and received the results below. Note: the below listing just shows the result of the first 3-4 test classes.

  1. tore down my AWS Elasticsearch instance and rebuilt it

  2. verified there were no indicies in the AWS console

  3. ran "mvn verify"

{{
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running org.hibernate.search.backend.elasticsearch.test.CombiningLuceneAndElasticsearchIT
Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 35.392 sec - in org.hibernate.search.backend.elasticsearch.test.CombiningLuceneAndElasticsearchIT
Running org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryIT
Tests run: 2, Failures: 1, Errors: 1, Skipped: 0, Time elapsed: 10.673 sec <<< FAILURE! - in org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryIT
canDeleteByQuery(org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryIT) Time elapsed: 10.669 sec <<< FAILURE!
java.lang.AssertionError: unexpected element(s):<['Galore', 'Kidd']> in <['Brand', 'Hergesheimer', 'Galore', 'Kidd']>
at org.fest.assertions.Fail.failure(Fail.java:228)
at org.fest.assertions.Assert.failure(Assert.java:149)
at org.fest.assertions.ItemGroupAssert.failureIfUnexpectedElementsFound(ItemGroupAssert.java:107)
at org.fest.assertions.ItemGroupAssert.assertContainsOnly(ItemGroupAssert.java:79)
at org.fest.assertions.ObjectGroupAssert.containsOnly(ObjectGroupAssert.java:65)
at org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryIT.canDeleteByQuery(DeleteByQueryIT.java:104)

canDeleteByQuery(org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryIT) Time elapsed: 10.67 sec <<< ERROR!
java.lang.IllegalStateException: Previously opened Session wasn't closed!
at org.hibernate.search.test.DefaultTestResourceManager.openSession(DefaultTestResourceManager.java:145)
at org.hibernate.search.test.SearchTestBase.openSession(SearchTestBase.java:81)
at org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryIT.deleteTestData(DeleteByQueryIT.java:67)

Running org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryMultiTenancyIT
Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 10.579 sec <<< FAILURE! - in org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryMultiTenancyIT
deleteByQueryOnlyAffectsEntitiesOfCurrentTenant(org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryMultiTenancyIT) Time elapsed: 10.576 sec <<< FAILURE!
java.lang.AssertionError: unexpected element(s):<['Kidd', 'Galore']> in <['Brand', 'Kidd', 'Galore', 'Hergesheimer']>
at org.fest.assertions.Fail.failure(Fail.java:228)
at org.fest.assertions.Assert.failure(Assert.java:149)
at org.fest.assertions.ItemGroupAssert.failureIfUnexpectedElementsFound(ItemGroupAssert.java:107)
at org.fest.assertions.ItemGroupAssert.assertContainsOnly(ItemGroupAssert.java:79)
at org.fest.assertions.ObjectGroupAssert.containsOnly(ObjectGroupAssert.java:65)
at org.hibernate.search.backend.elasticsearch.test.deletebyquery.DeleteByQueryMultiTenancyIT.deleteByQueryOnlyAffectsEntitiesOfCurrentTenant(DeleteByQueryMultiTenancyIT.java:151)
}}

Sanne Grinovero
March 30, 2016, 12:29 PM

Thanks for confirming that! I'll try to reproduce this myself next week.

Sanne Grinovero
August 3, 2017, 10:42 AM

This was resolved now, although I'm not linking to a specific commit as most of the work in 5.8 relates to fixing this.

Assignee

Yoann Rodière

Reporter

Joe

Labels

None

Suitable for new contributors

None

Pull Request

None

Feedback Requested

None

Components

Fix versions

Affects versions

Priority

Major
Configure