Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify site generation #1166

Merged
merged 48 commits into from
Jan 16, 2023
Merged

Simplify site generation #1166

merged 48 commits into from
Jan 16, 2023

Conversation

vy
Copy link
Member

@vy vy commented Dec 19, 2022

Warning! These changes are based on the work delivered in #1145 replacing the maven-changes-plugin. Hence, that PR needs to be merged first!

This PR attempts to simplify the site generation.
Highlights from the changes are as follows:

  1. all Maven reporting is disabled
  2. Coveralls, JaCoCo, DOAP, PDF configurations are removed
  3. enforce-upper-bound-deps Maven enforcer rule is fixed
  4. /pom.xml is overhauled (developers are simplified, contributors are removed, unused configurations/properties are removed, etc.)
  5. maven-site-plugin is disabled for all modules except /pom.xml
  6. all <module>/src/site/markdown/index.md[.vm] files are moved to /src/site/markdown/<module>.md[.vm]
  7. build instructions are updated

As a result, ./mvnw site takes less than 30s on a decent laptop.

@rgoers
Copy link
Member

rgoers commented Dec 19, 2022

I pulled logging-log4j-tools and built it. I ran mvn clean install (which worked). I then ran mvn site, which failed with

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-site-plugin:3.12.0:site (default-site) on project log4j: SiteToolException: The site descriptor cannot be resolved from the repository: ArtifactResolutionException: Unable to locate site descriptor: Could not transfer artifact org.apache.logging:logging-parent:xml:site_en:7 from/to spring-snapshots (https://repo.spring.io/libs-snapshot-local): Failed to transfer file https://repo.spring.io/libs-snapshot-local/org/apache/logging/logging-parent/7/logging-parent-7-site_en.xml with status code 409
[ERROR]   org.apache.logging:logging-parent:xml:7

@vy
Copy link
Member Author

vy commented Dec 19, 2022

@rgoers, it simply works on my machine. Since logging-log4j-tools release is stuck on INFRA-23996, I cannot prove my claim in CI, i.e., GitHub Actions.

Would you mind trying ./mvnw clean site in mvn-site-simplified branch, please?

Which module fails to build? log4j-spring-cloud-config-sample-server?

@rgoers
Copy link
Member

rgoers commented Dec 19, 2022

It fails at the root of the project. It isn't in any module.

@ppkarwasz
Copy link
Contributor

@rgoers: my guess is that you are using a Maven Central mirror that does not contain the logging-parent.site.* artifacts?

@rgoers
Copy link
Member

rgoers commented Dec 19, 2022

It turns out I had some Spring repos in my settings.xml from when I was adding out stuff to Spring and that messed it up. After removing it the site built fine and only took 47 seconds!

However, I still have to look at the results.

@rgoers
Copy link
Member

rgoers commented Dec 19, 2022

Under components, when I select "Implementation" I get a file not found. All the other pages are fine.

Note - make sure you do mvn site:stage -DstagingDirectory=$HOME/log4j to generate the full web site.

@vy
Copy link
Member Author

vy commented Dec 19, 2022

Under components, when I select "Implementation" I get a file not found. All the other pages are fine.

I have removed that page, since it was empty anyway. Now, in c612522, removed it from the menu too.

Note - make sure you do mvn site:stage -DstagingDirectory=$HOME/log4j to generate the full web site.

✔️

@vy vy force-pushed the mvn-site-simplified branch from c612522 to f1ee3a6 Compare December 27, 2022 12:13
@vy vy force-pushed the mvn-site-simplified branch from f1ee3a6 to fc40fdd Compare December 30, 2022 10:42
@vy vy changed the base branch from release-2.x to LOG4J2-3628 January 9, 2023 08:08
Base automatically changed from LOG4J2-3628 to release-2.x January 13, 2023 16:14
@jvz jvz added the build Affects the build system or other automation label Jan 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Affects the build system or other automation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants