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

Enhancements for startDate, stopDate, fire once, interval #102

Closed
csantanapr opened this Issue Oct 27, 2017 · 2 comments

Comments

Projects
None yet
2 participants
@csantanapr
Contributor

csantanapr commented Oct 27, 2017

This issue is an Epic to capture some enhancements for the alarms package

Feature requests:

  • Allow to specify startDate and stopDate
  • Allow to specify fire once Date
  • Allow to specify more granular interval

Allow to specify startDate and stopDate

Example configuration

wsk trigger create periodic \ 
--feed /whisk.system/alarms/alarm \
--param cron "*/2 * * * *" \
--param startDate “2017-10-27T14:00”
--param stopDate “2017-10-27T14:00”

The trigger will start to fire after startDate, and no longer fire after stopDate
The time is UTC, or user can provide time zone

Adding this feature will allow us to deprecate and remove the parameter 'maxTriggers`
(today the default is infinite)

Things to consider when using stopDate to clean up.

  • allow user to specify entities (trigger and/or set of rules) if trigger should be deleted when the alarm is suppose to fire, but the current time is past the stopDate.

Allow to specify fire once Date

User wants to fire a trigger only once at the specified time/date
Example configuration

wsk trigger create doOnce \ 
--feed /whisk.system/alarms/once \
--param date "2017-10-27T14:00"

Allow to specify more granular interval

Today the cron syntax doesn't allow to specify intervals, only at the hour mark, and then repeat on the next hour. User have requests that they want more control over the internal of the fires for example every 16, or 12 minutes.
Example configuration

wsk trigger create interval \ 
--feed /whisk.system/alarms/interval \
--param minutes ”16" \
--param startDate “2017-10-27T14:02”
--param stopDate “2017-10-28T14:00”

Future/Open

Provide in CLI and Feed Abstraction for runOnce Action
Example configuration

wsk invoke myaction --once --date “2017-10-28T14:00”

Under the hood create feed alarm Fire Once, and instead of fire trigger, we invoke the action myAction.
But we also need a way to list and identified actions to be fire in the future, maybe we create a trigger and a rule with a naming convention to allow for this management.

@daisy-ycguo

This comment has been minimized.

Show comment
Hide comment
@daisy-ycguo

daisy-ycguo Nov 20, 2017

Member

I think this one is fixed and we can close it. @csantanapr please verify if it can be closed.

Member

daisy-ycguo commented Nov 20, 2017

I think this one is fixed and we can close it. @csantanapr please verify if it can be closed.

@csantanapr

This comment has been minimized.

Show comment
Hide comment
@csantanapr
Contributor

csantanapr commented Nov 20, 2017

@csantanapr csantanapr closed this Nov 20, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment