How to remove a duplicate process model

Hi All,

Request you to please let me know how to remove the duplicate process model that has been created automatically.

Thanks,
Kiran.

Hi Kiran,

I am curious with this duplicate process model automatically, howz that?
Well if the Model is not being used you can delete it from MWS admin under business process. If the model is used then u need to delete all the process instances running/completed/errored from audit DB and then you can delete the process model from process definition and other related tables in process audit DB.

cheers!
naren

Hi All,

i am also trying to “undeploy” a used process model. So I am interested in how to delete all the process instances running/completed/errored from audit DB. I cannot find a way to do so.

Thanks,
Mathias

Hi Mathias,

I would think that it is not suitable to do so. You cannot undeploy a used process model. Have you run the particular process model mentioned before this? If you have do so, the process instance cannot be removed from MWS.

Thanks,
William

Hello,

thanks for your response William. You are right - it is not suitable to remove a process model that is still used. That is why I asked how to delete all instances of a process model. Because after that I would be able to delete the process model.

On a production environment one would never do that but on development and test environments there is a need to clean up the system from time to time. And that is what I would like to do.

So I think my question is valid - how can I delete all process instances of a given process model.

Thanks for any comments.
Mathias

Hi Mathias

Some times my process stuck for hours and to force a stop execute a sql command directly on oracle tables trough sqlplus as follow:

update wmprocess set status = ‘4’
where instanceid in (select contextid from wmprocessassoc
where externalid like ‘[thenameofmyprocess]’);

First of all you need to identify and keep the contextid from wmprocessassoc table. Delete the rows on this table and after this, delete the rows in the wmprocess based on instanceid. For future maintenance make a simple flow to clean old process.

Rgds

Claudio Cruz

Hi Mathias,

Which version of webMethods you are using ?

Thanks,
Willaim

Hello,

thanks for the comments.

@Willchoong - we are on version 8.

@Claudio Cruz - I will give it a try - thanks!

Mathias

Hello,

I am jst browsing the tables related to processes (or which I think are related to processes).

From what I can see there is data about a process instance in many locations:
BAM - BAM_PT_PROCESS_INST
MWS - WMPROCESS
IS PRT - PRTPROCESS

So is deleting instances from WMPROCESS and WMPROCESSASSOC really enough. What about the remaining tables.

Is there any documentation about all process related tables?

Thanks,
Mathias

Hello,

now I found a way to delete all process instances of a process model.

  • 1. I wrote a small flow service that uses the service pub.monitor.process.instance:getInstanceList to retrieve all instances of a process model. After that it loops over the result and calls the Service pub.prt.admin:changeProcessStatus to set the status for each instance to completed (Parameter Action=Done)

    2. Use the service pub.monitor.archive:processArchive to delete the process related data (I set up a scheduled service). The parameter “days” takes a retention period - every thing above 0 works - so you need to wait at least one day after setting the status of the process instances to completed (step 1)

    3. Delete the process model using the Business Process page in MWS is now possible because no instances of the model exist anymore.

So this is a way to get rid of instances and models without directly accessing webMehtods tables.

Mathias

I think we can use processinstanceID to kill the process.for each process we will have have processID.on linux or unix environment you can use “ps -ef | grep GetClaims” command to see processID and use kill command