slachiewicz commented on issue #13302: URL: https://github.com/apache/maven/issues/13302#issuecomment-5913951602
### maven-reporting-exec PR: apache/maven-reporting-exec#167. Status: **partial**, 3.0.0-SNAPSHOT, Java 17. Public API ported; implementation stays on maven-core. Verified locally: `mvn verify` with Maven 4.0.0-rc-7, JDK 21 → 4 unit tests, 0 failures; ITs 0 of 5 pass (5 before). Every IT runs the released maven-site-plugin 3.22.0 against this snapshot and fails with `NoSuchMethodError: MavenReportExecutorRequest.setMavenSession(MavenSession)`. Spotless clean. **Public API changes** - `MavenReportExecutorRequest`: `get/setMavenSession(MavenSession)` → `get/setSession(org.apache.maven.api.Session)`; `get/setProject(MavenProject)` → `org.apache.maven.api.Project`; `setReportPlugins(org.apache.maven.model.ReportPlugin[])` → `org.apache.maven.api.model.ReportPlugin[]`. - `MavenReportExecution`: `Plugin` → `org.apache.maven.api.model.Plugin`. - `MavenReportExecutor.buildMavenReports` throws unchecked `MojoException` instead of checked `MojoExecutionException`. **Gaps: the v4 API has no equivalent for what this component does** - `MavenPluginManager`, `PluginDescriptor`, `MojoDescriptor`, `MojoExecution`, `PluginVersionResolver`, plugin realm setup, and `LifecycleExecutor.calculateForkedExecutions`/`executeForkedExecutions`. `DefaultMavenReportExecutor` and `MavenPluginManagerHelper` therefore stay on maven-core. - `Session` → `MavenSession` and `Project` → `MavenProject` only via internal classes (`InternalMavenSession.from(...)`, `DefaultProject.getProject()`). - `MavenProject.isExecutionRoot()` has no equivalent; `Project.isRootProject()` means the `.mvn` directory. This affects `canAggregate`. - Tests stay on `@PlexusTest`, since maven-testing targets v4-DI mojos. They need `maven-compat` for `ToolchainManager` and `plexus-xml` 4.2.0, because parent 50 manages 3.0.1, which fails with `NoClassDefFoundError: Xpp3Dom$ChildrenTracking` on Maven 4. **Consumers that break:** maven-site-plugin only (`AbstractSiteRenderingMojo`, `AutoRefreshMojo`, `SiteMojo`, `SiteJarMojo`, `SiteRunMojo`, `ReportDocumentRenderer`); shown at runtime by the ITs above. **Recommendation:** keep a 3.x line; this port is a facade only. A real Maven 4 version needs a report-execution or plugin-manager API in `org.apache.maven.api`. If the Maven 4 site plugin gets one, retire this component in its favour. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
