[Iplant-api-dev] Wildcard Events for Job Status Notifications
Dennis Roberts
dennis at iplantcollaborative.org
Wed Aug 13 17:00:28 MST 2014
Thanks. That took care of that problem.
I’m also running into a problem where the DE isn’t getting callbacks for failed jobs. This is the case whether I use a wildcard event or explicitly list the events. Do I have to do something special to enable them?
Thanks,
Dennis
On Aug 13, 2014, at 4:20 PM, Rion Dooley <dooley at tacc.utexas.edu> wrote:
> You’re on the right track. Notifications expire after they fire unless you explicitly ask for them to stay active. You do that by setting persistent to true in your notification object. This should work regardless of whether you are embedding the notification is a job or transfer request, or calling the Notifications service directly.
>
> {
> "url":"https://de-2.iplantc.org/de/agave-cb/077ec168-93fb-4a1b-aede-ca5e597cde75?status=${JOB_STATUS}&external-id=${JOB_ID}&end-time=${JOB_END_TIME}",
> "event":"*",
> "persistent":true
> }
>
> --
> Rion
>
>
>
>
> On Aug 13, 2014, at 6:12 PM, Dennis Roberts <dennis at iplantcollaborative.org> wrote:
>
>> I was hoping to find a way to subscribe to all possible job status change events using a single notification request. I found a note on the notifications documentation page, http://agaveapi.co/notifications-and-events/, that seems to indicate that it’s possible to do that by specifying a wildcard for the name of the event. When I tried this, however, no notifications were registered at all. Am I doing something wrong?
>>
>> Here’s an EDN version of the job request:
>>
>> {:notifications
>> [{:url
>> "https://de-2.iplantc.org/de/agave-cb/077ec168-93fb-4a1b-aede-ca5e597cde75?status=${JOB_STATUS}&external-id=${JOB_ID}&end-time=${JOB_END_TIME}",
>> :event "*"}],
>> :archiveSystem "irods-2.iplantcollaborative.org",
>> :archivePath "/dennis/analyses/wc_08131601-2014-08-13-23-01-12.6",
>> :archive true,
>> :appId "failing-word-count-0.0.1",
>> :name "wc_08131601",
>> :inputs
>> {:wcInput
>> "agave://irods-2.iplantcollaborative.org/dennis/test_clear_range.fastq"},
>> :parameters {}}
>>
>> When formatted as JSON the job request would look like this:
>>
>> {"notifications":
>> [{"url":
>> "https://de-2.iplantc.org/de/agave-cb/077ec168-93fb-4a1b-aede-ca5e597cde75?status=${JOB_STATUS}&external-id=${JOB_ID}&end-time=${JOB_END_TIME}",
>> "event": "*"}],
>> "archiveSystem": "irods-2.iplantcollaborative.org",
>> "archivePath":"/dennis/analyses/wc_08131601-2014-08-13-23-01-12.6",
>> "archive":true,
>> "appId":"failing-word-count-0.0.1",
>> "name":"wc_08131601",
>> "inputs":
>> {"wcInput":
>> "agave://irods-2.iplantcollaborative.org/dennis/test_clear_range.fastq"},
>> "parameters":{}}
>>
>> Thanks,
>> Dennis
>>
>> _______________________________________________
>> Iplant-api-dev Mailing List: Iplant-api-dev at iplantcollaborative.org
>> List Info and Archives: http://mail.iplantcollaborative.org/mailman/listinfo/iplant-api-dev
>> One-click Unsubscribe: http://mail.iplantcollaborative.org/mailman/options/iplant-api-dev/dooley%40tacc.utexas.edu?unsub=1&unsubconfirm=1
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.iplantcollaborative.org/pipermail/iplant-api-dev/attachments/20140813/6c61c34a/attachment.html
More information about the Iplant-api-dev
mailing list