I have a tree of about 30,000 nodes that need to be removed. There is a process that runs against a database and creates CQ page nodes in authoring. The process had errors and all the nodes under this tree need to be deleted. Anyone know of a way to do this programatically. We have tried deleting entire trees, but if we weren't far enough down the branches, authoring just locks up.
You could try using the SlingPostServlet to do that: http://sling.apache.org/site/manipulating-content-the-slingpostservlet-servletspost.html#M anipulatingContent-TheSlingPostServlet%2528servlets.post%2529-ContentRemoval
Thanks, do you see this as a threat to bring down authoring? Can you blow away a whole tree of about 30000+ nodes this way?
Willy - you're right to be concerned about the performance impact. There's a specific utility class for this: com.day.cq.commons.jcr.JcrRecursiveRemove: http://dev.day.com/docs/en/cq/current/javadoc/com/day/cq/commons/jcr/JcrRecursiveRemove.ht ml
You can also use the Recursive Delete function through CRX Explorer (/crx/explorer/).