Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to use auto-generated IDs on indexing #679

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

Conversation

gjw13
Copy link

@gjw13 gjw13 commented Mar 15, 2023

Problem

While setting the document ID when indexing does provide exactly once delivery, it does put more load on Elasticsearch and is not necessary for all use cases.

PRs have been made for this issue before (#393) and (#510). This PR is largely an update to the most recent one, as again there were many merge conflicts that needed resolving there as it fell out of date.

Addresses #139 and #97

Solution

Add a new option to use the autogenerated document id on index requests. The new option (use.autogenerated.ids) will default to false and only be applicable when write.method is set to INSERT.

Note that the large diff in the DataCoverter class on the convertRecord method is a result of having to pull a chunk of that code out into a separate method. The checkstyle plugin was throwing errors when an extra statement was added in that the cyclomatic complexity got too high.

Does this solution apply anywhere else?
  • yes
  • no
If yes, where?

Test Strategy

Testing done:
  • Unit tests
  • Integration tests
  • System tests
  • Manual tests

As with (#510), we are running live connectors leveraging this feature.

Release Plan

@gjw13 gjw13 requested a review from a team as a code owner March 15, 2023 15:33
@gjw13
Copy link
Author

gjw13 commented Mar 15, 2023

I attempted to sign the CLA, but the URL doesn't resolve.

@cla-assistant
Copy link

cla-assistant bot commented Sep 11, 2023

CLA assistant check
All committers have signed the CLA.

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

Successfully merging this pull request may close these issues.

None yet

1 participant