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
support creating ForkJoinPools with maximumPoolSize #483
Comments
I think it makes sense to solve this when we get multi-jar-release working so we can target jdk 9+ in a principled fashion. For this reason I think removing it from the 1.1.0-M2 milestone makes sense as I seriously doubt that we will get multi-jar-release working by then, @He-Pin @pjfanning do you agree? |
IIRC, the multi-jar-release has bad IDE support, and @Glavo once told me about that too, for me the current implementation seems good, so does netty work this way, another library like reactor-core is using the multi-jar-release mechanism. |
I don't believe in dropping useful features because one implementation that can't be done is preferred over one that is ready to go. |
I am not saying that the feature should be dropped in general, just that the current implementation has a lot of unanswered questions and considering that the version with multi-jar-release would be trivial in comparison that might be preferrable. Also since we are dealing with JDK9 specifically, we have machinery in place in Pekko to compile classes just for JDK 9
IDE support is low priority compared to everything else and the version with reflection is much harder to understand/read code wise. |
@mdedetrich Netty's |
Android supports JDK 1.8+ which means it will ignore java 9 compiled classes in the multi-release-jar (its the java-9 compiled classes which will be a non standard location). In other words it will work fine
I am not saying that its a blocker, just that multi-jar-release may already be done before the feature is complete |
Some methods are missing on Android, AFAIK, we will see. |
@mdedetrich It will be contagious when user packaging shadow jars, @Glavo just told me。 |
I don't think this is a good reason not to use MR jars. Good shading tools support MR jars. |
We already depend on jackson-core which is an MR jar. |
Agreed, I don't know what the aversion to multi release jar's comes from but its well support and a lot of critical Java OS libraries use it. The issues currently with multi release jar's are more sbt specific and this is largely a historical artifact (which is that any new functionality in later JDK's typically had their own equivalent idiomatic Scala specific solution so there wasn't much incentive to support multi-release-jars in sbt as there was very little demand for it). |
@He-Pin I'm open to pressing to get this into 1.1. My view is that user need outweighs implementation niceties. Do you need this change? |
@pjfanning Yes, I'm using Pekko in several of our mission-critical systems, so I would like to keep my systems safe. If we like, we can re-implement it later with multi-jar-release. |
ForkJoinPool has extra contructors in JDK9+ that allow maximumPoolSize to be set.
Relates to #482
Pekko still supports JDK8 so implementing this is not straightforward.
Options include:
fork-join-executor-jdk9
which is similar tofork-join-executor
but supports the extramaximumPoolSize
config (the class for this could be added to jdk9+ build (we support having a scala-jdk9 source directory)fork-join-executor
support themaximumPoolSize
but ignore it or fail if Java 8 runtime is used. We might need to use Java reflection to do this.The text was updated successfully, but these errors were encountered: