Bug 2266667 - maven-archetype fails to build with java-21-openjdk
Summary: maven-archetype fails to build with java-21-openjdk
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: maven-archetype
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
Assignee: Mat Booth
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 2262141
TreeView+ depends on / blocked
 
Reported: 2024-02-28 17:34 UTC by Petra Alice Mikova
Modified: 2024-03-14 09:24 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2024-03-14 09:24:50 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Petra Alice Mikova 2024-02-28 17:34:41 UTC
maven-archetype fails to build with java-21-openjdk as sytem JDK. See https://fedoraproject.org/wiki/Changes/Java21.

For the build logs, see: https://koji.fedoraproject.org/koji/taskinfo?taskID=114137186
https://kojipkgs.fedoraproject.org/work/tasks/7189/114137189/state.log
https://kojipkgs.fedoraproject.org/work/tasks/7189/114137189/build.log
https://kojipkgs.fedoraproject.org/work/tasks/7189/114137189/root.log
https://kojipkgs.fedoraproject.org/work/tasks/7189/114137189/mock_output.log
https://kojipkgs.fedoraproject.org/work/tasks/7189/114137189/hw_info.log
https://kojipkgs.fedoraproject.org/work/tasks/7189/114137189/checkout.log
We run the rebuild in side tag f41-build-side-84507, but as fail ratio was small, we expect this side tag to be merged into rawhide ASAP.
To reproduce before this date simply: fedpkg clone maven-archetype; cd maven-archetype;  fedpkg build --target f41-build-side-84507; #The target is crucial.
After merge, the usual fedpkg build in rawhide should do.

We had tried aprox 400 packages, and aprox 55 had failed, so the java-21-openjdk will be system JDK in f40, and you should fix your package if you want to keep it alive. Usually the fix is simple, and best is to update the package to latest upstream version. Fix the issue in both f40 and rawhide, if possible, the side tag and rebuild of f40 (and bugs) will follow soon.
Let us know here if you have any questions, here in bug, or at java-devel.org .

We'd appreciate help from the people who know this package best, but if you don't want to work on this now, let us know so we can try to work around it on our side if needed.

Comment 1 jiri vanek 2024-03-13 20:02:56 UTC
better logs: https://koji.fedoraproject.org/koji/getfile?taskID=114911163&volume=DEFAULT&name=build.log&offset=-40000

Most likely needs some of https://github.com/apache/maven-archetypes/pulls?q=is%3Apr+is%3Aclosed


[INFO] -------------------------------------------------------------
[WARNING] bootstrap class path not set in conjunction with -source 8
[WARNING] source value 8 is obsolete and will be removed in a future release
[WARNING] target value 8 is obsolete and will be removed in a future release
[WARNING] To suppress warnings about obsolete options, use -Xlint:-options.
[INFO] 4 warnings 
[INFO] -------------------------------------------------------------
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java:[42,38] package org.apache.commons.collections does not exist
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java:[155,61] cannot find symbol
  symbol:   variable CollectionUtils
  location: class org.apache.maven.archetype.creator.FilesetArchetypeCreator
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java:[649,88] cannot find symbol
  symbol:   method templateExists(java.lang.String)
  location: class org.apache.velocity.app.VelocityEngine
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java:[650,55] cannot find symbol
  symbol:   method templateExists(java.lang.String)
  location: class org.apache.velocity.app.VelocityEngine
[INFO] 4 errors 
[INFO] -------------------------------------------------------------
[INFO] 
[INFO] ------------------------------------------------------------------------
[INFO] Skipping Maven Archetype
[INFO] This project has been banned from the build due to previous failures.
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for Maven Archetype 3.2.0:
[INFO] 
[INFO] Maven Archetype .................................... SUCCESS [  0.707 s]
[INFO] Maven Archetype Models ............................. SUCCESS [  0.034 s]
[INFO] Maven Archetype Catalog Model ...................... SUCCESS [  2.619 s]
[INFO] Maven Archetype Descriptor Model ................... SUCCESS [  0.566 s]
[INFO] Maven Archetype Common ............................. FAILURE [  1.814 s]
[INFO] Maven Archetype Packaging .......................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  6.592 s
[INFO] Finished at: 2024-03-13T19:58:56Z
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.12.1:compile (default-compile) on project archetype-common: Compilation failure: Compilation failure: 
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java:[42,38] package org.apache.commons.collections does not exist
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/creator/FilesetArchetypeCreator.java:[155,61] cannot find symbol
[ERROR]   symbol:   variable CollectionUtils
[ERROR]   location: class org.apache.maven.archetype.creator.FilesetArchetypeCreator
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java:[649,88] cannot find symbol
[ERROR]   symbol:   method templateExists(java.lang.String)
[ERROR]   location: class org.apache.velocity.app.VelocityEngine
[ERROR] /builddir/build/BUILD/maven-archetype-3.2.0/archetype-common/src/main/java/org/apache/maven/archetype/generator/DefaultFilesetArchetypeGenerator.java:[650,55] cannot find symbol
[ERROR]   symbol:   method templateExists(java.lang.String)
[ERROR]   location: class org.apache.velocity.app.VelocityEngine
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <args> -rf :archetype-common

Comment 2 jiri vanek 2024-03-13 21:04:42 UTC
should be fixed by https://koji.fedoraproject.org/koji/taskinfo?taskID=114913950

Comment 3 jiri vanek 2024-03-14 09:24:50 UTC
update for f40don


Note You need to log in before you can comment on or make changes to this bug.