mirror of
https://github.com/vale981/ray
synced 2025-03-10 05:16:49 -04:00

* putting large objects * add more checks * support large objects * fix test * fix linting * upgrade to latest arrow version * check malloc return code * print mmap file sizes * printing * revert to dlmalloc * add prints * more prints * add printing * printing * fix * update * fix * update * print * initialization * temp * fix * update * fix linting * comment out object_store_full tests * fix test * fix test * evict objects if dlmalloc fails * fix stresstests * Fix linting. * Uncomment large-memory tests. * Increase memory for docker image for jenkins tests. * Reduce large memory tests. * Further reduce large memory tests.
28 lines
704 B
Python
28 lines
704 B
Python
from __future__ import absolute_import
|
|
from __future__ import division
|
|
from __future__ import print_function
|
|
|
|
import os
|
|
import time
|
|
|
|
import ray
|
|
|
|
|
|
@ray.remote
|
|
def f():
|
|
time.sleep(0.1)
|
|
return ray.services.get_node_ip_address()
|
|
|
|
|
|
if __name__ == "__main__":
|
|
ray.init(redis_address=os.environ["RAY_REDIS_ADDRESS"])
|
|
# Check that tasks are scheduled on all nodes.
|
|
num_attempts = 30
|
|
for i in range(num_attempts):
|
|
ip_addresses = ray.get([f.remote() for i in range(1000)])
|
|
distinct_addresses = set(ip_addresses)
|
|
counts = [ip_addresses.count(address) for address in distinct_addresses]
|
|
print("Counts are {}".format(counts))
|
|
if len(counts) == 5:
|
|
break
|
|
assert len(counts) == 5
|