stackabletech / docker-images

Apache License 2.0
17 stars 3 forks source link

Build nifi from source #678

Closed maltesander closed 4 months ago

maltesander commented 4 months ago

Description

There is an error when trying to use java-devel 21 (for nifi 1.25.0):

79.83 [INFO] nifi-runtime-manifest .............................. SKIPPED
79.83 [INFO] nifi-runtime-manifest-test ......................... SKIPPED
79.83 [INFO] ------------------------------------------------------------------------
79.83 [INFO] BUILD FAILURE
79.83 [INFO] ------------------------------------------------------------------------
79.83 [INFO] Total time:  01:08 min
79.83 [INFO] Finished at: 2024-05-15T14:23:58Z
79.83 [INFO] ------------------------------------------------------------------------
79.83 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:3.4.1:enforce (enforce-maven-version) on project nifi: 
79.83 [ERROR] Rule 0: org.apache.maven.enforcer.rules.version.RequireJavaVersion failed with message:
79.83 [ERROR] Detected JDK version 21.0.3 (JAVA_HOME=/usr/lib/jvm/java-21-openjdk-21.0.3.0.9-1.el9.x86_64) is not in the allowed range [1.8.0-251,21).
79.83 [ERROR] -> [Help 1]
79.83 [ERROR] 
79.83 [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
79.83 [ERROR] Re-run Maven using the -X switch to enable full debug logging.
79.83 [ERROR] 
79.83 [ERROR] For more information about the errors and possible solutions, please read the following articles:
79.83 [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Thats why java-devel is on 11 there as well.

Edit: patching the 21 java version to 22 (for testing) leads to:

147.5 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.11.0:compile (default-compile) on project nifi-hl7-query-language: Compilation failure: Compilation failure: 
147.5 [ERROR] error: Source option 7 is no longer supported. Use 8 or later.
147.5 [ERROR] error: Target option 7 is no longer supported. Use 8 or later.
147.5 [ERROR] -> [Help 1]

Definition of Done Checklist

- [ ] Changes are OpenShift compatible
- [x] All added packages (via microdnf or otherwise) have a comment on why they are added
- [ ] Things not downloaded from Red Hat repositories should be mirrored in the Stackable repository and downloaded from there
- [x] All packages should have (if available) signatures/hashes verified
- [ ] Does your change affect an SBOM? Make sure to update all SBOMs
- [x] Add an entry to the CHANGELOG.md file
- [x] Integration tests ran successfully
TIP: Running integration tests with a new product image The image can be built and uploaded to the kind cluster with the following commands: ```shell bake --product --image-version kind load docker-image --name= ``` See the output of `bake` to retrieve the image tag for ``.