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

Bug fix: mongodb fields "ts" and "op" in user collection not picked up by river #136

Merged
merged 1 commit into from
Sep 25, 2013

Conversation

benmccann
Copy link
Collaborator

Create a QueueEntry class to hold items in the stream. This fixes a bug where fields named ts or op would not be indexed by the river. It also improves readability and removes the need for several class casts.

…ug where fields named ts or op would not be indexed by the river. It also improves readability and removes the need for several class casts.
@richardwilly98
Copy link
Owner

I agree with readability but I don't see the point to index ts or op.
Can you please clarify?

@benmccann
Copy link
Collaborator Author

If I have a MongoDB collection named "mycollection" that has an entry that looks like:

{
  _id: ObjectId("1243")
  firstName: "Ben",
  lastName: "McCann",
  ts: 738493940
}

Then currently the river will drop the ts field when copying it to ElasticSearch. First it overwrites it with the oplog timestamp and then it removes it. It should be possible to name a field "ts" in my own object.

@buildhive
Copy link

Richard Louapre » elasticsearch-river-mongodb #107 SUCCESS
This pull request looks good
(what's this?)

@richardwilly98
Copy link
Owner

Thanks for the clarification. I will merge the PR.
It would make sense to add a JUnit test for this scenario.

richardwilly98 added a commit that referenced this pull request Sep 25, 2013
Bug fix: mongodb fields "ts" and "op" in user collection not picked up by river
@richardwilly98 richardwilly98 merged commit 2e4ac12 into richardwilly98:master Sep 25, 2013
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

3 participants