Skip to content

[cherry-pick][2.58.0][Docs][KubeRay] Use RayJob sample YAML for History Server docs (#65505) - #65531

Merged
elliot-barn merged 1 commit into
ray-project:releases/2.58.0from
machichima:cherry-pick-65505-2.58.0
Aug 19, 2026
Merged

elliot-barn merged 1 commit into
ray-project:releases/2.58.0from
machichima:cherry-pick-65505-2.58.0

Conversation

@machichima

Copy link
Copy Markdown
Contributor

Description

Update the Ray History Server with KubeRay doc to use RayJob example, this is related to kuberay-project/kuberay#5150

Related issues

Link related issues: "Fixes #1234", "Closes #1234", or "Related to
#1234".

Additional information

Optional: Add implementation details, API changes, usage examples,
screenshots, etc.


(cherry picked from commit 23d0178)

Thank you for contributing to Ray! 🚀
Please review the Ray Contribution Guide before opening a pull request.

⚠️ Remove these instructions before submitting your PR.

💡 Tip: Mark as draft if you want early feedback, or ready for review when it's complete.

Description

Briefly describe what this PR accomplishes and why it's needed.

Related issues

Link related issues: "Fixes #1234", "Closes #1234", or "Related to #1234".

Additional information

Optional: Add implementation details, API changes, usage examples, screenshots, etc.

…roject#65505)

## Description
Update the Ray History Server with KubeRay doc to use RayJob example,
this is related to kuberay-project/kuberay#5150

## Related issues
> Link related issues: "Fixes ray-project#1234", "Closes ray-project#1234", or "Related to
ray-project#1234".

## Additional information
> Optional: Add implementation details, API changes, usage examples,
screenshots, etc.

---------

Signed-off-by: win5923 <[email protected]>
Signed-off-by: Jun-Hao Wan <[email protected]>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Nary Yeh <[email protected]>
(cherry picked from commit 23d0178)
Signed-off-by: machichima <[email protected]>
@machichima
machichima requested review from a team and andrewsykim as code owners August 17, 2026 14:47

@gemini-code-assist gemini-code-assist Bot 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.

Code Review

This pull request updates the KubeRay History Server user guide to transition the example deployment from a RayCluster to a RayJob with a collector sidecar, updating all relevant commands, manifests, and endpoint examples. The review feedback suggests using ${NAMESPACE:-default} instead of ${NAMESPACE} in the kubectl commands to prevent potential syntax errors or failures if the environment variable is unset.

export RAY_JOB=rayjob-historyserver-gcs

curl https://raw.githubusercontent.com/ray-project/kuberay/refs/heads/master/historyserver/config/raycluster-gcs.yaml | envsubst | kubectl apply -f -
curl https://raw.githubusercontent.com/ray-project/kuberay/refs/heads/master/historyserver/config/rayjob-gcs.yaml | envsubst | kubectl apply -n ${NAMESPACE} -f -

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.

medium

If the user runs this command in a new terminal session, the ${NAMESPACE} environment variable might be empty, which would cause kubectl apply -n -f - to fail with a syntax error. Using ${NAMESPACE:-default} provides a safe fallback to the default namespace.

Suggested change
curl https://raw.githubusercontent.com/ray-project/kuberay/refs/heads/master/historyserver/config/rayjob-gcs.yaml | envsubst | kubectl apply -n ${NAMESPACE} -f -
curl https://raw.githubusercontent.com/ray-project/kuberay/refs/heads/master/historyserver/config/rayjob-gcs.yaml | envsubst | kubectl apply -n ${NAMESPACE:-default} -f -

Check the RayJob status. The entrypoint script takes about a minute to finish:

```sh
kubectl get rayjob ${RAY_JOB}

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.

medium

To ensure consistency and support cases where the RayJob is deployed in a non-default namespace, include the namespace flag -n ${NAMESPACE:-default}.

Suggested change
kubectl get rayjob ${RAY_JOB}
kubectl get rayjob ${RAY_JOB} -n ${NAMESPACE:-default}


```sh
kubectl delete raycluster ${RAY_CLUSTER} -n ${NAMESPACE}
kubectl delete rayjob ${RAY_JOB} -n ${NAMESPACE}

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.

medium

Using ${NAMESPACE:-default} instead of ${NAMESPACE} ensures that the command does not fail with a syntax error if the NAMESPACE environment variable is unset in the current terminal session.

Suggested change
kubectl delete rayjob ${RAY_JOB} -n ${NAMESPACE}
kubectl delete rayjob ${RAY_JOB} -n ${NAMESPACE:-default}

@chiayi chiayi 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.

One thing I realized is that we don't have a variables and configurations chart for history server. So variables like session-cache-size and use-auth-token-mode aren't explained. We should maybe update the chart we already have or add another one?

@andrewsykim andrewsykim added the go add ONLY when ready to merge, run all tests label Aug 17, 2026
@ray-gardener ray-gardener Bot added docs An issue or change related to documentation core Issues that should be addressed in Ray Core community-contribution Contributed by the community labels Aug 17, 2026
@machichima machichima changed the title [Docs][KubeRay] Use RayJob sample YAML for History Server docs (#65505) [cherry-pick][2.58.0][Docs][KubeRay] Use RayJob sample YAML for History Server docs (#65505) Aug 18, 2026
@elliot-barn
elliot-barn merged commit d8277b5 into ray-project:releases/2.58.0 Aug 19, 2026
4 checks passed
rueian added a commit that referenced this pull request Aug 28, 2026
## Description
Follow up on:
-
#65531 (review)
- #65531 (comment)

Made following changes:
- add variables and configurations chart
- mention that "ALL" only works for 2.54+ versions

## Related issues

## Additional information
docs:
https://anyscale-ray--65580.com.readthedocs.build/en/65580/cluster/kubernetes/user-guides/kuberay-history-server.html

---------

Signed-off-by: machichima <[email protected]>
Signed-off-by: Nary Yeh <[email protected]>
Co-authored-by: Douglas Strodtman <[email protected]>
Co-authored-by: Rueian <[email protected]>
nadongjun pushed a commit to nadongjun/ray that referenced this pull request Oct 6, 2026
## Description
Follow up on:
-
ray-project#65531 (review)
- ray-project#65531 (comment)

Made following changes:
- add variables and configurations chart
- mention that "ALL" only works for 2.54+ versions

## Related issues

## Additional information
docs:
https://anyscale-ray--65580.com.readthedocs.build/en/65580/cluster/kubernetes/user-guides/kuberay-history-server.html

---------

Signed-off-by: machichima <[email protected]>
Signed-off-by: Nary Yeh <[email protected]>
Co-authored-by: Douglas Strodtman <[email protected]>
Co-authored-by: Rueian <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community-contribution Contributed by the community core Issues that should be addressed in Ray Core docs An issue or change related to documentation go add ONLY when ready to merge, run all tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants