I have installed X-Pack 5.2.2 on Elasticsearch 5.2.2. I connect from java code to Elastic Search cluster, with none SSL connection. JDK is 1.8.102, I have all X-Pack jars at client classpath.
I have used following java client code:
I am getting following when I try to establish Transport connection:
Failed to load plugin class [org.elasticsearch.xpack.XPackPlugin]
ElasticsearchException[Failed to load plugin class [org.elasticsearch.xpack.XPackPlugin]]; nested: InvocationTargetException; nested: ElasticsearchException[failed to initialize a TrustManagerFactory]; nested: NoSuchFileException[NOT_SET];
at org.elasticsearch.plugins.PluginsService.loadPlugin(PluginsService.java:384)
at org.elasticsearch.plugins.PluginsService.(PluginsService.java:104)
at org.elasticsearch.client.transport.TransportClient.newPluginService(TransportClient.java:99)
at org.elasticsearch.client.transport.TransportClient.buildTemplate(TransportClient.java:124)
at org.elasticsearch.client.transport.TransportClient.(TransportClient.java:258)
at org.elasticsearch.transport.client.PreBuiltTransportClient.(PreBuiltTransportClient.java:125)
at org.elasticsearch.xpack.client.PreBuiltXPackTransportClient.(PreBuiltXPackTransportClient.java:55)
at org.elasticsearch.xpack.client.PreBuiltXPackTransportClient.(PreBuiltXPackTransportClient.java:50)
at org.elasticsearch.xpack.client.PreBuiltXPackTransportClient.(PreBuiltXPackTransportClient.java:46)
2017-08-07 16:16:32,759 ERROR com.searchservice.domain.factory.BoxTransportClientFactory [http-nio-7065-exec-17] PreBuiltTransportClient :Failed to load plugin class [org.elasticsearch.xpack.XPackPlugin]
ElasticsearchException[Failed to load plugin class [org.elasticsearch.xpack.XPackPlugin]]; nested: InvocationTargetException; nested: ElasticsearchException[failed to initialize a TrustManagerFactory]; nested: NoSuchFileException[NOT_SET];
at org.elasticsearch.plugins.PluginsService.loadPlugin(PluginsService.java:384)
at org.elasticsearch.plugins.PluginsService.(PluginsService.java:104)
at org.elasticsearch.client.transport.TransportClient.newPluginService(TransportClient.java:99)
at org.elasticsearch.client.transport.TransportClient.buildTemplate(TransportClient.java:124)
at org.elasticsearch.client.transport.TransportClient.(TransportClient.java:258)
at org.elasticsearch.transport.client.PreBuiltTransportClient.(PreBuiltTransportClient.java:125)
at org.elasticsearch.xpack.client.PreBuiltXPackTransportClient.(PreBuiltXPackTransportClient.java:55)
at org.elasticsearch.xpack.client.PreBuiltXPackTransportClient.(PreBuiltXPackTransportClient.java:50)
at org.elasticsearch.xpack.client.PreBuiltXPackTransportClient.(PreBuiltXPackTransportClient.java:46)
at com.boeing.searchservice.domain.factory.BoxTransportClientFactory.getTransportClient(BoxTransportClientFactory.java:162)
at com.boeing.searchservice.domain.factory.BoxTransportClientFactory.getClient(BoxTransportClientFactory.java:119)
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 org.springframework.expression.spel.support.ReflectiveMethodExecutor.execute(ReflectiveMethodExecutor.java:69)
at org.springframework.expression.spel.ast.MethodReference.getValueInternal(MethodReference.java:110)
at org.springframework.expression.spel.ast.CompoundExpression.getValueInternal(CompoundExpression.java:57)
at org.springframework.expression.spel.ast.SpelNodeImpl.getValue(SpelNodeImpl.java:93)
at org.springframework.expression.spel.standard.SpelExpression.getValue(SpelExpression.java:88)
at org.springframework.context.expression.StandardBeanExpressionResolver.evaluate(StandardBeanExpressionResolver.java:138)
at org.springframework.beans.factory.support.AbstractBeanFactory.evaluateBeanDefinitionString(AbstractBeanFactory.java:1287)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.evaluate(BeanDefinitionValueResolver.java:210)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:182)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1325)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean.....
Caused by: ElasticsearchException[failed to initialize a TrustManagerFactory]; nested: NoSuchFileException[NOT_SET];
at org.elasticsearch.xpack.ssl.StoreTrustConfig.createTrustManager(StoreTrustConfig.java:57)
at org.elasticsearch.xpack.ssl.SSLService.createSslContext(SSLService.java:378)
at org.elasticsearch.xpack.ssl.SSLService.loadSSLConfigurations(SSLService.java:401)
at org.elasticsearch.xpack.ssl.SSLService.(SSLService.java:79)
at org.elasticsearch.xpack.XPackPlugin.(XPackPlugin.java:194)
... 113 more
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.