-
Notifications
You must be signed in to change notification settings - Fork 806
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(core): handle null when invoking pipelines with stages that are m…
…issing a "type" so callers see 400 with a helpful mesage instead of 500. There's also code here in PipelineBuilder.withStages to throw an IllegalArgumentException for null stages. Due to [this change](https://github.com/spinnaker/orca/pull/4102/files#diff-88a2bb8f8eddf44a88866f3d27f096d67577c6c5f651acd88fdb3da32ed88d0aR211), PipelineBuilder.withStages isn't called with null even if stages is null in the incoming pipeline. #4182 (Nov 30, 2021, version 1.28.0) was a behavior change from a NullPointerException/500 to succeed (but do nothing) for a pipeline with null stages. #4102 (Jan 3, 2022) was also part of version 1.28.0. Changing the behavior to explictly reject null stages / respond with 400 instead of accepting them and doing nothing feels better, but I'll leave that for a separate PR as it's potentially more controversial.
- Loading branch information
Showing
3 changed files
with
27 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters