HIVE-30091: Fix K8s operator LLAP/TezAM replica resolution when autos… - #6814
Merged
Merged
Conversation
…caling is disabled
Contributor
Author
|
CC: @ayushtkn |
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
One or more issues must be addressed before approval.
Get a fresh assessment by requesting another Copilot review.
Review effort: Lite
Findings: 1
Open (1)
What changed in this PR
Updates the Kubernetes operator’s replica resolution so static replica settings are honored when autoscaling is disabled.
Changes:
- Cleans managed replica values for non-autoscaled components.
- Limits wake-up state initialization to autoscaled components.
- Adds managed-replica cleanup support.
| File | Description |
|---|---|
| packaging/src/kubernetes/src/java/org/apache/hive/kubernetes/operator/reconciler/HiveClusterReconciler.java | Updated as part of this pull request. |
| packaging/src/kubernetes/src/java/org/apache/hive/kubernetes/operator/dependent/HiveDependentResource.java | Updated as part of this pull request. |
| packaging/src/kubernetes/src/java/org/apache/hive/kubernetes/operator/autoscaling/HiveClusterAutoscaler.java | Updated as part of this pull request. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+88
to
+89
| public static void cleanupManagedReplicas(String namespace, String clusterName, String component) { | ||
| MANAGED_REPLICAS.remove(cacheKey(namespace, clusterName, component)); |
deniskuzZ
reviewed
Sep 23, 2026
| } | ||
| } | ||
|
|
||
| private static void resetComponentAutoscalingState(HiveClusterAutoscaler scaler, |
Member
There was a problem hiding this comment.
consider renaming to clearAutoscalingState, not to shadow the instance method it calls
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.




…caling is disabled
What changes were proposed in this pull request?
Clean up stale autoscaling state per-component when autoscaling has been disabled
Why are the changes needed?
To Fix the case where suspend/wake and toggling autoscaling off caused wrong replica state
Does this PR introduce any user-facing change?
No
How was this patch tested?
Manual Testing