How to expedite the processing of asynchronous deletes in the JCR database
Applies to
HCL Digital Experience 8.5 and higher
Introduction
When the clearVersions ConfigEngine task deletes versions in the Java Content Repository (JCR) database, it may leave the associated asynchronous database deletes pending. You can run the following query to track the processing speed of the deletion:
SELECT COUNT(1) FROM <jcr>.ICMSTJCRREMOVEHLP
Sometimes, the versions are deleted slower than usual. This article describes how to expedite the processing of pending deletes.
Instructions
Use following ConfigEngine task to purge the pending deletes in much larger batches by increasing the value of the batchSize parameter:
./ConfigEngine.sh jcr-complete-asynchronous-deletes -DbatchSize=5000
Note
- This is a database resource-intensive activity so it is recommended to run this task when server activity is low.
- This task should only be used if the count in the ICMSTJCRREMOVEHLP table is high ( > 100,000) and is taking too long to process after finishing all runs of clearVersions.
If processing a batch takes too long, the jcr-complete-asynchronous-deletes task will be stopped and the standard AsynchronousDelete job will resume. To prevent this from happening, you can disable the standard AsynchronousDelete job:
- Login to the WebSphere Application Server (WAS) admin console and navigate to Resources > Resource Environment > Resource Environment Providers > JCR ConfigService PortalContent > Custom properties.
- Click New....
-
Enter the following details:
- Name:
jcr.background.services - Value:
TextSearch,BinaryCache - Type:
java.lang.String
- Name:
-
Click Apply.
- Click Save at the top of the console messages.
- Restart your Portal nodes.
-
Run the following task:
jcr-complete-asynchronous-deletesYou can monitor the progress of this task by turning on the following trace-string in Portal:
com.ibm.icm.da.portable.data.AsynchronousDelete=finestIf the job completes successfully, the following SQL will return 0:
SELECT COUNT(1) FROM JCR.ICMSTJCRREMOVEHLP
To re-enable the AsynchronousDelete job:
- Navigate to Resources > Resource Environment > Resource Environment Providers > JCR ConfigService PortalContent > Custom properties.
- Tick the checkbox for jcr.background.services then click Delete.
- Click Save at the top of the console messages.
- Restart your Portal nodes.