Welcome to the new Gigaspaces XAP forum. To recover your account, please follow these instructions.

Ask Your Question

What is the correct way to undeploy a PU programmatically?


I have tried to use the .undeploy() method to undeploy a PU however it was unsuccessful. Could you please advise if there is a better way to undeploy a PU?

Thanks, KP

asked 2018-06-15 09:47:33 -0500

kp's avatar
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

There are multiple ways to undeploy a pu. For example, it can be done from the command line, web ui or in your case using the Admin API. In the end, they are calling the Admin API internally to do the undeployment. So the choice of your tool depends on what suits you. You don't mention why it was unsuccessful.

answered 2018-06-15 11:51:14 -0500

Dixson Huie's avatar
edit flag offensive delete link more


Hi Dixson, I attempted to undeploy using org.openspaces.admin.pu.ProcessingUnit undeploy(). I am unsure why it was unsuccessful that is why I created this question. Regards, KP

kp's avatar kp  ( 2018-06-18 03:25:01 -0500 )edit

Hi Dixson,

To clarify, on calling undeploy(), the Mirror Service PU was removed from Gigaspaces Web UI however the related process was not killed using 'ps -ef' to search for the process id on the node. We noticed that there was a memory shortage error before we undeployed so it may be related?

With previous testing, we noticed that if the Mirror Service PU is INTACT, then usually undeploying it kills the associated process id. However, when the Mirror Service PU is BROKEN, the associated process id is still running when we try to undeploy it.

Perhaps we can kill the GSC itself after the PU undeploy to ensure that the PU resources have been freed up?

Perhaps it is possible to get the process id for the pu and then kill it?

Thanks, KP

kp's avatar kp  ( 2018-06-18 08:05:19 -0500 )edit

If you are using the service grid, then deploying the GSC and the processing unit are 2 distinct steps and these components are managed separately. If you undeploy a processing unit it won't kill the GSC it was running in.

See: https://docs.gigaspaces.com/xap/12.3/... and https://docs.gigaspaces.com/xap/12.3/...

Dixson Huie's avatar Dixson Huie  ( 2018-06-18 14:46:26 -0500 )edit

Hi Dixson, is this applicable to XAP 10.1? Am trying to find the instructions for killing the GSC.

kp's avatar kp  ( 2018-06-19 06:12:49 -0500 )edit

Run kill from the command line, if you're intention is to make the gsa automatically start another one. Otherwise you can do a shutdown, but you would have to start another one.

Dixson Huie's avatar Dixson Huie  ( 2018-06-19 08:36:37 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2018-06-15 09:47:33 -0500

Seen: 396 times

Last updated: Jun 15 '18