Does SCR annotations work in AEM 6.4? | Community
Skip to main content
kishore_polsani
Level 4
October 26, 2018
Solved

Does SCR annotations work in AEM 6.4?

  • October 26, 2018
  • 2 replies
  • 2648 views

Hi,

I am upgrading AEM 6.2 to AEM 6.4 (archetype 13), I am using SCR annotations in AEM6.2. I tried to use same SCR annotation for time being rather than using OSGI  declarative services annotations in AEM6.4. When I use SCR annotations, "Declarative Service Components" are in satisfied state, when I use OSGI annotations, I can see component is active.

Is SCR annotations compatible in AEM 6.4?

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 smacdonald2008

SCR Annotation by default are used in Maven 10 archetypes. I have successfully deployed Maven 10 projects to AEM 6.4. The answer is yes - SRC annotations work in AEM 6.4 - however - it's considered better practice to use R6 annotations.

2 replies

smacdonald2008
smacdonald2008Accepted solution
Level 10
October 26, 2018

SCR Annotation by default are used in Maven 10 archetypes. I have successfully deployed Maven 10 projects to AEM 6.4. The answer is yes - SRC annotations work in AEM 6.4 - however - it's considered better practice to use R6 annotations.

joerghoh
Adobe Employee
Adobe Employee
October 26, 2018

the SCR annotations are processed during build time (you can find the result inside the bundles in the OSGI-INF directory), and both SCR and OSGI annotations should create the same XML files. There is no runtime dependency on the annotations themselves. But of course there is the SCR Service, but that has nothing to do with the SCR annotations in the first place.

Jörg