Failed

Scenario: Create same user in different accounts.Scenario: Create same user in different accounts (from org.eclipse.kapua.integration.service.user.RunUserServiceI9nTest)

Failing for the past 7 builds (Since #725 )
Took 1 sec.

Error Message

Cannot instantiate Elasticsearch Client

Stacktrace

org.eclipse.kapua.service.datastore.exception.DatastoreInternalError: Cannot instantiate Elasticsearch Client
Caused by: java.lang.ClassCastException: org.eclipse.kapua.service.elasticsearch.client.rest.RestElasticsearchClient cannot be cast to org.eclipse.kapua.service.elasticsearch.client.ElasticsearchClientProvider

Standard Output

10:03:18.005 [main] INFO  o.e.k.s.a.steps.AccountServiceSteps - Logging out in cleanup
10:03:18.005 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.005 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.006 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.006 [main] INFO  o.e.k.s.u.steps.UserRoleServiceSteps - Logging out in cleanup
10:03:18.006 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.006 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.007 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.007 [main] INFO  o.e.k.s.user.steps.UserServiceSteps - Logging out in cleanup
10:03:18.007 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.007 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.008 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.008 [main] INFO  o.e.k.s.a.s.AuthorizationServiceSteps - Logging out in cleanup
10:03:18.008 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.008 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.009 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.009 [main] INFO  o.e.k.s.d.r.s.DeviceRegistrySteps - Logging out in cleanup
10:03:18.009 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.009 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.010 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.010 [main] INFO  o.e.k.s.job.steps.JobServiceSteps - Logging out in cleanup
10:03:18.010 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.010 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.011 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.011 [main] INFO  o.e.k.s.tag.steps.TagServiceSteps - Logging out in cleanup
10:03:18.011 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.011 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.011 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.012 [main] INFO  o.e.k.s.d.steps.DatastoreSteps - Logging out in cleanup
10:03:18.012 [main] ERROR o.e.k.s.d.steps.DatastoreSteps - Failed to log out in @After
org.eclipse.kapua.service.datastore.exception.DatastoreInternalError: Cannot instantiate Elasticsearch Client
	at org.eclipse.kapua.service.datastore.internal.client.DatastoreClientFactory.getInstance(DatastoreClientFactory.java:67)
	at org.eclipse.kapua.service.datastore.internal.client.DatastoreClientFactory.getElasticsearchClient(DatastoreClientFactory.java:86)
	at org.eclipse.kapua.service.datastore.internal.AbstractRegistryFacade.getElasticsearchClient(AbstractRegistryFacade.java:46)
	at org.eclipse.kapua.service.datastore.internal.MessageStoreFacade.deleteAllIndexes(MessageStoreFacade.java:530)
	at org.eclipse.kapua.service.datastore.internal.mediator.DatastoreMediator.deleteAllIndexes(DatastoreMediator.java:238)
	at org.eclipse.kapua.service.datastore.steps.DatastoreSteps.deleteIndices(DatastoreSteps.java:366)
	at org.eclipse.kapua.service.datastore.steps.DatastoreSteps.afterScenario(DatastoreSteps.java:349)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at cucumber.runtime.Utils$1.call(Utils.java:37)
	at cucumber.runtime.Timeout.timeout(Timeout.java:13)
	at cucumber.runtime.Utils.invoke(Utils.java:31)
	at cucumber.runtime.java.JavaHookDefinition.execute(JavaHookDefinition.java:60)
	at cucumber.runtime.Runtime.runHookIfTagsMatch(Runtime.java:223)
	at cucumber.runtime.Runtime.runHooks(Runtime.java:211)
	at cucumber.runtime.Runtime.runAfterHooks(Runtime.java:205)
	at cucumber.runtime.model.CucumberScenario.run(CucumberScenario.java:46)
	at cucumber.runtime.junit.ExecutionUnitRunner.run(ExecutionUnitRunner.java:91)
	at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:63)
	at cucumber.runtime.junit.FeatureRunner.runChild(FeatureRunner.java:18)
	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
	at cucumber.runtime.junit.FeatureRunner.run(FeatureRunner.java:70)
	at cucumber.api.junit.Cucumber.runChild(Cucumber.java:93)
	at cucumber.api.junit.Cucumber.runChild(Cucumber.java:37)
	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
	at cucumber.api.junit.Cucumber.run(Cucumber.java:98)
	at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:365)
	at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:272)
	at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:236)
	at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:159)
	at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:386)
	at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:323)
	at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:143)
Caused by: java.lang.ClassCastException: org.eclipse.kapua.service.elasticsearch.client.rest.RestElasticsearchClient cannot be cast to org.eclipse.kapua.service.elasticsearch.client.ElasticsearchClientProvider
	at org.eclipse.kapua.service.datastore.internal.client.DatastoreClientFactory.getInstance(DatastoreClientFactory.java:59)
	... 44 common frames omitted
10:03:18.012 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - Running database script from resources...
10:03:18.012 [main] INFO  o.e.k.c.jpa.SimpleSqlScriptExecutor - Running resources script: sql/all_delete.sql
10:03:18.013 [main] INFO  o.e.k.c.c.KapuaConfigurableServiceSchemaUtilsWithResources - ...database scripts from resources done!
10:03:18.013 [main] INFO  o.eclipse.kapua.qa.common.BasicSteps - Wait multiplier active: 4.0
10:03:18.013 [main] INFO  org.eclipse.kapua.qa.common.DBHelper - Setting up embedded database
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - =================== KapuaLiquibaseClient Configuration ===================
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  Liquibase Version: 3.6.3
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  DB connection info
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  	JDBC URL: jdbc:h2:mem:kapua;MODE=MySQL;DB_CLOSE_DELAY=-1;INIT=CREATE SCHEMA IF NOT EXISTS kapuadb\;SET SCHEMA kapuadb
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  	Username: kapua
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  	Password: ******
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  	Schema: kapuadb
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  Timestamp(3) fix info (eclipse/kapua#2889)
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  	Force timestamp fix: false
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - |  	Apply timestamp fix: true
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - ==========================================
10:03:18.013 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Running Liquibase scripts...
10:03:18.029 [main] INFO  org.reflections.Reflections - Reflections took 5 ms to scan 22 urls, producing 1370 keys and 1388 values 
10:03:18.076 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Executing pre master files...
10:03:18.076 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 	Master Liquibase files found: 5
10:03:18.076 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-authorization-master.pre.xml...
10:03:18.095 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-event-store-master.pre.xml...
10:03:18.118 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-job-master.pre.xml...
10:03:18.137 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-scheduler-master.pre.xml...
10:03:18.154 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-system-configurations-master.pre.xml...
10:03:18.175 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Executing pre master files... DONE!
10:03:18.175 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Executing master files...
10:03:18.175 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 	Master Liquibase files found: 21
10:03:18.175 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-account-master.xml...
10:03:18.212 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-asset-job-master.xml...
10:03:18.234 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-authentication-master.xml...
10:03:18.298 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-authorization-master.xml...
10:03:18.396 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-broker-master.xml...
10:03:18.413 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-bundle-job-master.xml...
10:03:18.439 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-command-job-master.xml...
10:03:18.461 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-configuration-job-master.xml...
10:03:18.489 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-datastore-master.xml...
10:03:18.505 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-device-management-master.xml...
10:03:18.526 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-device-master.xml...
10:03:18.629 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-device_management_registry-master.xml...
10:03:18.666 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-endpoint-master.xml...
10:03:18.686 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-job-device-management-operation-master.xml...
10:03:18.703 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-job-engine-master.xml...
10:03:18.738 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-job-master.xml...
10:03:18.810 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-packages-job-master.xml...
10:03:18.837 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-scheduler-master.xml...
10:03:18.906 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-stream-master.xml...
10:03:18.922 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-tag-master.xml...
10:03:18.955 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-user-master.xml...
10:03:18.995 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Executing master files... DONE!
10:03:18.995 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Executing post master files...
10:03:18.995 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 	Master Liquibase files found: 5
10:03:18.995 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-asset-job-master.post.xml...
10:03:19.010 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-command-job-master.post.xml...
10:03:19.024 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-configuration-job-master.post.xml...
10:03:19.038 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-endpoint-master.post.xml...
10:03:19.053 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - 		Executing liquibase script: /tmp/kapua-liquibase/changelog-packages-job-master.post.xml...
10:03:19.067 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Executing post master files... DONE!
10:03:19.067 [main] INFO  o.e.k.c.l.KapuaLiquibaseClient - Running Liquibase scripts... DONE!
10:03:19.068 [main] WARN  o.e.kapua.ExceptionMessageUtils - Could not load exception messages for resource: datastore-service-error-messages in locale: en_US. A generic error message will be printed.
10:03:19.068 [main] WARN  o.e.kapua.ExceptionMessageUtils - Could not load exception messages for resource: datastore-service-error-messages in locale: en_US. A generic error message will be printed.
10:03:19.069 [main] WARN  o.e.kapua.ExceptionMessageUtils - Could not load exception messages for resource: datastore-service-error-messages in locale: en_US. A generic error message will be printed.