dongjoon-hyun opened a new pull request, #913:
URL: https://github.com/apache/spark-kubernetes-operator/pull/913

   ### What changes were proposed in this pull request?
   
   This PR aims to call `GenericRetry.withoutMaxInterval()` when 
`spark.kubernetes.operator.reconciler.retry.maxIntervalSeconds` is 
non-positive, which is the default (`-1`). This PR also fixes the log message 
of this case from `unlimited max attempts` to `unlimited max interval`.
   
   ### Why are the changes needed?
   
   The documentation says `Set to non-positive for unlimited.`, but the retry 
interval is capped at 15187ms in this case. 
`SparkOperatorConf.getOperatorRetry()` skips `setMaxInterval()` for 
non-positive values, so `GenericRetry` keeps the JOSDK default, 
`GradualRetry.DEFAULT_MAX_INTERVAL` (`2000ms * 1.5^5`). JOSDK applies the cap 
only when the max interval is greater than `-1`, and `withoutMaxInterval()` 
sets it to `-1`.
   
   In addition, the log message says `max attempts` although this case is about 
the max interval.
   
   ### Does this PR introduce _any_ user-facing change?
   
   Yes. All releases from 
[v0.1.0](https://github.com/apache/spark-kubernetes-operator/releases/tag/v0.1.0)
 (2025-05-04) to 
[1.0.0](https://github.com/apache/spark-kubernetes-operator/releases/tag/1.0.0) 
(2026-07-23) cap the reconciler retry interval at 15187ms by default. With the 
other default configurations (15 max attempts, 5s initial interval, and 1.5 
multiplier), the retry delays change like the following.
   
   - Before: 5s, 5s, 7.5s, 11.25s, and then 15.187s for the remaining 11 
retries (about 3.3 minutes in total)
   - After: 5s, 5s, 7.5s, 11.25s, 16.875s, ..., up to about 16.2 minutes for 
the last retry (about 48.6 minutes in total)
   
   Users can set 
`spark.kubernetes.operator.reconciler.retry.maxIntervalSeconds` to `15` to keep 
a similar cap.
   
   ### How was this patch tested?
   
   Pass the CIs with the newly added test cases in `SparkOperatorConfTest`. 
Without the main code change, `testOperatorRetryWithoutMaxIntervalByDefault` 
fails with `expected: <-1> but was: <15187>`.
   
   ### Was this patch authored or co-authored using generative AI tooling?
   
   Generated-by: Claude Opus 5.5


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to