playframework / playframework/play-ws
Incorrect reflection-config.json for shaded-asynchttpclient?
Nobody has claimed this yet.
- Dominant language
- Scala
- Stars
- 224
- Forks
- 92
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 28
Description
I'm using sbt-native-packager to build a graalvm-native image
https://www.scala-sbt.org/sbt-native-packager/formats/graalvm-native-image.html
Play WS Version (2.5.x / etc)
2.1.3
API (Scala / Java / Neither / Both)
Scala
Operating System (Ubuntu 15.10 / MacOS 10.10 / Windows 10)
MacOS 11.4
JDK (Oracle 1.8.0_72, OpenJDK 1.8.x, Azul Zing)
openjdk 16.0.1 2021-04-20
OpenJDK Runtime Environment GraalVM CE 21.1.0 (build 16.0.1+9-jvmci-21.1-b05)
OpenJDK 64-Bit Server VM GraalVM CE 21.1.0 (build 16.0.1+9-jvmci-21.1-b05, mixed mode, sharing)
Expected Behavior
Native image compilation works as expected
Actual Behavior
> show graalvm-native-image:packageBin
...
[error] Error: Error parsing reflection configuration in jar:file:/Users/xxx/Library/Caches/Coursier/v1/https/repo1.maven.org/maven2/com/typesafe/play/shaded-asynchttpclient/2.1.3/shaded-asynchttpclient-2.1.3.jar!/META-INF/native-image/io.netty/transport/reflection-config.json:
[error] Could not resolve io.netty.channel.socket.nio.NioServerSocketChannel for reflection configuration. Reason: java.lang.ClassNotFoundException: io.netty.channel.socket.nio.NioServerSocketChannel. To allow unresolvable reflection configuration, use option -H:+AllowIncompleteClasspath
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the failure with graalvm-native-image:packageBin and inspect META-INF/native-image/io.netty/transport/reflection-config.json inside the shaded-asynchttpclient 2.1.3 jar. Check why the configuration references io.netty.channel.socket.nio.NioServerSocketChannel when compiling the native image; done means native image compilation completes without this reflection-configuration error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, scala
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100