Skip to content
This repository has been archived by the owner on Mar 30, 2021. It is now read-only.

elasticsearch 2.x support #63

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

danielcbright
Copy link

Purpose

Currently there is no elasticsearch 2.x.x support in the amazon-kinesis-connectors library. This PR is a first step forward towards getting support implemented.

Status

WORK IN PROGRESS / NEED HELP

Related Issues and PRs

Background

I was enticed to use the cloudwatch-logs-subscription-consumer by @dvassallo one day and went about trying to get it to work with our already implemented elasticsearch 2.0.0 installation in AWS. By figuring out what had changed between the 1.x and 2.x versions of elasticsearch (great reference here) I was then able to go through the amazon-kinesis-connectors code and the cloudwatch-subscription-consumer code and make some changes to support 2.x. I then built a local .jar for amazon-kinesis-connectors after making some pom.xml changes. Followed by changes to cloudwatch-logs-subscription-consumer that fixed ImmutableSettings and re-wrote the ElasticsearchEmitter function to use the methods outlined in the java api doc here.

I was then able to make a successful connection to elasticsearch and see records start coming through. There are still a few things to iron out, they are outlined below. But the hope is, people who really need it can start using the configs in the PR and then soon it will be merged and fully functional.

ToDos

  • The main issue that remains is the ElasticsearchEmitter needs to be able to determine the elasticsearch version it is using from the pom.xml, and then use the correct imports and function syntax. I am a newbie to Maven, and not a Java expert so this is beyond me for now.
  • I didn't write any tests, nor did I notice any, they may need to be written?
  • Documentation needs to be updated.

Other Notes

  • This was tested in Centos 6.7 and nowhere else.

Daniel Bright and others added 2 commits January 21, 2016 14:24
Added new pom.xml.elasticsearch-2.0.0 example for building with
elasticsearch 2.0.0 (tested on 2.0.0 and 2.0.1 so far). And added a new
Elasticsearch2Emitter.java that contains all the needed changes to make
this library work with elasticsearch 2.x.x.

//TODO - The changes in Elasticsearch2Emitter.java need to be merged
into ElasticsearchEmitter.java and the imort of "import
org.elasticsearch.common.settings.ImmutableSettings;" needs to be driven
by the version of elasticsearch used, the "ElasticsearchEmitter"
function also needs to be dependent on the version.
Added support for elasticsearch 2.x.x
@alexanderdean
Copy link

Any update on this?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants