Howdy,

yes, in Maven4 there is ongoing effort to properly codify these, see
this thread (on dev ML) and feel free to join in:
https://lists.apache.org/thread/0k214oy4mzbtodmzc1wrkzl2d3nkoogb
This would allow POM to express the "reason" of a dependency (and of
course, plugins would be able to handle those, after modified).

For Maven3 plans, I am unsure about plans, but again, feel free to
open discussions about it.

Thanks
T

On Thu, Feb 6, 2025 at 9:20 AM Moritz Halbritter
<moritz.halbrit...@broadcom.com.invalid> wrote:
>
> Hello,
>
> I'm Moritz, working in the Spring Team on start.spring.io. We have an issue
> about a warning that gets printed when using Mockito on JDK 21 or above (
> https://github.com/spring-io/initializr/issues/1590):
>
> WARNING: A Java agent has been loaded dynamically
> (/home/mhalbritter/.m2/repository/net/bytebuddy/byte-buddy-agent/1.15.11/byte-buddy-agent-1.15.11.jar)
> WARNING: If a serviceability tool is in use, please run with
> -XX:+EnableDynamicAgentLoading to hide this warning
> WARNING: If a serviceability tool is not in use, please run with
> -Djdk.instrument.traceUsage for more information
> WARNING: Dynamic loading of agents will be disallowed by default in a
> future release
>
> The recommended fix for that is documented in the Mockito docs (
> https://javadoc.io/doc/org.mockito/mockito-core/latest/org/mockito/Mockito.html#0.3),
> and it involves modifying the "argLine" configuration of the
> maven-surefire-plugin plugin.
>
> Are there any plans to automatically detect the use of bytebuddy (or more
> generally the use of agents) on Maven side and automatically configure
> surefire to do the right thing or are users expected to modify their build
> themselves?
>
> Thanks,
> Moritz
>
> --
> This electronic communication and the information and any files transmitted
> with it, or attached to it, are confidential and are intended solely for
> the use of the individual or entity to whom it is addressed and may contain
> information that is confidential, legally privileged, protected by privacy
> laws, or otherwise restricted from disclosure to anyone else. If you are
> not the intended recipient or the person responsible for delivering the
> e-mail to the intended recipient, you are hereby notified that any use,
> copying, distributing, dissemination, forwarding, printing, or copying of
> this e-mail is strictly prohibited. If you received this e-mail in error,
> please return the e-mail to the sender, delete it from your computer, and
> destroy any printed copy of it.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to