Fel: BUILD_MAVEN_PACKAGE_ERROR i AEM Cloud Manager
När du stöter på en Build_Maven_Package_Error
i Adobe Experience Manager Cloud Manager beror det på ett kodfel. Detta kan lösas genom att uppdatera nodversionen i en modul som inte fungerar med npm (Node Package Manager).
Beskrivning description
Miljö
Adobe Experience Manager Cloud Manager
Problem/symtom
Hur löser jag felet - Build_Maven_Package_Error
i AEM Cloud Manager?
19:19:53,214 [ main] [ INFO] ------------------------------------------------------------------------
19:19:53,215 [ main] [ INFO] Reactor Summary for customer_name XXXX.XXX.XXXXXXX.XXXXXXXXXX:{}:
19:19:53,215 [ main] [ INFO]
19:19:53,216 [ main] [ INFO] customer_name ...................................... SUCCESS [ 3.600 s]
19:19:53,217 [ main] [ INFO] customer_name - Core ............................... SUCCESS [ 17.855 s]
19:19:53,218 [ main] [ INFO] customer_name - UI Frontend ........................ FAILURE [ 01:16 min]
19:19:53,218 [ main] [ INFO] customer_name – UI React ........................... SKIPPED
19:19:53,218 [ main] [ INFO] customer_name - UI apps ............................ SKIPPED
19:19:53,219 [ main] [ INFO] customer_name - UI content ......................... SKIPPED
19:19:53,219 [ main] [ INFO] customer_name Project Package ...................... SKIPPED
19:19:53,219 [ main] [ INFO] customer_name - Dispatcher ......................... SKIPPED
19:19:53,220 [ main] [ INFO] ------------------------------------------------------------------------
19:19:53,220 [ main] [ INFO] BUILD FAILURE
19:19:53,220 [ main] [ INFO] ------------------------------------------------------------------------
19:19:53,222 [ main] [ INFO] Total time: 01:41 min
19:19:53,224 [ main] [ INFO] Finished at: 2023-02-07T19:19:53Z
19:19:53,224 [ main] [ INFO] ------------------------------------------------------------------------
19:19:53,226 [ main] [ ERROR] Failed to execute goal com.github.xxxxx:frontend-maven-plugin:1.7.6:npm (npm run prod) on project com.xyz.ui.frontend: Failed to run task: 'npm run prod' failed. org.apache.commons.exec.ExecuteException: Process exited with an error: 2 (Exit value: 2) ->[ Help 1]
19:19:53,227 [ main] [ ERROR]
FEL i P2-biljett:
Pipeline Name: Production Pipeline
Pipeline Status: FAILED
Failure Caused By: CUSTOMER
Failed Step: build
Error Message: org.apache.commons.exec.ExecuteException: Process exited with an error: 1 (Exit value: 1)
Upplösning resolution
Felet beror på ett kodproblem som måste åtgärdas genom att nodversionen uppdateras i en misslyckad modul med hjälp av npm. Gör så här:
-
Hitta den nodversion som används i reaktorn
pom.xml
. Nedanför exempel = 16.14.0pom.xml
:code language-none <configuration> <nodeVersion>v16.14.0</nodeVersion>. <npmVersion>8.3.1</npmVersion> <configuration>
-
Lägg till den här nodversionen som devDependencies i filen
package.json
i modulen som inte kunde skapas. I exemplet ovan är det UI-teckensnitt.FÖRE -
package.json
:code language-none "devDependencies": { "@babel/core": "7.0.0", "@babel/plugin-proposal-class-properties": "7.3.3", "@babel/plugin-proposal-object-rest-spread": "7.3.2", "@material/tab-bar": "12.0.0", },
EFTER -
package.json
:code language-none "devDependencies": { "@types/node": "16.14.0", THIS LINE WAS ADDED "@babel/core": "7.0.0", "@babel/plugin-proposal-class-properties": "7.3.3", "@babel/plugin-proposal-object-rest-spread": "7.3.2", "@material/tab-bar": "12.0.0", },