-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
[serve] Implement serve.build
#23232
Conversation
python/ray/serve/api.py
Outdated
|
||
parameter_group.append(deployment_parameters) | ||
|
||
internal_get_global_client().deploy_group(parameter_group, _blocking=blocking) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does deploy_group
return a RayServeHandle
as func signature says ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, not it doesn't. However, it also doesn't look like anything is using the public deploy_group
, so I'll remove it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dag part looks good to me, only nits.
with open(output_path, "w") as f: | ||
app.to_yaml(f) | ||
else: | ||
print(app.to_yaml(), end="") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not for this PR, but as a follow up it will be much more actionable to print other instructions for next step, such as providing a file path, or calling other clis to deployment the yaml file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lg, i noticed last green commit has 500+ added lines but after lastest commit it's 338, did any file got untracked ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM feel free to ignore my comment but would be a good check
attr_name = full_path[last_period_idx + 1 :] | ||
module_name = full_path[:last_period_idx] | ||
|
||
if ":" in full_path: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: check only one ":" exists?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added a conditional to handle this.
Why are these changes needed?
The Serve REST API relies on YAML config files to specify and deploy deployments. This change introduces
serve.build()
andserve build
, which translate Pipelines to YAML files.Related issue number
Closes #23137, closes #23138, and closes #23139.
Checks
scripts/format.sh
to lint the changes in this PR.Applications
' behavior.