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

Writing to data stream in elastic returns an error #132

Closed
hmlmartins opened this issue Oct 27, 2020 · 7 comments · Fixed by #133
Closed

Writing to data stream in elastic returns an error #132

hmlmartins opened this issue Oct 27, 2020 · 7 comments · Fixed by #133

Comments

@hmlmartins
Copy link

Hello,

I set up my index to be a data stream in elastic but I get an error stating the request should have op_type: create.

Is there a way to overcome, or is this not ready yet to work with data streams?

Thank you

@snakefoot
Copy link
Collaborator

snakefoot commented Oct 28, 2020

@hmlmartins You can try this pre-release nuget-package (Artifact from PR #133) to see if resolves your problem (Just place in local nuget-folder).

It introduces a new option called OpCodeCreate that can be used like this:

<target xsi:type="ElasticSearch" uri="http://localhost:9200/" opCodeCreate="true" />

@hmlmartins
Copy link
Author

hmlmartins commented Oct 29, 2020 via email

@snakefoot
Copy link
Collaborator

snakefoot commented Oct 29, 2020 via email

@hmlmartins
Copy link
Author

hmlmartins commented Oct 29, 2020 via email

@snakefoot
Copy link
Collaborator

But I'll keep an eye out for changes and eventually provide some feedback.

Excellent. Looking forward to hear about the test results.

@TheDruidsKeeper
Copy link

TheDruidsKeeper commented Nov 12, 2020

I ran into this issue as well, so I took the time to test the PR build and it worked perfectly for me. I'm using elastic v7.9.1, and verified with the prelease package that I could still write to traditional (non data stream) indexes both with & without opCodeCreate="true". Writing to the datastream isn't successful without the opCodeCreate enabled (as expected), and is successful with it.
image

@snakefoot
Copy link
Collaborator

ElasticSearch ver. 7.5.0 has been released: https://www.nuget.org/packages/NLog.Targets.ElasticSearch

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 a pull request may close this issue.

3 participants