Getting your hands dirty
You can now block tasks from being executed depending on some values found in parameters or results. You are ready to test your knowledge with the following exercises. To complete the challenges, you will need to use the concepts introduced here and notions from the previous chapters.
As usual, you can find the solutions to these exercises at the end of this book, in the Assessment section.
Hello Admin
Build a pipeline that will take a username as a parameter. If the username is admin
, log the text Hello Admin
. For any other username, output a simple Hello
message.
Tips
- This exercise is similar to the example you just did.
- Use the logger
task to output messages.
- You will need two tasks, each with a different when expression.
Critical Hit
In role-playing games using dice, rolling a 20 on a 20-sided die is sometimes referred to as rolling a critical hit. For this exercise, build a pipeline that would log Critical Hit...