log the observed status in redshift sensor #29274
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
this sensor only checks against the "wanted" status, and not other possibly terminal statuses.
So if the cluster takes an unexpected branch and ends up in a semi-terminal state, this is completely invisible, and would only fail with an uninformative timeout after a long time.
The "proper" fix would be to have a list of terminal states to check against, but I don't have enough redshift knowledge to know what's terminal in the long list of possible statuses:
So I'm taking this poor man's approach that'd at least allow us to get a sense of what happened from looking at the logs.
(also, since the sensor is very generic, I think it'd be super hard to do because
storage-fullfor instance could be terminal in some cases, except if we run a step to free space and are waiting on the cluster leaving that state ? So many possibilities...)