Error while upgrading AEM from 6.5.2 to 6.5.5 | Community
Skip to main content
New Participant
August 12, 2020
Solved

Error while upgrading AEM from 6.5.2 to 6.5.5

  • August 12, 2020
  • 3 replies
  • 3027 views

HI,

 

We are planning to upgrade our AEM from 6.5.2 to 6.5.5 through service pack: https://docs.adobe.com/content/help/en/experience-manager-65/release-notes/service-pack/sp-release-notes.html.

While following the instruction, I installed the 6.5.5 package and then updated pom.xml to update uber jar to 6.5.5. I can see those changes in my project.

But when I try to compile and build the project I get below error:

[ERROR] COMPILATION ERROR :

[INFO] -------------------------------------------------------------

[ERROR] /Users/mukmayu/All_Documents/Project_Official/Manulife_CEA/Code_Workspaces/AEMCodeAll/aem-global/core/src/main/java/ca/manulifeglobal/core/util/AssetAccessUtils.java:[99,7] cannot access org.apache.poi.ooxml.POIXMLDocument

  class file for org.apache.poi.ooxml.POIXMLDocument not found

[ERROR] /Users/mukmayu/All_Documents/Project_Official/Manulife_CEA/Code_Workspaces/AEMCodeAll/aem-global/core/src/main/java/ca/manulifeglobal/core/util/AssetAccessUtils.java:[132,19] cannot access org.apache.poi.ooxml.POIXMLDocumentPart

  class file for org.apache.poi.ooxml.POIXMLDocumentPart not found

[ERROR] /Users/mukmayu/All_Documents/Project_Official/Manulife_CEA/Code_Workspaces/AEMCodeAll/aem-global/core/src/main/java/ca/manulifeglobal/core/util/AssetAccessUtils.java:[158,15] cannot find symbol

  symbol:   method write(java.io.ByteArrayOutputStream)

  location: variable workbook of type org.apache.poi.xssf.usermodel.XSSFWorkbook

 

To fix I tried to add dependency for apache poi:

<dependency>

    <groupId>org.apache.poi</groupId>

    <artifactId>poi</artifactId>

    <version>4.1.2</version>

</dependency>

 

But when I do maven update, i dont see any jar getting added in my project and error persists.

Any suggestion...?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by SundeepKatepally

You need to add one more dependency

<dependency>
    <groupId>org.apache.poi</groupId>
    <artifactId>poi-ooxml</artifactId>
    <version>3.9</version>
</dependency>

 

Change the version as expected by your instance

 

org.apache.poi.xssf.usermodel.XSSFWorkbook class is available in the above dependency bundle.

 

3 replies

SundeepKatepally
SundeepKatepallyAccepted solution
New Participant
August 13, 2020

You need to add one more dependency

<dependency>
    <groupId>org.apache.poi</groupId>
    <artifactId>poi-ooxml</artifactId>
    <version>3.9</version>
</dependency>

 

Change the version as expected by your instance

 

org.apache.poi.xssf.usermodel.XSSFWorkbook class is available in the above dependency bundle.

 

Mayukh007Author
New Participant
August 13, 2020

Thanks Sundeep, that resolved the issue....but now I am getting another error for it.launcher:

 

[INFO] Installing /Users/mukmayu/All_Documents/Project_Official/Manulife_CEA/Code_Workspaces/AEMCodeAll/aem-global/it.launcher/target/aem-global.it.launcher-0.4.83-SNAPSHOT.jar to /Users/mukmayu/.m2/repository/ca/manulife/dxp/aem-global.it.launcher/0.4.83-SNAPSHOT/aem-global.it.launcher-0.4.83-SNAPSHOT.jar

[INFO] Installing /Users/mukmayu/All_Documents/Project_Official/Manulife_CEA/Code_Workspaces/AEMCodeAll/aem-global/it.launcher/pom.xml to /Users/mukmayu/.m2/repository/ca/manulife/dxp/aem-global.it.launcher/0.4.83-SNAPSHOT/aem-global.it.launcher-0.4.83-SNAPSHOT.pom

[INFO] Installing /Users/mukmayu/All_Documents/Project_Official/Manulife_CEA/Code_Workspaces/AEMCodeAll/aem-global/it.launcher/reports.zip to /Users/mukmayu/.m2/repository/ca/manulife/dxp/aem-global.it.launcher/0.4.83-SNAPSHOT/aem-global.it.launcher-0.4.83-SNAPSHOT.reports.zip

[INFO] ------------------------------------------------------------------------

[INFO] Reactor Summary:

[INFO]

[INFO] Manulife AEM Global - Reactor Project 0.4.83-SNAPSHOT SUCCESS [  0.241 s]

[INFO] Manulife AEM Global Bundle ......................... SUCCESS [ 20.971 s]

[INFO] Manulife AEM Global Apps Package ................... SUCCESS [ 24.754 s]

[INFO] Manulife AEM Global Content Package ................ SUCCESS [  0.305 s]

[INFO] aem-global - Integration Tests Bundles ............. SUCCESS [  1.674 s]

[INFO] aem-global - Integration Tests Launcher 0.4.83-SNAPSHOT FAILURE [  1.092 s]

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 50.248 s

[INFO] Finished at: 2020-08-13T00:09:37-04:00

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-install-plugin:2.5.2:install (default-install) on project aem-global.it.launcher: Failed to install artifact ca.manulife.dxp:aem-global.it.launcher:reports.zip:0.4.83-SNAPSHOT: /Users/mukmayu/All_Documents/Project_Official/Manulife_CEA/Code_Workspaces/AEMCodeAll/aem-global/it.launcher/reports.zip (No such file or directory) -> [Help 1]

[ERROR]

ChitraMadan
New Participant
August 12, 2020

Hi @mayukh007 

 

The dependency you are including does not have the class you are trying to compile with it.

<dependency>

    <groupId>org.apache.poi</groupId>

    <artifactId>poi</artifactId>

    <version>4.1.2</version>

</dependency>

 

 

Can you please try to add below dependency and tray again

<!-- https://mvnrepository.com/artifact/org.apache.poi/poi-ooxml -->
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>4.1.2</version>
</dependency>

Mayukh007Author
New Participant
August 13, 2020
Thank you Chitra...that resolved the issue...!!
Mayukh007Author
New Participant
August 12, 2020
Update: I added dependency for apache poi in core and updated maven project. Now i see 4.0.1 poi version in maven dependency in core..but issue remains.