Skip to content
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

[job submission] Add driver exit code in JobInfo #31183

Closed
MissiontoMars opened this issue Dec 19, 2022 · 3 comments · Fixed by #39675
Closed

[job submission] Add driver exit code in JobInfo #31183

MissiontoMars opened this issue Dec 19, 2022 · 3 comments · Fixed by #39675
Assignees
Labels
core Issues that should be addressed in Ray Core enhancement Request for new feature and/or capability P1 Issue that should be fixed within a few weeks

Comments

@MissiontoMars
Copy link

Description

The query result of jobs through job submission api curl 'http://0.0.0.0:8266/api/jobs/' looks like:

  {
    "type": "SUBMISSION",
    "entrypoint": "python3.9 case1.py",
    "job_id": "02000000",
    "submission_id": "raysubmit_tndCXjZtTT13X7jD",
    "driver_info": {
      "id": "02000000",
      "node_ip_address": "127.0.0.1",
      "pid": "94633"
    },
    "status": "SUCCEEDED",
    "message": "Job finished successfully.",
    "error_type": null,
    "start_time": 1671433867107,
    "end_time": 1671434381364,
    "metadata": {},
    "runtime_env": {
      "working_dir": "gcs://_ray_pkg_1c2d7859d752eb23.zip",
      "env_vars": {
        "RAY_BACKEND_LOG_LEVEL": "debug"
      }
    }
  }

In our use case, ray job users want to obtain the driver's exit code which represents the actual exit reason of the job. For example, the driver process exit with code 100, which means OOM occurs in the job.

However, the existing query result from job submission api is lack of driver exit code.

There are maybe two possible solutions:

  1. add driver exit code field in JobInfo
  2. reuse the existing message field, but need to make it structured, currently it is just a string that contains part of the job log

I'm glad to submit a PR if the feature makes sense.

Use case

No response

@MissiontoMars MissiontoMars added the enhancement Request for new feature and/or capability label Dec 19, 2022
@MissiontoMars
Copy link
Author

@alanwguo @architkulkarni Please evaluate whether this feature makes sense.

@rkooo567
Copy link
Contributor

We should definitely do this. We (cc @rickyyx) are also planning to expose exit code of workers

@rkooo567 rkooo567 added P1 Issue that should be fixed within a few weeks core Issues that should be addressed in Ray Core labels Dec 19, 2022
@rkooo567
Copy link
Contributor

I'd love to shepherd the PR if you submit one @MissiontoMars

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Issues that should be addressed in Ray Core enhancement Request for new feature and/or capability P1 Issue that should be fixed within a few weeks
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants