-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Cherry pick #3627 from Cadence #839
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
Conversation
|
|
||
| maxCassandraTTL = int64(630720000) // Cassandra TTL maximum, 20 years in second | ||
| // ref: https://docs.datastax.com/en/dse-trblshoot/doc/troubleshooting/recoveringTtlYear2038Problem.html | ||
| maxCassandraTTL = int64(315360000) // Cassandra max support time is 2038-01-19T03:14:06+00:00. Updated this to 10 years to support until year 2028 |
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.
Why not:
func maxCassandraTTL() int64 {
return (time.Date(2038,01,19,03,14,06,0,time.UTC).Sub(time.Now().UTC())).Milliseconds()
}
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.
We have default timeouts of 10 years.
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.
depending on whether we are still going to support Cassandra after 10 years
the solution from uber is much more simpler.
@samarabbas what do you think?
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.
Agreed with @wxing1292. The main issue is we need a concept of infinite timeout in Temporal. Using a default of 10 years introduces a scalability bottleneck. Here are couple of issues tracking this:
#358
#573
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.
This is not even 10 but 8 years. I don't understand why they picked up some random number instead of properly set to the real limit Cassandra gives us. It is used in 2 places only.
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.
well, I guess as long as the time is really long (far in the future), then it is ok? BTW, cadence picked 5 years...
What changed?
Why?
cadence-workflow/cadence#3627
How did you test it?
DB integration tests
Potential risks
N/A