Reduce reporter CPU (#6553)

* wip

* remove

* Update ray_constants.py
This commit is contained in:
Eric Liang 2019-12-19 22:21:30 -08:00 committed by GitHub
parent 97e8afacd3
commit de22cdb233
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 5 deletions

View file

@ -70,7 +70,6 @@ export interface NodeInfoResponse {
vms: number;
rss: number;
};
memory_full_info: null; // Currently unused as it requires superuser permission on some systems
}>;
}>;
log_counts: {

View file

@ -150,8 +150,8 @@ AUTOSCALER_UPDATE_INTERVAL_S = env_integer("AUTOSCALER_UPDATE_INTERVAL_S", 5)
AUTOSCALER_HEARTBEAT_TIMEOUT_S = env_integer("AUTOSCALER_HEARTBEAT_TIMEOUT_S",
30)
# The reporter will report its' statistics this often (milliseconds).
REPORTER_UPDATE_INTERVAL_MS = env_integer("REPORTER_UPDATE_INTERVAL_MS", 500)
# The reporter will report its statistics this often (milliseconds).
REPORTER_UPDATE_INTERVAL_MS = env_integer("REPORTER_UPDATE_INTERVAL_MS", 2500)
# Max number of retries to AWS (default is 5, time increases exponentially)
BOTO_MAX_RETRIES = env_integer("BOTO_MAX_RETRIES", 12)

View file

@ -112,8 +112,12 @@ class Reporter(object):
def get_workers():
return [
x.as_dict(attrs=[
"pid", "create_time", "cpu_percent", "cpu_times", "cmdline",
"memory_info", "memory_full_info"
"pid",
"create_time",
"cpu_percent",
"cpu_times",
"cmdline",
"memory_info",
]) for x in psutil.process_iter(attrs=["cmdline"])
if is_worker(x.info["cmdline"])
]