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

Call services initializer from BootstrapPipeline #236

Open
isra17 opened this issue Oct 26, 2022 · 0 comments
Open

Call services initializer from BootstrapPipeline #236

isra17 opened this issue Oct 26, 2022 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@isra17
Copy link
Member

isra17 commented Oct 26, 2022

Right now if a service need to run initialization code in the executor worker, it's somewhat difficult or hackish.

We added hooks.on_executor_initialized, but many executor (ARQ, Ray) don't support it.

Right now, we actually rely on the executor to call services initializer (ie.

initialize_hook.register(logger.on_executor_initialized)
)

It would be better if we extend BootstrapPipeline that take care of this. All executor have to instantiate this call to execute message. We could rely on this to ensure that the worker had initialized the services. It might require the executor worker to load Saturn config and pass it to the bootstrapper and let the services define a open_in_executor and remove the partly supported on_executor_initialized.

@isra17 isra17 added enhancement New feature or request good first issue Good for newcomers labels Oct 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant