Skip to content

Conversation

@raviagarwal7
Copy link
Contributor

@raviagarwal7 raviagarwal7 commented Jun 18, 2021

Move byte buddy agent installation to a static block so
that the installation only happens once per JVM.

This ensures that the plugin works well with BUCK(and likewise) build
systems where multiple javac compilation tasks are started parallelly in
the same JVM. Without this, the JVM crashes nondeterministically.

This will also work well in the Gradle build system where one javac
task runs per JVM.

Also remove the unused net.java.dev.jna:jna:5.8.0 dependency.

Move bytebuddy agent installation to a static block so
that the installation only happens once per JVM.

This ensures that the plugin works well with BUCK(and likewise) build
systems where multiple javac compilation task is started parallely in
the same JVM. Without this the JVM crashes undeterministically.

This will also work well in gradle build system where once javac task
runs per JVM
@bsideup
Copy link
Owner

bsideup commented Jun 18, 2021

Hi @raviagarwal7,

Thanks! The JNA dependency isn't unused - ByteBuddy will use it to emulate attachment on JVMs where emulation is not provided OOTB.

Could you please revert that change? Happy to accept the PR once done!

@bsideup bsideup added the enhancement New feature or request label Jun 18, 2021
@bsideup bsideup merged commit 42089a4 into bsideup:master Jun 18, 2021
@bsideup
Copy link
Owner

bsideup commented Jun 18, 2021

@raviagarwal7 I reverted the JNA change and accepted your PR. Many thanks! I will release now, as I understand this is a blocker for you.

@bsideup bsideup added this to the 0.4.1 milestone Jun 18, 2021
@bsideup
Copy link
Owner

bsideup commented Jun 18, 2021

Released as 0.4.1!

@raviagarwal7
Copy link
Contributor Author

thanks a lot @bsideup

@raviagarwal7 raviagarwal7 deleted the ravi/static branch June 18, 2021 20:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants