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

feat: add blueprints for finally #25

Merged
merged 1 commit into from
Feb 4, 2025
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
22 changes: 22 additions & 0 deletions finally-failure-flow.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
id: finally-failure-flow
namespace: company.team

tasks:
- id: log
type: io.kestra.plugin.core.execution.Fail

finally:
- id: final_task
type: io.kestra.plugin.core.log.Log
message: "This task gets executed irrespective of whether the flow is successful or failed."

extend:
title: Using finally to run the task at the end of the failed flow
description: >-
This flow demonstrates that the tasks in the `finally` block gets executed even when the
flow has failed.
tags:
- Software Engineering
ee: false
demo: true
meta_description: This flow demonstrated finally task for failed flow.
24 changes: 24 additions & 0 deletions finally.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
id: finally
namespace: company.team

tasks:
- id: log
type: io.kestra.plugin.core.log.Log
message: "This flow executes successfully!"

finally:
- id: final_task
type: io.kestra.plugin.core.log.Log
message: "This task gets executed irrespective of whether the flow is successful or failed."


extend:
title: Using finally to run the task at the end of the flow
description: >-
This flow demonstrates that the tasks in the `finally` block gets executed even when all the
tasks in the flow are run successfully.
tags:
- Software Engineering
ee: false
demo: true
meta_description: This flow demonstrated finally task for successful flow.