-
Notifications
You must be signed in to change notification settings - Fork 165
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
AsyncFunc spawns new thread for each apply() call #324
Comments
Looks like it was partially fixed in #330 |
@0crat in |
Job |
@rultor release, tag is |
@g4s8 the problem seems to be fixed? |
@yegor256 sure, thanks |
Job |
+30 points just awarded to @fabriciofx, total is +60 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Creating new threads is expensive operation because it allocates a lot of memory, performs system-calls and register descriptors.
It would be better to create
Executors.newCachedThreadPool()
for async task (or maybe accept Executor as constructor argument) and submit tasks to it:The text was updated successfully, but these errors were encountered: