[ 
https://issues.apache.org/jira/browse/COUCHDB-3266?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15799245#comment-15799245
 ] 

Steven Spungin commented on COUCHDB-3266:
-----------------------------------------

> f you keep all original fields then the deleted doc takes up as much space as 
> before. Do as Nick suggests and keep only the fields that you need for your 
> filter.

That means every time I change the filter, I have to find all workaround calls 
to delete and change them.  Not very maintainable.

Anyway, in my case I am monitoring other code that is already calling the 
delete method, so I won't be able to alter it.

I do think that the filter callback should be called in my case, however.  I 
have not looked at the source code, but at the very least, when a document is 
deleted, a workaround is to look at the last revision and if it matches the 
filter then simply notify the listener with the deleted rev.  This seems 
reasonable and appropriate behavior for the selector filter.

> changes feed not invoked when deleting a document using a selector filtered 
> feed.
> ---------------------------------------------------------------------------------
>
>                 Key: COUCHDB-3266
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-3266
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Database Core
>            Reporter: Steven Spungin
>
> When I subscribe to the _changes endpoint with a selector filter, I get 
> updated and created changes, but not deleted changes.
> But when I subscribe without a selector, I get all the changes as expected.
> Here is my posted selector:
>      {"selector": {"type": "message", "subtype": "email"}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to