Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make timeout configurable #112

Open
trgill opened this issue Jun 30, 2021 · 1 comment
Open

make timeout configurable #112

trgill opened this issue Jun 30, 2021 · 1 comment

Comments

@trgill
Copy link
Contributor

trgill commented Jun 30, 2021

@prajnoha this comment is for when we've got re-usable workers? Currently the kill() won't block, so we don't need a timeout here. (?)

/* FIXME: Make timeout configurable. If timeout is set to zero, exit worker right away - call

/* FIXME: Make timeout configurable. If timeout is set to zero, exit worker right away - call
_make_worker_exit.
	*
timeout_usec = util_get_now_usec(CLOCK_MONOTONIC) + DEFAULT_WORKER_IDLE_TIMEOUT_USEC;
sid_resource_create_time_event_source(chan->owner, &worker_proxy->idle_timeout_es, CLOCK_MONOTONIC,
				                                  timeout_usec, 0, _on_worker_proxy_idle_timeout_event, "idle
timeout", chan->owner); _change_worker_proxy_state(chan->owner, WORKER_STATE_IDLE);
*/
@prajnoha
Copy link
Member

prajnoha commented Jul 1, 2021

Yes, indeed, this is for the case when we have reusable workers in place (the pool of workers). And if the worker in the pool stays unused for certain configured time, we'd terminate it...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants