Skip to content
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

Updated Retry Failed Workflows to use less than or equals operator #17

Merged
merged 1 commit into from
Sep 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions workflows/retry-failed-workflows/RetryFailedWorkflowsForm.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"elementType": "SECTION",
"config": {
"alignment": "LEFT",
"description": "Use this form to start a workflow that will retry failed workflows after the specified date.",
"description": "Use this form to start a workflow that will retry failed workflows on or after the specified date.",
"formElements": [
{
"config": {
Expand Down Expand Up @@ -49,7 +49,7 @@
"config": {
"default": "",
"description": "",
"helpText": "Retry all Workflow executions that have a start date after this date and have a \"Failed\" status.",
"helpText": "Retry all Workflow executions that have a start date on or after this date and have a \"Failed\" status.",
"label": "Start Date",
"placeholder": "",
"required": true
Expand All @@ -70,7 +70,7 @@
"config": {
"default": "",
"description": "",
"helpText": "Retry all Workflow executions that have a start time after this time and have a \"Failed\" status. You must use the following format: hh:mm:ss.",
"helpText": "Retry all Workflow executions that have a start time on or after this time and have a \"Failed\" status. You must use the following format: hh:mm:ss.",
"label": "Start Time",
"placeholder": "13:16:24",
"required": true
Expand All @@ -95,7 +95,7 @@
"config": {
"default": "",
"description": "",
"helpText": "Retry all Workflow executions that have a start date before this date and have a \"Failed\" status.",
"helpText": "Retry all Workflow executions that have a start date on or before this date and have a \"Failed\" status.",
"label": "End Date",
"placeholder": "",
"required": true
Expand All @@ -116,7 +116,7 @@
"config": {
"default": "",
"description": "",
"helpText": "Retry all Workflow executions that have a start time before this time and have a \"Failed\" status. You must use the following format: hh:mm:ss.",
"helpText": "Retry all Workflow executions that have a start time on or before this time and have a \"Failed\" status. You must use the following format: hh:mm:ss.",
"label": "End Time",
"placeholder": "13:16:24",
"required": true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"Compare Timestamps 1": {
"choiceList": [
{
"comparator": "TimestampGreaterThan",
"comparator": "TimestampGreaterThanEquals",
"nextStep": "HTTP Request 4",
"variableA.$": "$.hTTPRequest.body[100].startTime",
"variableB.$": "$.trigger.start"
Expand All @@ -41,10 +41,10 @@
"attributes": {
"authenticationType": "OAuth",
"method": "get",
"oAuthClientId": "535f24d1236f4da1a663410e6cc8cee7",
"oAuthClientId": "",
"oAuthClientSecret": "",
"oAuthTokenUrl": "https://devrel.api.identitynow.com/oauth/token",
"url": "https://devrel.api.identitynow.com/v3/workflows/{{$.trigger.workflowId}}/executions?filters=status%20eq%20\"Failed\"%20and%20start_time%20lt%20\"{{$.trigger.end}}\""
"oAuthTokenUrl": "https://tenant.api.identitynow.com/oauth/token",
"url": "https://tenant.api.identitynow.com/v3/workflows/{{$.trigger.workflowId}}/executions?filters=status%20eq%20\"Failed\"%20and%20start_time%20le%20\"{{$.trigger.end}}\""
},
"description": "Get all failed executions with a start time that is less than the end date.",
"displayName": "Get Failed Executions",
Expand All @@ -63,11 +63,11 @@
"workflowId": "{{$.trigger.workflowId}}"
},
"method": "post",
"oAuthClientId": "128f6d07-8b68-468c-be14-876648c2c12d",
"oAuthClientId": "",
"oAuthClientSecret": "",
"oAuthTokenUrl": "https://devrel.api.identitynow.com/oauth/token",
"oAuthTokenUrl": "https://tenant.api.identitynow.com/oauth/token",
"requestContentType": "json",
"url": "https://devrel.api.identitynow.com/beta/workflows/execute/external/ba067050-3a26-4bda-995d-55717da4ebeb"
"url": "https://tenant.api.identitynow.com/beta/workflows/execute/external/ba067050-3a26-4bda-995d-55717da4ebeb"
},
"description": "Invoke this workflow again with a modified end date that the same date as the last item processed in this invocation. This ensures the next iteration of this workflow will not process the same items again.",
"displayName": "Process next 100",
Expand All @@ -85,14 +85,14 @@
"Compare Timestamps": {
"choiceList": [
{
"comparator": "TimestampGreaterThan",
"comparator": "TimestampGreaterThanEquals",
"nextStep": "HTTP Request 2",
"variableA.$": "$.loop.loopInput.startTime",
"variableB.$": "$.loop.context.start"
}
],
"defaultStep": "End Step - Success",
"description": "Make sure the execution's start date is after the start time provided in the trigger input. We don't want to retry failed workflows that are outside of the start/end time provided.",
"description": "Make sure the execution's start date is on or after the start time provided in the trigger input. We don't want to retry failed workflows that are outside of the start/end time provided.",
"displayName": "Is execution after start date",
"type": "choice"
},
Expand All @@ -110,11 +110,11 @@
"authenticationType": "OAuth",
"jsonRequestBody.$": "$.hTTPRequest2.body[?(@.type == \"WorkflowExecutionStarted\")].attributes",
"method": "post",
"oAuthClientId": "535f24d1236f4da1a663410e6cc8cee7",
"oAuthClientId": "",
"oAuthClientSecret": "",
"oAuthTokenUrl": "https://devrel.api.identitynow.com/oauth/token",
"oAuthTokenUrl": "https://tenant.api.identitynow.com/oauth/token",
"requestContentType": "json",
"url": "https://devrel.api.identitynow.com/v3/workflows/{{$.loop.context.workflowId}}/test"
"url": "https://tenant.api.identitynow.com/v3/workflows/{{$.loop.context.workflowId}}/test"
},
"description": "Retry the failed workflow execution by executing the workflow test endpoint and providing the original input to the trigger.",
"displayName": "Retry Failed Workflow",
Expand All @@ -127,10 +127,10 @@
"attributes": {
"authenticationType": "OAuth",
"method": "get",
"oAuthClientId": "535f24d1236f4da1a663410e6cc8cee7",
"oAuthClientId": "",
"oAuthClientSecret": "",
"oAuthTokenUrl": "https://devrel.api.identitynow.com/oauth/token",
"url": "https://devrel.api.identitynow.com/v3/workflow-executions/{{$.loop.loopInput.id}}/history"
"oAuthTokenUrl": "https://tenant.api.identitynow.com/oauth/token",
"url": "https://tenant.api.identitynow.com/v3/workflow-executions/{{$.loop.loopInput.id}}/history"
},
"description": "Get the details of the individual execution, which will include the original input provided to the failed execution's trigger.",
"displayName": "Get Execution Details",
Expand Down Expand Up @@ -167,7 +167,7 @@
"attributes": {
"clientId": "128f6d07-8b68-468c-be14-876648c2c12d",
"description": "This trigger requires a workflowId, start, end, and email.",
"url": "https://devrel.api.identitynow.com/beta/workflows/execute/external/ba067050-3a26-4bda-995d-55717da4ebeb"
"url": "https://tenant.api.identitynow.com/beta/workflows/execute/external/ba067050-3a26-4bda-995d-55717da4ebeb"
}
}
}