slfan1989 commented on code in PR #1354: URL: https://github.com/apache/ratis/pull/1354#discussion_r2830617941
########## ratis-docs/src/site/markdown/configurations.md: ########## @@ -509,11 +509,28 @@ The follower's statemachine is responsible for fetching and installing snapshot | **Type** | string | | **Default** | 1ms,10, 1s,20, 5s,1000 | -"1ms,10, 1s,20, 5s,1000" means -The min wait time as 1ms (0 is not allowed) for first 10, -(5 iteration with 2 times grpc client retry), -next wait 1sec for next 20 retry (10 iteration with 2 times grpc client) -further wait for 5sec for max times ((5sec*980)/2 times ~= 40min) +Format: +`<classname>,<params...>` +If `<classname>` is omitted, it defaults to `MultipleLinearRandomRetry` for backward compatibility. + +Examples: +- `MultipleLinearRandomRetry,1ms,10,1s,20,5s,1000` +- `1ms,10,1s,20,5s,1000` (same as above) +- `ExponentialBackoffRetry,100ms,5s,100` + +For `MultipleLinearRandomRetry`, the parameter "1ms,10, 1s,20, 5s,1000" means +that the wait time is 1ms on average for the first 10 retries. +Then, it becomes 1s on average for next 20 retries +and 5s on average for the last 1000 retries. + +For `ExponentialBackoffRetry`, the parameter "100ms,5s,100" means +that the base wait time is 100ms, the maximum wait time is 5s +and the number of attempts is 100. +The wait time is min(2^(n-1) * 100ms, 5s) on average for the n-th retry. Review Comment: Thanks for the note! Since GitHub supports LaTeX, I agree it reads more clearly here. I’ve updated the markdown to use LaTeX for the min notation. <img width="1057" height="150" alt="image" src="https://github.com/user-attachments/assets/21d1b5c6-c01a-4ceb-9d99-ef9adb15800e" /> -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
