-
Notifications
You must be signed in to change notification settings - Fork 809
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(cfn): Add retries when force cache refreshing #3200
Conversation
For cache refreshing can fail for some reason (e.g. read timeout), but should generally succeed. This patch makes this task more reliable by retrying if there was a failure for 5 minutes. Signed-off-by: Xavi León <xavi.leon@adevinta.com>
import javax.annotation.Nonnull; | ||
import org.springframework.beans.factory.annotation.Autowired; | ||
import org.springframework.stereotype.Component; | ||
|
||
@Component | ||
public class CloudFormationForceCacheRefreshTask extends AbstractCloudProviderAwareTask | ||
implements Task { | ||
implements OverridableTimeoutRetryableTask { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just making sure that you intended this to be OverridableTimeoutRetryableTask
vs. RetryableTask
OverridableTimeoutRetryableTask
allow the timeout to be overridden by the user in the stage config, is that what you want?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One clarification, otherwise LGTM
Ah good point! Haven't thought about that. I don't think it needs to be configurable but I see no harm on it in case the default I chose doesn't apply. Is there any hidden reason to not making it configurable? I think I'm fine either way. |
no real reason/harm in having it configurable, @xavileon - just that it adds another point to think about when you're debugging a deploy that took way too long..? I will merge as is, and you can change it later if you want - unless you tell me otherwise - need to pull master and wait for travis anyway |
@spinnakerbot cherry-pick 1.16 |
Cherry pick successful: #3204 |
For cache refreshing can fail for some reason (e.g. read timeout), but should generally succeed. This patch makes this task more reliable by retrying if there was a failure for 5 minutes. Signed-off-by: Xavi León <xavi.leon@adevinta.com>
For cache refreshing the CloudFormation cache can fail for
some reason (e.g. read timeout), but should generally succeed.
This patch makes this task more reliable by retrying if there was
a failure for up to 5 minutes.