[No handler for type [geo_shape] declared on field [mapped_geo_shape]] AbstractQueryTestCase

I have a plugin with a custom query and QueryBuilder. I've written the test extending it from org.elasticsearch.test.AbstractQueryTestCase. When I'm running it I got the following error:

Caused by: MapperParsingException[No handler for type [geo_shape] declared on field [mapped_geo_shape]]
	at org.elasticsearch.index.mapper.ObjectMapper$TypeParser.parseProperties(ObjectMapper.java:274)
	at org.elasticsearch.index.mapper.ObjectMapper$TypeParser.parseObjectOrDocumentTypeProperties(ObjectMapper.java:199)
	at org.elasticsearch.index.mapper.RootObjectMapper$TypeParser.parse(RootObjectMapper.java:131)
	at org.elasticsearch.index.mapper.DocumentMapperParser.parse(DocumentMapperParser.java:112)
	at org.elasticsearch.index.mapper.DocumentMapperParser.parse(DocumentMapperParser.java:92)
	at org.elasticsearch.index.mapper.MapperService.internalMerge(MapperService.java:349)
	... 39 more

Elasticsearch 6.3.2 (tried also wtih 6.4.3)
Lucene 7.3.1 (tried also with 7.4.0)

When I updated Elasticsearch version to 6.4.3 - this error gone for the first run. I ran the test again and got this error again. My plugin doesn't operates with geo_shape type or other types. I've returned to 6.3.2 and first run worked, but the following calls are failed.

I've tried to add dependencies to my pom.xml com.vididsolutions.jts and spatial4j as advised in the that topic but it didn't helped.

Any help as appreciated.

Which version did you try to add?

1.13 (jts)
0.6 (spatial4j)

These are wrong versions for 6.3 and 6.4.

I've tried 1.15 and 0.7 as specified in versions file for 6.3, 6.4, 6.5. But I got the same error.

Interesting, that com.vividsolutions.jts 1.15.0 is not found in maven repository and I used org.locationtech.jts package.

I don't know, may I should specify this dependency not only in pom.xml?

Intersting, that for ES 6.5 the error happen approximately 1 time from 2, but in earlier version it happen always.

Same error. May I should configure the test in IDEA in some specific way?

Interesting, that com.vividsolutions.jts 1.15.0 is not found in maven repository and I used org.locationtech.jts package.

Yes, the maintainer of the library changed between 1.14 and 1.15

It is hard to tell without seeing how things are configured. Is this plugin open source?

Unfortunately it is not opensource at this moment. I can't show you it, but the error happen before the plugin is initialized. And It is reproduced on just clean project. I've found that jts jar is not downloaded to my repository. I've tried to find it manually: not result. Please have a look:

There is jts-core found, but jts - isn't.
I even tried to build it manually, and jts jar is not builded..

Where did you get it?

jts was renamed to jts-core in 1.15. It can be found here https://oss.sonatype.org/content/repositories/releases/org/locationtech/jts/jts-core/1.15.0/ and here http://central.maven.org/maven2/org/locationtech/jts/jts-core/1.15.0/

Now the test is running. Igor, thank you very much!

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.