-
Notifications
You must be signed in to change notification settings - Fork 25.6k
CouchDB river : add support for views #1258
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
Conversation
Ooouch. I'm not a Git expert so I added the commit 270d7e0 to this pull request instead of opening a new pull request for the attachement bypass option... So, what can I do now ? Is there anyway to remove the last commit to this pull request ? Thanks (and sorry ;-) ) |
I think we should have two different pull requests for those. Lemme first also work on the ids prefix filter so we can have the better solution baked right in. Not sure I fully followed what it does though :) |
Ok. Pull request #1283 created for the ignoreAttachements new option. I will try to update this one (or will close it and open another one if I don't suceed). |
…erly after cluster update settings
… structure (resulting in wrong search responses), closes elastic#1323.
…rocess hanging, closes elastic#1325.
…re no ongoing merges, closes elastic#1336.
…ans id is not written
…e the list fo nodes to ping as well as the provided nodes, closes elastic#1217.
…*non* data node is added to the cluster, closes elastic#1368.
…ype missing, closes elastic#1369.
…hards to make sure we don't miss it, closes elastic#1370.
…e clean things up before we delete content if needed
…dex}/{type}/_bulk endpoints, closes elastic#1375.
…he callback listener is threaded
Do you think the functionality of pulling from a view will be added to the couchdb river? |
Hi there, Not sure of what happened with my pull request : fc0e03c I think that I did a stupid thing yesterday with git and my elasticsearch fork... Do I have to create a new pull request for this issue ? |
I was looking through the release notes for 18 and I don't the ability to create a couchdb river for a view is this something that's not getting implemented or is it just being worked on from other angles? |
No. It's not here. |
@jdzurik : I worked on it again. You can give it a try and let me know. Please let me know if it answers to your needs. If so, I will send a pull request for it. David. |
Hello David, I installed ElasticSearch, its work good i can index and search xml and json content using Dev HTTP Client. sincerely, |
I think you misunderstood what I answered to your private email. If you need to ask public question, please use the mailing list. You can have more details on how to do it here: http://www.elasticsearch.org/help/ But please, don't hijack issues or pull requests. |
ok i'm sorry for misunderstanding you and thanks for help you are a good man(Professional) |
In CouchDB, you can retrieve docs by
GET
,_changes
API and views.CouchDB river uses
_changes
API to get documents.I would like to be able to get documents that changed (getting ID with the _changes API) using a view with parameter
key="DOCID"
.As views return a collection of results (aka rows), we will index in ES each row with an id like DOCID_seq where seq is the sequence number of each row.
If you get back 3 rows for one single change for document with ID=1234, the river will index 3 documents :
To use it, you have to define a view in couchDB. For instance,
_design/vues/_view/test_dpi
withYou can use it in your couchDb river as follow :
New options :
view
: if not null, couchDB river will not fetch content from_changes
API but only IDs and then will use the view to retrieve rows using the ID as a key. By default : nullviewIgnoreRemove
: ask the river to ignore removal of rows if there is less rows after a document update. By default : false so non existing rows will be removed from elastic search.For example, with the 3 rows described earlier, if you push a new version of the document 1234 in couchDB with only 2 docs,
If
viewIgnoreRemove
is false (default), thenIf
viewIgnoreRemove
is true, thenI hope I wrote it in the right way. Any comments are welcome...
BTW, I will push an update when the
ids_prefix
filter will be available to make code more efficient. (See issue #1259)Thanks