Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed test ElasticSearchClientProvider value #3332

Merged
merged 1 commit into from
Jun 18, 2021

Conversation

Coduz
Copy link
Contributor

@Coduz Coduz commented Jun 17, 2021

This PR fixes and issue with the test that came out after merge of #3315.
The PR build had test passing but after merge the issue arised even if the #3315 branch was up to date with develop

After a bit of investigation on error:

Error: Scenario: Stop datastore after all scenarios Time elapsed: 1.523 s <<< ERROR!
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

I've found a test class that had the wrong value for the datastore.elasticsearch.provider property which was pointing to the Client class instead of the ClientProvider.

Related Issue
None

Description of the solution adopted
Just fixed the wrong parameter

Screenshots
None

Any side note on the changes made
None

Signed-off-by: Alberto Codutti <alberto.codutti@eurotech.com>
@Coduz Coduz added Bug This is a bug or an unexpected behaviour. Fix it! Test Test related stuff. It's a dirty job, but someone needs to do that! labels Jun 17, 2021
@Coduz Coduz requested a review from lorthirk June 17, 2021 14:20
@codecov
Copy link

codecov bot commented Jun 17, 2021

Codecov Report

Merging #3332 (00c2fb6) into develop (6278827) will decrease coverage by 12.37%.
The diff coverage is n/a.

❗ Current head 00c2fb6 differs from pull request most recent head 73562ee. Consider uploading reports for the commit 73562ee to get more accurate results
Impacted file tree graph

@@              Coverage Diff               @@
##             develop    #3332       +/-   ##
==============================================
- Coverage      47.82%   35.44%   -12.38%     
+ Complexity       867      739      -128     
==============================================
  Files           1516     1516               
  Lines          30463    30463               
  Branches        2528     2528               
==============================================
- Hits           14569    10798     -3771     
- Misses         15161    18799     +3638     
- Partials         733      866      +133     
Impacted Files Coverage Δ
...rc/main/java/org/eclipse/kapua/KapuaException.java 0.00% <0.00%> (-100.00%) ⬇️
...c/main/java/org/eclipse/kapua/KapuaErrorCodes.java 0.00% <0.00%> (-100.00%) ⬇️
...in/java/org/eclipse/kapua/broker/BrokerDomain.java 0.00% <0.00%> (-100.00%) ⬇️
...ain/java/org/eclipse/kapua/event/ServiceEvent.java 0.00% <0.00%> (-100.00%) ⬇️
...n/java/org/eclipse/kapua/broker/BrokerDomains.java 0.00% <0.00%> (-100.00%) ⬇️
...va/org/eclipse/kapua/commons/util/SystemUtils.java 0.00% <0.00%> (-100.00%) ⬇️
...n/java/org/eclipse/kapua/model/domain/Actions.java 0.00% <0.00%> (-100.00%) ⬇️
.../java/org/eclipse/kapua/message/KapuaPosition.java 0.00% <0.00%> (-100.00%) ⬇️
.../java/org/eclipse/kapua/KapuaRuntimeException.java 0.00% <0.00%> (-100.00%) ⬇️
.../java/org/eclipse/kapua/model/query/SortOrder.java 0.00% <0.00%> (-100.00%) ⬇️
... and 526 more

@Coduz Coduz merged commit 80954ba into eclipse:develop Jun 18, 2021
@Coduz Coduz deleted the fix-testElasticSearchProviderName branch June 18, 2021 07:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug This is a bug or an unexpected behaviour. Fix it! Test Test related stuff. It's a dirty job, but someone needs to do that!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants