April 3, 2020
Estimated Post Reading Time ~

Why you should set all @Reference variables to null

What you should do when writing sling servlets, all @Reference variables should be set to null

why we experienced an issue where when changing pom, reference was still being kept between updates. It seems that if your running servlets have injected an @Reference variable if a change causes the @Reference variable to not successfully be able to be injected, it will only happen when the instance has been destroyed.

This is confusing as it makes it hard to narrow down which change has caused an @Reference variable to no longer be injected.


By aem4beginner

No comments:

Post a Comment

If you have any doubts or questions, please let us know.