The new "path-configuration" field will resolve to a URI inside a jar when building multi-level maven projects where the first level contains the spring-data-es configuration xml and the elasticsearch yml. However, it will fail to load this jar with the current code. The PR #136, has the one-line fix that fixes this issue with reading the configs
adding the relevant stacktrace that occurs without this fix:
Caused by: java.nio.file.FileSystemNotFoundException: null
at com.sun.nio.zipfs.ZipFileSystemProvider.getFileSystem(ZipFileSystemProvider.java:171)
at com.sun.nio.zipfs.ZipFileSystemProvider.getPath(ZipFileSystemProvider.java:157)
at java.nio.file.Paths.get(Paths.java:143)
at org.springframework.data.elasticsearch.client.NodeClientFactoryBean.loadConfig(NodeClientFactoryBean.java:87)
at org.springframework.data.elasticsearch.client.NodeClientFactoryBean.afterPropertiesSet(NodeClientFactoryBean.java:76)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1631)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1568)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:539)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)
My pom.xml configuration
Spring Boot version: 1.3.5.RELEASE
Spring Data Elasticsearch: 2.0.1.RELEASE (overriding manually since version 1.3.4-RELEASE does not use elasticsearch 2.0+)
Elasticsearch version 2.2.0 (overriding manually since spring-data-elasticsearch brings elasticsearc 1.5.2 to my maven dependencies.
Getting the same issue.
Caused by: java.lang.IllegalArgumentException: @ConditionalOnMissingBean annotations must specify at least one bean (type, name or annotation)
at org.springframework.util.Assert.isTrue(Assert.java:68)
Joseph Moore opened DATAES-237 and commented
The new "path-configuration" field will resolve to a URI inside a jar when building multi-level maven projects where the first level contains the spring-data-es configuration xml and the elasticsearch yml. However, it will fail to load this jar with the current code. The PR #136, has the one-line fix that fixes this issue with reading the configs
Affects: 2.0 RC1 (Hopper)
Reference URL: #136
The text was updated successfully, but these errors were encountered: