Delayed cleanup of deleted portal pages

When you delete a page the portal server also deletes all its derived pages and dependent resources. This information is stored in the database so deleting all the resource might take long time. As administrator you have two choices for when the actual deletion should happen


  • Immediately: That means as soon as you delete the portal page all its dependent resources get deleted immediately

  • Delayed deletion: If you choose this option then that means when you delete the page it does not actually get deleted instead portal will only mark the page and its dependent resources as deleted and make sure that users are not able to access these deleted pages but the actual deletion is done by the ResourceCleanup task which runs on every Saturday at 8 PM by default.



You can configure delayed cleanup of resources by setting value of scheduler.cleanup.enabled property to true in the DataStoreService. If you dont want delayed cleanup set it to false.

Now if you set the delayed cleanup then you might face one problem. Lets say you deleted a page then if you try to recreate that page immediately you might get DuplicateKey exception because that page is not actually deleted. In that case you can execute XMLAccess task using Task.xml file which is available in PortalServer/doc/xml-samples directory as input file.

xmlaccess.bat -in c:\WebSphere\PortalServer\doc\xml-samples\Task.xml -out c:\temp\taskresult.xml -url http://localhost:10040/wps/config -user wasadmin -password wasadmin

When you run the cleanup task, the XML configuration interface only schedules the task to be run in WebSphere Application Server and returns. This does not necessarily mean that IBM WebSphere Application Server runs the task immediately. To determine when a task started and ended, check the portal log SystemOut.log for the EJPDE0002I and EJPDE0003I messages.

[5/9/09 11:29:27:319 PDT] 00000027 SchedulerTask I com.ibm.wps.datastore.ejb.cleanup.SchedulerTaskNotificationSinkBean handleEvent() EJPDE0005I: Task WPS_RUN_ONCE_TASK_com.ibm.portal.datastore.task.ResourceCleanup with ID 4957 was started.
[5/9/09 11:29:28:069 PDT] 00000027 SchedulerTask I com.ibm.wps.datastore.ejb.cleanup.SchedulerTaskNotificationSinkBean handleEvent() EJPDE0007I: Task WPS_RUN_ONCE_TASK_com.ibm.portal.datastore.task.ResourceCleanup with ID 4957 has finished.
[5/9/09 11:29:28:100 PDT] 00000027 SchedulerTask I com.ibm.wps.datastore.ejb.cleanup.SchedulerTaskNotificationSinkBean handleEvent() EJPDE0006I: RUN ONCE Task WPS_RUN_ONCE_TASK_com.ibm.portal.datastore.task.ResourceCleanup with ID 4957 has completed.


These messages confirm that the cleanup task has successfully completed. After you have confirmed this, you can run the XML script for re-creating a page with the same object ID as it had before the deletion.

If you want to change the schedule of when ResourceCleanup task runs then you can use XMLAccess and use the sample Task.xml file to figure out how to schedule a task.

3 comments:

srjwebsolutions said...


We are leading responsive website designing and development company in Noida.
We are offering mobile friendly responsive website designing, website development, e-commerce website, seo service and sem services in Noida.

Responsive Website Designing Company in Noida
Website Designing Company in Noida
SEO Services in Noida
SMO Services in Noida

EG MEDI said...

Egmedi.com is online medical store pharmacy in laxmi nagar Delhi. You can Order prescription/OTC medicines online.
Cash on Delivery available. Free Home Delivery


Online Pharmacy in Delhi
Buy Online medicine in Delhi
Online Pharmacy in laxmi nagar
Buy Online medicine in laxmi nagar
Onine Medical Store in Delhi
Online Medical store in laxmi nagar
Online medicine store in delhi
online medicine store in laxmi nagar
Purchase Medicine Online
Online Pharmacy India
Online Medical Store


Vikas Chaudhary said...

Battery Mantra is Authorized exide car battery dealer in Noida and Greater Noida. We are providing our service in Indirapuram, Delhi, Ashok Nagar.

Exide Battery Dealer in Noida
Battery Dealer in Noida
Authorized Battery Dealer in Noida
Car Battery Dealer in Noida
Car Battery Dealer
Exide Battery Dealer