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

cbdatasource with options.SeqEnd, same mutations over and over #70

Open
mschoch opened this issue Dec 3, 2015 · 2 comments
Open

cbdatasource with options.SeqEnd, same mutations over and over #70

mschoch opened this issue Dec 3, 2015 · 2 comments

Comments

@mschoch
Copy link
Contributor

mschoch commented Dec 3, 2015

When I set the options.SeqEnd to a set of vbucket high-water marks, I end up getting the same mutation delivered to me over and over again.

Also, is there any callback/notification that the configure end has been reached and things can be shut down?

cc @steveyen

@mschoch
Copy link
Contributor Author

mschoch commented Dec 3, 2015

@steveyen I've uploaded the program which can reproduce the problem:

https://github.com/couchbaselabs/cb2bleve

Uncomment these lines:

https://github.com/couchbaselabs/cb2bleve/blob/master/cb2bleve.go#L40-L48

Then run with a bucket containing a single document. I see DataUpdate() method get called repeatedly for the single key.

@steveyen
Copy link
Member

steveyen commented Dec 3, 2015

thanks @mschoch

I made some changes to cb2bleve so that it implements the SetMetaData/GetMetaData callbacks in a "barely good enough" way, which should be helpful.

But, the cbdatasource is still at this point handling a stream-end DCP message incorrectly/inefficiently. That is, the DCP mutations will stop, so from the app's perspective the functionality looks right. But, underneath the hood cbdatasource will next inefficiently go into a loop of trying to refresh cluster information again and again, and unfortunately consume lots of CPU.

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

No branches or pull requests

2 participants