mirror of
https://github.com/wassname/ray.git
synced 2026-08-10 12:30:14 +08:00
[serve] Remove start_server flag (#8620)
This commit is contained in:
@@ -62,7 +62,6 @@ def accept_batch(f):
|
||||
|
||||
def init(cluster_name=None,
|
||||
blocking=False,
|
||||
start_server=True,
|
||||
http_host=DEFAULT_HTTP_HOST,
|
||||
http_port=DEFAULT_HTTP_PORT,
|
||||
ray_init_kwargs={
|
||||
@@ -84,8 +83,6 @@ def init(cluster_name=None,
|
||||
specified in all subsequent serve.init() calls.
|
||||
blocking (bool): If true, the function will wait for the HTTP server to
|
||||
be healthy, and other components to be ready before returns.
|
||||
start_server (bool): If true, `serve.init` starts http server.
|
||||
(Default: True)
|
||||
http_host (str): Host for HTTP server. Default to "0.0.0.0".
|
||||
http_port (int): Port for HTTP server. Default to 8000.
|
||||
ray_init_kwargs (dict): Argument passed to ray.init, if there is no ray
|
||||
@@ -126,10 +123,9 @@ def init(cluster_name=None,
|
||||
master_actor = ServeMaster.options(
|
||||
name=master_actor_name,
|
||||
max_restarts=-1,
|
||||
).remote(cluster_name, start_server, http_node_id, http_host, http_port,
|
||||
metric_exporter)
|
||||
).remote(cluster_name, http_node_id, http_host, http_port, metric_exporter)
|
||||
|
||||
if start_server and blocking:
|
||||
if blocking:
|
||||
block_until_http_ready("http://{}:{}/-/routes".format(
|
||||
http_host, http_port))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user