AEM6.3 | @Reference aanotation is not working in abstract class

Avatar

Avatar

pradeepdubey82

Avatar

pradeepdubey82

pradeepdubey82

06-03-2018

Hi All,

I am facing issue in AEM6.3(6.1 code was working), @Reference annotation is not working in abstract class.

Same code was working fine in AEM6.1

Below is my code

@Service

public abstract class Test implements ABCIntf {

@Reference (this is not working in 6.3 was working in 6.1)

private Replicator replicator

}

I had no option other than to move @Reference in concrete class.

Please advise if anyone can help.

Thanks,

Pradeep

View Entire Topic

Avatar

Avatar

pradeepdubey82

Avatar

pradeepdubey82

pradeepdubey82

06-03-2018

Hi,

I am working on  upgrade from 6.1 to 6.3. Code  which  was working fine in 6.1 is not working on 6.3.

@Reference

private Replicator replicator

Throwing nullpointer exception in  abstract class (@Service annotation only no @Component annotation on top of class definition). It was working in 6.1.

Gone through the links shared in response, i think there are lot of changes i have to do (pom file changes, felix annotation are deprecated)

I was thinking this will be minor change. But after going through the links it is not minor change. Will post you if needed any help.

Anyway, thanks a lot for the quick  help.

Thanks,

Pradeep