Skip to content

refactor: move shared job utilities to common module - #667

Open
Debashich wants to merge 1 commit into
kubeflow:mainfrom
Debashich:kep-107-common-job-utils
Open

refactor: move shared job utilities to common module#667
Debashich wants to merge 1 commit into
kubeflow:mainfrom
Debashich:kep-107-common-job-utils

Conversation

@Debashich

Copy link
Copy Markdown

What this PR does / why we need it

Implements KEP-107 by moving shared job-submission utilities used by the Trainer, Optimizer, and Spark clients into kubeflow.common.

Changes

  • Adds shared Kubernetes utilities for:

    • Job event retrieval
    • Pod log retrieval
    • Random name generation
  • Adds a shared Event dataclass to kubeflow.common.types.

  • Refactors Trainer, Optimizer, and Spark backends to use the common utilities.

  • Re-exports Event through Trainer types for compatibility.

  • Removes duplicated utility implementations and redundant tests.

  • Adds unit tests covering shared utilities, timeout handling, and pod log streaming.

This reduces duplication across the three clients and improves long-term maintainability and consistency.

Testing

  • make test-python642 tests passed
  • make verifyAll checks passed

Which issue(s) this PR fixes

Fixes #608

Checklist

@google-oss-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign andreyvelich for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@github-actions

Copy link
Copy Markdown
Contributor

🎉 Welcome to the Kubeflow SDK! 🎉

Thanks for opening your first PR! We're happy to have you as part of our community 🚀

Here's what happens next:

  • If you haven't already, please check out our Contributing Guide for repo-specific guidelines and the Kubeflow Contributor Guide for general community standards
  • Our team will review your PR soon! cc @kubeflow/kubeflow-sdk-team

Join the community:

Feel free to ask questions in the comments if you need any help or clarification!
Thanks again for contributing to Kubeflow! 🙏

Signed-off-by: Debashich <debashishsinha555@gmail.com>
@Debashich
Debashich force-pushed the kep-107-common-job-utils branch from afafc94 to 37f204d Compare July 26, 2026 19:50
@Debashich
Debashich marked this pull request as ready for review July 26, 2026 19:51
Copilot AI review requested due to automatic review settings July 26, 2026 19:51

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@Debashich

Copy link
Copy Markdown
Author

/cc @tariq-hasan @andreyvelich

The PR is ready for review. I’ve implemented KEP-107, added tests for the new shared common utilities, and verified the full test suite (642 passed) along with make verify.

Please take a look when you’re free. Thanks!

@google-oss-prow
google-oss-prow Bot requested a review from tariq-hasan July 26, 2026 19:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

KEP-107: Move shared utilities for job submission into common module

2 participants