Expand my Community achievements bar.

Adobe Summit 2025: AEM Session Recordings Are Live! Missed a session or want to revisit your favorites? Watch the latest recordings now.

Mark Solution

This conversation has been locked due to inactivity. Please create a new post.

SOLVED

Deleting component in /apps deletes its references in content pages

Avatar

Level 1

I have deleted a component and its coresponding java files. When I do a build to my local instance, the component is deleted as expected.
But in our QA environment found the references of this component in pages is also deleted (verified the page node structure in CRXDE).
Any idea, what is happening here?

1 Accepted Solution

Avatar

Correct answer by
Community Advisor and Adobe Champion

@sushmaa61672298,

After authoring pages, the authored component reference nodes becomes apart of the page configuration. When you delete your component from /apps, the authored pages will still be referencing to the deleted component; deleting a component from /apps will not remove referenced nodes from AEM.

so if the component is heavily used, then after deleting the component from /apps, you will be left with a lot of exceptions in the error.log, because the reference cannot be found.

A simple way to remove component reference nodes from authored pages will be to write a custom servlet that will find and remove all unwanted reference nodes.

I hope this helps.

View solution in original post

1 Reply

Avatar

Correct answer by
Community Advisor and Adobe Champion

@sushmaa61672298,

After authoring pages, the authored component reference nodes becomes apart of the page configuration. When you delete your component from /apps, the authored pages will still be referencing to the deleted component; deleting a component from /apps will not remove referenced nodes from AEM.

so if the component is heavily used, then after deleting the component from /apps, you will be left with a lot of exceptions in the error.log, because the reference cannot be found.

A simple way to remove component reference nodes from authored pages will be to write a custom servlet that will find and remove all unwanted reference nodes.

I hope this helps.