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

Add close time in mutable state #2917

Merged
merged 5 commits into from
May 31, 2022
Merged

Add close time in mutable state #2917

merged 5 commits into from
May 31, 2022

Conversation

yux0
Copy link
Contributor

@yux0 yux0 commented May 28, 2022

What changed?
Add close time in mutable state

Why?
In some code path, we don't need to fetch complete event to get the close time.

How did you test it?
Unit tests

Potential risks

Is hotfix candidate?

@yux0 yux0 requested a review from a team as a code owner May 28, 2022 07:04
@yux0 yux0 requested review from yycptt and yiminc May 28, 2022 07:05
} else {
closeTime = completionEvent.GetEventTime()
}
closeTime = executionInfo.GetCloseTime()
Copy link
Member

Choose a reason for hiding this comment

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

I think we still need the fallback logic for at least one release?

Copy link
Member

Choose a reason for hiding this comment

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

Shall we call mutableState.GetWorkflowCloseTime as well here? or we don't care about compatibility for admin commands?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Cannot get the mutable state in admin service. I think I still need your get completion event here for compatibility.

service/history/workflow/mutable_state_impl.go Outdated Show resolved Hide resolved
} else {
closeTime = completionEvent.GetEventTime()
}
closeTime = executionInfo.GetCloseTime()
Copy link
Member

Choose a reason for hiding this comment

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

Shall we call mutableState.GetWorkflowCloseTime as well here? or we don't care about compatibility for admin commands?

@yux0 yux0 merged commit 00394e9 into temporalio:master May 31, 2022
@yux0 yux0 deleted the close-time branch May 31, 2022 22:01
Sushisource pushed a commit to Sushisource/temporal that referenced this pull request Jun 7, 2022
* Add close time in mutable state
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.

None yet

2 participants