mirror of
https://github.com/wassname/ray.git
synced 2026-06-27 21:38:18 +08:00
Simplify put test and move it to failure tests. (#788)
This commit is contained in:
committed by
Philipp Moritz
parent
c394a65ffc
commit
37dafa4d14
+12
-4
@@ -565,8 +565,8 @@ def start_local_scheduler(redis_address,
|
||||
def start_objstore(node_ip_address, redis_address,
|
||||
object_manager_port=None, store_stdout_file=None,
|
||||
store_stderr_file=None, manager_stdout_file=None,
|
||||
manager_stderr_file=None, cleanup=True,
|
||||
objstore_memory=None):
|
||||
manager_stderr_file=None, objstore_memory=None,
|
||||
cleanup=True):
|
||||
"""This method starts an object store process.
|
||||
|
||||
Args:
|
||||
@@ -585,11 +585,11 @@ def start_objstore(node_ip_address, redis_address,
|
||||
manager_stderr_file: A file handle opened for writing to redirect
|
||||
stderr to. If no redirection should happen, then this should be
|
||||
None.
|
||||
objstore_memory: The amount of memory (in bytes) to start the object
|
||||
store with.
|
||||
cleanup (bool): True if using Ray in local mode. If cleanup is true,
|
||||
then this process will be killed by serices.cleanup() when the
|
||||
Python process that imported services exits.
|
||||
objstore_memory: The amount of memory (in bytes) to start the object
|
||||
store with.
|
||||
|
||||
Return:
|
||||
A tuple of the Plasma store socket name, the Plasma manager socket
|
||||
@@ -734,6 +734,7 @@ def start_ray_processes(address_info=None,
|
||||
redis_port=None,
|
||||
num_workers=None,
|
||||
num_local_schedulers=1,
|
||||
object_store_memory=None,
|
||||
num_redis_shards=1,
|
||||
worker_path=None,
|
||||
cleanup=True,
|
||||
@@ -762,6 +763,8 @@ def start_ray_processes(address_info=None,
|
||||
stores until there are num_local_schedulers existing instances of
|
||||
each, including ones already registered with the given
|
||||
address_info.
|
||||
object_store_memory: The amount of memory (in bytes) to start the
|
||||
object store with.
|
||||
num_redis_shards: The number of Redis shards to start in addition to
|
||||
the primary Redis shard.
|
||||
worker_path (str): The path of the source code that will be run by the
|
||||
@@ -895,6 +898,7 @@ def start_ray_processes(address_info=None,
|
||||
store_stderr_file=plasma_store_stderr_file,
|
||||
manager_stdout_file=plasma_manager_stdout_file,
|
||||
manager_stderr_file=plasma_manager_stderr_file,
|
||||
objstore_memory=object_store_memory,
|
||||
cleanup=cleanup)
|
||||
object_store_addresses.append(object_store_address)
|
||||
time.sleep(0.1)
|
||||
@@ -1026,6 +1030,7 @@ def start_ray_head(address_info=None,
|
||||
redis_port=None,
|
||||
num_workers=0,
|
||||
num_local_schedulers=1,
|
||||
object_store_memory=None,
|
||||
worker_path=None,
|
||||
cleanup=True,
|
||||
redirect_output=False,
|
||||
@@ -1051,6 +1056,8 @@ def start_ray_head(address_info=None,
|
||||
stores until there are at least num_local_schedulers existing
|
||||
instances of each, including ones already registered with the given
|
||||
address_info.
|
||||
object_store_memory: The amount of memory (in bytes) to start the
|
||||
object store with.
|
||||
worker_path (str): The path of the source code that will be run by the
|
||||
worker.
|
||||
cleanup (bool): If cleanup is true, then the processes started here
|
||||
@@ -1077,6 +1084,7 @@ def start_ray_head(address_info=None,
|
||||
redis_port=redis_port,
|
||||
num_workers=num_workers,
|
||||
num_local_schedulers=num_local_schedulers,
|
||||
object_store_memory=object_store_memory,
|
||||
worker_path=worker_path,
|
||||
cleanup=cleanup,
|
||||
redirect_output=redirect_output,
|
||||
|
||||
@@ -814,6 +814,7 @@ def _init(address_info=None,
|
||||
object_id_seed=None,
|
||||
num_workers=None,
|
||||
num_local_schedulers=None,
|
||||
object_store_memory=None,
|
||||
driver_mode=SCRIPT_MODE,
|
||||
redirect_output=False,
|
||||
start_workers_from_local_scheduler=True,
|
||||
@@ -845,6 +846,8 @@ def _init(address_info=None,
|
||||
provided if start_ray_local is True.
|
||||
num_local_schedulers (int): The number of local schedulers to start.
|
||||
This is only provided if start_ray_local is True.
|
||||
object_store_memory: The amount of memory (in bytes) to start the
|
||||
object store with.
|
||||
driver_mode (bool): The mode in which to start the driver. This should
|
||||
be one of ray.SCRIPT_MODE, ray.PYTHON_MODE, and ray.SILENT_MODE.
|
||||
redirect_output (bool): True if stdout and stderr for all the processes
|
||||
@@ -909,6 +912,7 @@ def _init(address_info=None,
|
||||
node_ip_address=node_ip_address,
|
||||
num_workers=num_workers,
|
||||
num_local_schedulers=num_local_schedulers,
|
||||
object_store_memory=object_store_memory,
|
||||
redirect_output=redirect_output,
|
||||
start_workers_from_local_scheduler=(
|
||||
start_workers_from_local_scheduler),
|
||||
@@ -931,6 +935,9 @@ def _init(address_info=None,
|
||||
if num_redis_shards is not None:
|
||||
raise Exception("When connecting to an existing cluster, "
|
||||
"num_redis_shards must not be provided.")
|
||||
if object_store_memory is not None:
|
||||
raise Exception("When connecting to an existing cluster, "
|
||||
"object_store_memory must not be provided.")
|
||||
# Get the node IP address if one is not provided.
|
||||
if node_ip_address is None:
|
||||
node_ip_address = services.get_node_ip_address(redis_address)
|
||||
|
||||
Reference in New Issue
Block a user