Applications grow, specs change, bugs happen, and our code can quickly get out of hand. Duplicated code, ifs, elses, switches, and statements like “I used this there, but it needs to be slightly different here”, help turn our work of art into a garbled mess. But what if we could fix that?
That’s where Pipelines come in. We can break out our code into smaller chunks, called stages, that we can group or combine into configurations called pipelines. Separating our code into stages allows for easier and isolated testing. Reassembling stages sequentially into a pipeline allows us to have consistent results.
In this talk, we’ll define what stages and pipelines are. We'll examine when pipelines can help us and when they are not the right solution. We will look at example pipelines ranging from simple to multi-stage reusable pipelines. We'll implement what we've learned by walking through a refactor and discover how testing becomes easier with stages. You will walk away with an understanding of the what the Pipeline pattern is and when it can benefit your application.
Support our efforts (and help us have food) by donating here: https://opencollective.com/upstatephp