Skip to content

[KYUUBI #6884] [FEATURE] Support to reassign the batches to alternative kyuubi instance in case kyuubi instance lost #7037

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

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

George314159
Copy link
Contributor

Why are the changes needed?

Support to reassign the batches to alternative kyuubi instance in case kyuubi instance lost.
#6884

How was this patch tested?

Unit Test

Was this patch authored or co-authored using generative AI tooling?

No

@codecov-commenter
Copy link

codecov-commenter commented Apr 22, 2025

Codecov Report

Attention: Patch coverage is 0% with 132 lines in your changes missing coverage. Please review.

Project coverage is 0.00%. Comparing base (29b6076) to head (8565d4a).
Report is 7 commits behind head on master.

Files with missing lines Patch % Lines
...g/apache/kyuubi/session/KyuubiSessionManager.scala 0.00% 36 Missing ⚠️
...ache/kyuubi/server/KyuubiRestFrontendService.scala 0.00% 30 Missing ⚠️
...yuubi/client/api/v1/dto/ReassignBatchResponse.java 0.00% 26 Missing ⚠️
.../apache/kyuubi/server/api/v1/BatchesResource.scala 0.00% 16 Missing ⚠️
...kyuubi/client/api/v1/dto/ReassignBatchRequest.java 0.00% 13 Missing ⚠️
...ain/java/org/apache/kyuubi/client/BaseRestApi.java 0.00% 7 Missing ⚠️
...ache/kyuubi/server/api/v1/InternalRestClient.scala 0.00% 2 Missing ⚠️
...org/apache/kyuubi/session/KyuubiBatchSession.scala 0.00% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master   #7037    +/-   ##
=======================================
  Coverage    0.00%   0.00%            
=======================================
  Files         695     699     +4     
  Lines       42833   43138   +305     
  Branches     5833    5859    +26     
=======================================
- Misses      42833   43138   +305     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR implements a new feature to reassign batches to an alternative Kyuubi instance in case the original instance is lost. The changes include the addition of a new DTO class to encapsulate the response of the reassign operation.

  • Introduces ReassignBatchResponse DTO with fields for success and message
  • Implements standard methods like equals, hashCode, and toString for the new DTO
Files not reviewed (3)
  • kyuubi-server/src/main/scala/org/apache/kyuubi/server/api/v1/BatchesResource.scala: Language not supported
  • kyuubi-server/src/main/scala/org/apache/kyuubi/session/KyuubiSessionManager.scala: Language not supported
  • kyuubi-server/src/test/scala/org/apache/kyuubi/server/api/v1/BatchesResourceSuite.scala: Language not supported
Comments suppressed due to low confidence (1)

kyuubi-rest-client/src/main/java/org/apache/kyuubi/client/api/v1/dto/ReassignBatchResponse.java:26

  • [nitpick] Consider renaming 'msg' to 'message' in the DTO for improved clarity and consistency with common naming conventions.
private String msg = null;

@turboFei turboFei added this to the v1.11.0 milestone Apr 24, 2025
@turboFei
Copy link
Member

rebased the code

Copy link
Member

@turboFei turboFei left a comment

Choose a reason for hiding this comment

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

LGTM, cc @pan3793

@pan3793
Copy link
Member

pan3793 commented Apr 27, 2025

quite useful and nice feature for failure tolerance, I will take a closer look next week

@turboFei turboFei force-pushed the 6884 branch 2 times, most recently from bb66a58 to f004520 Compare May 3, 2025 05:13
@turboFei turboFei force-pushed the 6884 branch 3 times, most recently from 31ab721 to 5f87ab2 Compare May 3, 2025 23:50
@turboFei turboFei closed this May 4, 2025
@turboFei turboFei reopened this May 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants