[serve] Remove start_server flag (#8620)

This commit is contained in:
Edward Oakes
2020-05-26 14:34:18 -05:00
committed by GitHub
parent b3d686b78f
commit 137519e19d
2 changed files with 6 additions and 12 deletions
+2 -6
View File
@@ -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))