Skip to content
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

Remove task max retry count config #3771

Merged
merged 3 commits into from
Jan 5, 2023

Conversation

yycptt
Copy link
Member

@yycptt yycptt commented Jan 4, 2023

What changed?

  • Remove task max retry count config and use a fixed value of 30.

Why?

  • The config is only used for determine when special task processing error log and task attempt metric should be emitted, not actually the maximum number of attempts. So removing this config and a fixed value should be good enough for this use case.

How did you test it?

Potential risks

Is hotfix candidate?

@yycptt yycptt requested a review from yux0 January 4, 2023 00:29
@yycptt yycptt requested a review from a team as a code owner January 4, 2023 00:29
@@ -209,7 +208,7 @@ func (e *executableImpl) HandleErr(err error) (retErr error) {
defer e.Unlock()

e.attempt++
if e.attempt > e.criticalRetryAttempt() {
if e.attempt > taskCriticalAttempts {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Log message is bad. "Critical" is already in the tag and number of attempts is missing (but might be useful):

e.logger.Error("Error processing task after number of attempts.", tag.Error(err), tag.Attempt(e.attempt), tag.OperationCritical)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure how useful # of attempts is in the log given that we have the attempt count metric. But I can add it.

Re. the message itself, I kinda agree. My main concern is oncall needs to memorize a new way for finding this important log (this message is used/searched a lot). So if it's not something you have strong opinion on, I'd like to leave it as is.

@yycptt yycptt merged commit a026002 into temporalio:master Jan 5, 2023
@yycptt yycptt deleted the remove-task-max-retry-count branch January 5, 2023 02:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants