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

Possibility to have subflow fully included in flow (template-like behaviour) #2495

Closed
Ben8t opened this issue Nov 10, 2023 · 3 comments
Closed
Labels
enhancement New feature or request kind/customer-request Requested by one or more customers

Comments

@Ben8t
Copy link
Member

Ben8t commented Nov 10, 2023

Feature description

Problem

With the deprecation of templates, there are some flaws arising with the only use of Subflow:

  1. It doubles the number of execution. With templates, tasks were passed directly in the flow, like if they were written directly inside it. Before 1 flow = 1 exec. Now with subflow 1 flow = 2 exec. Making the executions lists overwhelming in the UI.

  2. Some users track billing information, with 1 namespace = 1 project. Using subflow here kind of make this billing wrong as one subflow can be used in many namespaces (so there is an overlap sometimes in the executions).

  3. Subflow have to be in the same namespace to have access to the same right (service account)

Possible Solutions

  • For the execution problem (1. & 2.):
    • can be handle with labels or filtering: bring a flag subflow on the flow, that allow to hide subflow from the list
    • add a included:true property to the io.kestra.core.tasks.flows.Flow :
id: parent
namespace: company.team

tasks:
  - id: call_subflow
    type: io.kestra.plugin.core.flow.Subflow
    namespace: company.team
    flowId: subflow
    inputs:
      user: Rick Astley
      favorite_song: Never Gonna Give You Up
    wait: true
    transmitFailed: true
    included: true 

Without this kind of flag, currently the flow will create two executions: one for the main flow, one for the subflow. The included property let the user to choose if the subflow can be "included" directly in the subflow - merging the old template behaviour into the subflow one; i.e. having only one execution for the thing.

@Ben8t Ben8t added the enhancement New feature or request label Nov 10, 2023
@Ben8t Ben8t added this to All issues Nov 10, 2023
@github-project-automation github-project-automation bot moved this to Backlog in All issues Nov 10, 2023
@anna-geller anna-geller moved this from Backlog to Ready in All issues Nov 16, 2023
@anna-geller anna-geller moved this from Ready to Won't do in All issues Nov 19, 2023
@anna-geller anna-geller moved this from Won't do to Ready in All issues Nov 20, 2023
@anna-geller anna-geller moved this from Ready to Backlog in All issues Nov 20, 2023
@anna-geller anna-geller modified the milestones: v0.15.0, v0.16.0 Dec 4, 2023
@anna-geller anna-geller removed this from All issues Dec 12, 2023
@anna-geller anna-geller added the kind/customer-request Requested by one or more customers label Feb 12, 2024
@anna-geller anna-geller modified the milestones: v0.16.0, v0.19.0 Feb 12, 2024
@anna-geller anna-geller modified the milestones: v0.19.0, v0.17.0 Mar 26, 2024
@anna-geller anna-geller modified the milestones: v0.17.0, v0.18.0 Apr 17, 2024
@npranav10
Copy link
Contributor

Hi Kestra Team,

I was going to open a similar issue. @Ben8t has perfectly described my thoughts about point 1. Any updates on this feature request ?

@anna-geller
Copy link
Member

@npranav10 you can see the estimate when something will be released in the Milestone on the right side below labels, this one is planned for 0.18 atm.

@github-project-automation github-project-automation bot moved this to Backlog in Issues Jun 10, 2024
@anna-geller anna-geller removed this from the v0.18.0 milestone Jul 23, 2024
@anna-geller
Copy link
Member

this proposal is great! To avoid breaking changes, confusion and too many properties in the Subflow task, we will handle it as a separate task as described here #6518 -- but 100% the same idea still 👍

@anna-geller anna-geller closed this as not planned Won't fix, can't repro, duplicate, stale Dec 18, 2024
@github-project-automation github-project-automation bot moved this from Backlog to Done in Issues Dec 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request kind/customer-request Requested by one or more customers
Projects
Status: Done
Development

No branches or pull requests

3 participants