Adds support for newer versions of Elasticsearch that removed _type in Elasticsearch Appender.
Hi @reidmorrison,
I tested this code with 6.x, 7.x and 8.x. For integrating the tests with the different versions, I think we would need to add different gemfiles and run the tests with each version, but I don't know if that's worth it or something you'd like to have since it'd be quite an overhead. Let me know.
I added a helper function to the tests. For versions < 8.0.0, Elasticsearch::Transport::Client and Elasticsearch::Client could be used to call bulk, but since we extracted Transport into its own library, you need to call Elasticsearch::Client for bulk.
Let me know what you think. For ElasticsearchHTTP, you'd need to make a call to / in the Elasticsearch instance to find out the version, and if it's 7 or 8 remove type from the path. Let me know if you'd like me to add this.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
Issue #225
Description of changes
Adds support for newer versions of Elasticsearch that removed _type in Elasticsearch Appender.
Hi @reidmorrison, I tested this code with 6.x, 7.x and 8.x. For integrating the tests with the different versions, I think we would need to add different gemfiles and run the tests with each version, but I don't know if that's worth it or something you'd like to have since it'd be quite an overhead. Let me know.
I added a helper function to the tests. For versions < 8.0.0,
Elasticsearch::Transport::Client
andElasticsearch::Client
could be used to callbulk
, but since we extracted Transport into its own library, you need to callElasticsearch::Client
for bulk.Let me know what you think. For
ElasticsearchHTTP
, you'd need to make a call to/
in the Elasticsearch instance to find out the version, and if it's 7 or 8 removetype
from the path. Let me know if you'd like me to add this.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.