You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was trying to listen to changes of a cloudant feed and then send an email using sendgrid, when one flag 'process' was set to true.
For this I needed to implement one openwhisk action to filter out whether 'process' was set to true and 'mailsend' set to false.
Suggestion
Looking at the documentation of cloudant I saw that you can add add filter and doc_ids to a changefeed. It would be very awesome to add these parameters, so that filtering can already be taken care of at the change feed instead of the user created action.
Bonus
I also saw that you can pass oldDoc as a parameter. This could be helpful if you want to compare what exactly changed in an action.
@bseyb commented on Wed Oct 19 2016
Why
I was trying to listen to changes of a cloudant feed and then send an email using sendgrid, when one flag 'process' was set to true.
For this I needed to implement one openwhisk action to filter out whether 'process' was set to true and 'mailsend' set to false.
Suggestion
Looking at the documentation of cloudant I saw that you can add add filter and doc_ids to a changefeed. It would be very awesome to add these parameters, so that filtering can already be taken care of at the change feed instead of the user created action.
Bonus
I also saw that you can pass oldDoc as a parameter. This could be helpful if you want to compare what exactly changed in an action.
@csantanapr commented on Thu Nov 24 2016
Hi @bseyb I started looking into the design on providing a way to filter changes for the cloudant trigger.
Looking at the spec of the changes API
It looks like a filter and docs_id is doable, a filter will be a filter function on a design document.
What I didn't find was
oldDoc
during my testing the changes feed only provide the id anddeleted=true
and the new revision marked as deleted.I was not able to find a reference to
oldDoc
in the changes API params.Could you share a bit more where you saw this reference?
@bseyb commented on Tue Dec 13 2016
Hi @csantanapr I must have misread it, I cannot find oldDoc in the correct context either.
Having that Filter function available would help a whole lot.
@rabbah commented on Tue Jan 24 2017
@csantanapr move this to openwhisk-catalog-cloudant? FYI @johnsolm @dubeejw.
The text was updated successfully, but these errors were encountered: