【问题标题】:AEM WKND Apache Maven ConcurrentModificationException Build FailureAEM WKND Apache Maven ConcurrentModificationException 构建失败
【发布时间】:2021-01-30 18:33:31
【问题描述】:

我正在此处 (https://experienceleague.adobe.com/docs/experience-manager-learn/getting-started-wknd-tutorial-develop/project-setup.html?lang=en#build) 浏览“项目设置”说明并遇到以下故障...

[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for aem-guides-wknd 0.0.1-SNAPSHOT:
[INFO]
[INFO] aem-guides-wknd .................................... SUCCESS [  0.990 s]
[INFO] WKND Sites Project - Core .......................... FAILURE [01:32 min]
[INFO] WKND Sites Project - UI Frontend ................... SKIPPED
[INFO] WKND Sites Project - Repository Structure Package .. SKIPPED
[INFO] WKND Sites Project - UI apps ....................... SKIPPED
[INFO] WKND Sites Project - UI content .................... SKIPPED
[INFO] WKND Sites Project - All ........................... SKIPPED
[INFO] WKND Sites Project - Integration Tests Bundles ..... SKIPPED
[INFO] WKND Sites Project - Integration Tests Launcher .... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  01:37 min
[INFO] Finished at: 2021-01-30T12:49:20-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal biz.aQute.bnd:bnd-maven-plugin:4.2.0:bnd-process (bnd-process) on project aem-guides-wknd.core: bnd error: null: ConcurrentModificationException -> [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/MojoExecutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <args> -rf :aem-guides-wknd.core

...当我尝试执行步骤4中的命令时,即执行以下内容:

$ mvn archetype:generate -B \
    -DarchetypeGroupId=com.adobe.granite.archetypes \
    -DarchetypeArtifactId=aem-project-archetype \
    -DarchetypeVersion=22 \
    -DgroupId=com.adobe.aem.guides \
    -Dversion=0.0.1-SNAPSHOT \
    -DappsFolderName=wknd \
    -DartifactId=aem-guides-wknd \
    -Dpackage=com.adobe.aem.guides.wknd \
    -DartifactName="WKND Sites Project" \
    -DcomponentGroupName=WKND \
    -DconfFolderName=wknd \
    -DcontentFolderName=wknd \
    -DcssId=wknd \
    -DisSingleCountryWebsite=n \
    -Dlanguage_country=en_us \
    -DoptionAemVersion=6.5.0 \
    -DoptionDispatcherConfig=none \
    -DoptionIncludeErrorHandler=n \
    -DoptionIncludeExamples=y \
    -DoptionIncludeFrontendModule=y \
    -DpackageGroup=wknd \
    -DsiteName="WKND Site"

我导航到被引用​​的http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException,它说 MojoExecutionException“不是由 Maven 核心本身生成的,而是由插件生成的”,但我不知道是什么插件导致了这个问题。此外,我得到的错误是“ConcurrentModificationException”而不是“MojoExecutionException”。有什么想法我可能会遗漏吗?

【问题讨论】:

    标签: java eclipse maven aem


    【解决方案1】:

    您应该更新 bnd-maven-plugin,修复已在 v5.1.0 中提供。 更新到 latest 一个,它应该可以工作。

    【讨论】:

      【解决方案2】:

      我看到 archtype 的命令是:

      mvn -B archetype:generate \
      -D **archetypeGroupId=com.adobe.aem** \
      -D archetypeArtifactId=aem-project-archetype \
      -D archetypeVersion=26 \
      -D appTitle="WKND Sites Project" \
      -D appId="wknd" \
      -D groupId="com.adobe.aem.guides.wknd" \
      -D artifactId="aem-guides-wknd" \
      ...
      

      至少组 id 部分应该是

      archetypeGroupId=com.adobe.aem

      您可能需要检查您的命令并再次运行它。

      【讨论】: