I am upgrading the elasticsearch version from 1.* to 2.1.1. I am using it in a storm topology:
<dependency>
<groupId>org.elasticsearch</groupId>
<artifactId>elasticsearch</artifactId>
<version>2.1.1</version>
</dependency>
java version "1.8.0_45"
I am using shade plugin. the following code failed with NoClassDef exception:
Settings settings = Settings.settingsBuilder().put("cluster.name", elasticSearchCluster)
.put("client.transport.ping_timeout", this.clientTimeout).build();
TransportClient transportClient = TransportClient.builder().settings(settings).build();
java.lang.NoClassDefFoundError: Could not initialize class org.elasticsearch.threadpool.ThreadPool
at org.elasticsearch.client.transport.TransportClient$Builder.build(TransportClient.java:130)
What I am missing here?
Thanks,
Chen