openwhisk-package-alarms icon indicating copy to clipboard operation
openwhisk-package-alarms copied to clipboard

automatically delete a feed that reaches max trigger count

Open rabbah opened this issue 7 years ago • 6 comments

once a feed has exhausted its triggers, should be deleted for convenience? it might also be nice to infer which triggers are one offs as well and delete them regardless of max trigger since they will not fire again.

rabbah avatar Aug 27 '17 14:08 rabbah

if we delete the feed -- where will the user see a record making transparent that this happened?

mbehrendt avatar Aug 27 '17 14:08 mbehrendt

The feed API does not provide any visibility into the status of the feed as it is and this opaqueness should be addressed systematically - at which point, the feed API can provide the necessary details: feed deleted in this case or doesn't exist.

See for example: https://github.com/apache/incubator-openwhisk-package-kafka/issues/53 but this is not specific to kafka - when a feed fails to fire a trigger, a user has no idea why. Similarly short of counting received triggers activations, the user has no idea how many events were received either, or if the feed is still active (because it already reached max triggers).

rabbah avatar Aug 27 '17 15:08 rabbah

thank you, that's what I thought.

Should we extend the feed API correspondingly?

mbehrendt avatar Aug 27 '17 16:08 mbehrendt

Originally, it was deleted for convenience. Had a request to never delete trigger feed and only disable them. We need to discuss this further and not just keep going back and forth on this matter.

jasonpet avatar Aug 28 '17 02:08 jasonpet

Another problem with deleting the feed is that the trigger still exists in the core system, which is likely confusing, as well as being a dangling reference. I think opening up the state of feeds to the user is a better approach than automatically deleting the feed.

jberstler avatar Aug 28 '17 12:08 jberstler

It would be nice to support a parameter for choosing whether to "delete when finished". I can see examples where you would want both types of behaviour. It would be better to "opt-in" for this as I can see users getting confused if it defaults to on.

:+1: on extending the feed API as well. There have been numerous issues asking for this. https://github.com/apache/incubator-openwhisk/issues/1925 https://github.com/apache/incubator-openwhisk/issues/1398

jthomas avatar Oct 19 '17 11:10 jthomas