Solved

List Pipeline Stages

  • 11 January 2023
  • 6 replies
  • 47 views

Is it possible to list the stages of an existing pipeline once you have the existing pipeline in the builder?

icon

Best answer by saleempothiwala 12 January 2023, 10:22

View original

6 replies

Userlevel 4
Badge

hi @songforwhoever 

 

Yes, it is possible to do so using the Python SDK for StreamSets.

More help here: https://docs.streamsets.com/platform-sdk/latest/index.html

hi @songforwhoever 

 

Yes, it is possible to do so using the Python SDK for StreamSets.

More help here: https://docs.streamsets.com/platform-sdk/latest/index.html

 

Thanks, can you be more specific on where I can found out how to do this? I’ve looked through the documentation but not found anything - maybe it’s how I’m searching for it that’s the problem

Userlevel 4
Badge

@songforwhoever 

 

What is the version of your Control Hub?

CH 3.19.2
Userlevel 4
Badge

@songforwhoever 

 

You can find more information here: https://docs.streamsets.com/sdk/latest/index.html

You will have to get your SDK activation code from StreamSets Support.

pip3 install streamsets~=3.0 

python3

from streamsets.sdk import ControlHub

sch = ControlHub('<YOUR CONTROL HUB URL>', '<YOUR USERNAME>', '<YOUR PASSWORD>')
#Gets instance of your SCH


pipeline = control_hub.pipelines.get(name = '<YOUR PIPELINE NAME>')
#gets instance of your pipeline

pipeline.stages
#this will give you list of all the stages

 

@songforwhoever

 

You can find more information here: https://docs.streamsets.com/sdk/latest/index.html

You will have to get your SDK activation code from StreamSets Support.

pip3 install streamsets~=3.0 

python3

from streamsets.sdk import ControlHub

sch = ControlHub('<YOUR CONTROL HUB URL>', '<YOUR USERNAME>', '<YOUR PASSWORD>')
#Gets instance of your SCH


pipeline = control_hub.pipelines.get(name = '<YOUR PIPELINE NAME>')
#gets instance of your pipeline

pipeline.stages
#this will give you list of all the stages

 

Fantastic, Thank you @saleempothiwala - that’s really useful.

Reply