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

Ability to provide ExecutorService #51

Closed
Gee2113 opened this issue Feb 27, 2019 · 3 comments
Closed

Ability to provide ExecutorService #51

Gee2113 opened this issue Feb 27, 2019 · 3 comments
Milestone

Comments

@Gee2113
Copy link

Gee2113 commented Feb 27, 2019

In An EE managed environment such as thorntail, ideally youd use a provided managed executor so that the container can manage the creation of threads. Add the ability to provide executorservice/scheduledexceturservice in the Scheduler builder.

@kagkarlsson
Copy link
Owner

Thank you for your suggestion!

Am not very familiar with "EE-environments". What is the benfit of letting for example thorntail supply the executorservice?

@Gee2113
Copy link
Author

Gee2113 commented Feb 28, 2019

Thanks for the quick reply

The container will provide instances of ManagedExecutorService and ManagedScheduledExecutorService which means the tasks will be run in managed threads created by the containers threadfactory. This allows the continer to add hooks and pas contextual information to these threads etc. it also means that global settings such as thread pool size are adhered to for example. More info here if required: https://jcp.org/aboutJava/communityprocess/final/jsr236/index.html

@kagkarlsson
Copy link
Owner

Will add this in the upcoming release.

@kagkarlsson kagkarlsson added this to the 5.1 milestone Mar 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants