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

can i chain multiple pipelines together? #145

Open
serensoner opened this issue Jul 18, 2023 · 1 comment
Open

can i chain multiple pipelines together? #145

serensoner opened this issue Jul 18, 2023 · 1 comment

Comments

@serensoner
Copy link

i have a pipeline that looks like the following:

class InputParams(BaseModel):
    name: str

def foo(params: InputParams):
    print(params.name)

def all_printed():
    print('all printed, yay!')

names = ['bar', 'foo', 'foobar', 'barfoo']
register_pipeline(
    id="pipeline",
    tasks=[foo],
    params=InputParams,
    triggers=[
        Trigger(
            id=f'foo_{name}', name=f'foo_{name}', schedule=IntervalTrigger(days=1),
            params={'name': name}
        ) for name in names
    ],
)

I would ideally like to run a pipeline that goes like: foo('bar'), foo('foo'), foo('foobar'), foo('barfoo'), all_printed(). Is this possible, or should I create another pipeline, and "hope" that the previous one finished?

@lucafaggianelli
Copy link
Owner

At the moment is not possible, but it's something I'd like to support, so in the future you can create a foo pipeline with a matrix trigger #14 where you specify the list of arguments and then trigger the all_printed pipeline at the end of the foo pipeline #146

It's time for me to work on those 2 issues 🤦‍♂️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants