Skip to content

Commit 8052de7

Browse files
author
Raunak Bhagat
authored
[FEAT] Add ability to download log files from ray-cluster (Eventual-Inc#3406)
# Overview - when submitting the job to the ray cluster, the extra `DAFT_ENABLE_RAY_TRACING` env-var is set to `"1"` - this will produce custom daft logs - these log files are rsync'd down from the ray cluster, packaged up, and sent back to the GHA Summary Page (from where they can be downloaded by the user) ## Notes When running the job on the ray-cluster, daft logs are *not* being generated. Only ray logs are being generated. This is something that will need to be investigated and resolved later. For now, will request to have it merged, since everything else still works (we can still grab ray logs, which is quite useful in and of itself).
1 parent b6706d9 commit 8052de7

File tree

1 file changed

+26
-1
lines changed

1 file changed

+26
-1
lines changed

.github/workflows/run-cluster.yaml

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,34 @@ jobs:
7878
echo 'Invalid command submitted; command cannot be empty'
7979
exit 1
8080
fi
81-
ray job submit --working-dir ${{ inputs.working_dir }} --address http://localhost:8265 -- ${{ inputs.command }}
81+
ray job submit \
82+
--working-dir ${{ inputs.working_dir }} \
83+
--address http://localhost:8265 \
84+
--runtime-env-json '{"DAFT_RUNNER": "ray", "DAFT_ENABLE_RAY_TRACING": "1"}' \
85+
-- ${{ inputs.command }}
86+
- name: Download log files from ray cluster
87+
run: |
88+
source .venv/bin/activate
89+
ray rsync-down .github/assets/benchmarking_ray_config.yaml /tmp/ray/session_*/logs ray-daft-logs
90+
- name: Kill connection to ray cluster
91+
run: |
92+
PID=$(lsof -t -i:8265)
93+
if [[ -n "$PID" ]]; then
94+
echo "Process $PID is listening on port 8265; killing it..."
95+
kill -9 "$PID"
96+
if [[ $? -eq 0 ]]; then
97+
echo "Process $PID killed successfully"
98+
else
99+
echo "Failed to kill process $PID"
100+
fi
101+
fi
82102
- name: Spin down ray cluster
83103
if: always()
84104
run: |
85105
source .venv/bin/activate
86106
ray down .github/assets/benchmarking_ray_config.yaml -y
107+
- name: Upload log files
108+
uses: actions/upload-artifact@v4
109+
with:
110+
name: ray-daft-logs
111+
path: ray-daft-logs

0 commit comments

Comments
 (0)