Maven site plugin: The following plugins are not marked @threadSafe in project org.apache.maven.plugins:maven-site-plugin:3.9.1

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Maven site plugin: The following plugins are not marked @threadSafe in project org.apache.maven.plugins:maven-site-plugin:3.9.1

Patrick Pok
Hello Maven site Team,


I just wanted to reach out with a small question/bug report/enhancement request please.

For a Maven multi module project, I have some 50 micro services that are totally independent.
They could have been in a separated project/repository, but for organization and team management purpose, they are all in one same Maven multi module. (This is not the question actually)

As they are independent of each other, we would like to run parallel build with Maven. Instead of running the analysis for service one, then service two, etc, we do something like:

mvn clean install -U -T 10 sonar:sonar
And this is actually working fine, the parallel and sequential perform correct computation, we verified with logs and even a real stopwatch, -T 10 will build faster.

Unfortunately, during the build, we see this issue.

[INFO] --------------------------------[ pom ]---------------------------------
[WARNING] *****************************************************************
[WARNING] * Your build is requesting parallel execution, but project      *
[WARNING] * contains the following plugin(s) that have goals not marked   *
[WARNING] * as @threadSafe to support parallel building.                  *
[WARNING] * While this /may/ work fine, please look for plugin updates    *
[WARNING] * and/or request plugins be made thread-safe.                   *
[WARNING] * If reporting an issue, report it against the plugin in        *
[WARNING] * question, not against maven-core                              *
[WARNING] *****************************************************************
[WARNING] The following plugins are not marked @threadSafe in project:
[WARNING] org.apache.maven.plugins:maven-site-plugin:3.9.1
[WARNING] Enable debug to see more precisely which goals are not marked @threadSafe.
[WARNING] *****************************************************************
Is it possible to just change the plugin by allowing thread safe?
Maybe something as simple as

@Mojo(name = “x", requiresProject = true, defaultPhase = LifecyclePhase.x, requiresDependencyResolution = ResolutionScope.TEST, threadSafe = true)
Many thanks

Patrick