[AEM][6.4][Upgrade]- Java servlet can't register on fresh 6.4 install and are in satisfied state | Community
Skip to main content
Adobe Employee
January 29, 2019
Solved

[AEM][6.4][Upgrade]- Java servlet can't register on fresh 6.4 install and are in satisfied state

  • January 29, 2019
  • 4 replies
  • 3591 views
Content backfill required
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 Gaurav-Behl

As Scott mentioned, you would need to modify the source code to bring it up. At bare minimum, fix the following:

Admin session would not work - return repository.loginAdministrative(null);

Use correct jar versions  - When you build the project using Maven Archetype 13 (or higher), you would get the required dependencies and correct jar versions

4 replies

smacdonald2008
Level 10
January 29, 2019

There are some issues here:

1. Its better practice to use R6 annotations as opposed to SRC annotations.

2- To get a session, you should use a System User and map that using Mapping Service. For details - see Adobe Experience Manager Help | Querying Adobe Experience Manager 6.4 JCR data using the QueryBuilder API

For AEM 6.4 - you should be using a Maven Archetype 13 (or higher) and use UBER 6.4 jar. See the article I referenced.

After you perform these tasks - your bundle will go into Active State.

smacdonald2008
Level 10
January 29, 2019

In addition - as your example uses QueryBuilder API, see our HELPX article that shows how to successfully use this API to query the AEM JCR:

Adobe Experience Manager Help | Querying Adobe Experience Manager 6.4 JCR data using the QueryBuilder API 

nraiAdobe EmployeeAuthor
Adobe Employee
January 29, 2019

Hi, thanks for the inputs.

Some of the components having SRC annotation are in active state.

Is there any way I can install my bundle that used to work on AEM 6.3 versions without any change as there are several servlets and it will take a lot to rework to incorporate the changes you suggested.

Gaurav-Behl
Gaurav-BehlAccepted solution
Level 10
January 29, 2019

As Scott mentioned, you would need to modify the source code to bring it up. At bare minimum, fix the following:

Admin session would not work - return repository.loginAdministrative(null);

Use correct jar versions  - When you build the project using Maven Archetype 13 (or higher), you would get the required dependencies and correct jar versions