You can remove deployed objects from an execution group, for example, to rename them..
Before you start:
Stop all message flows in the execution group. See Starting and stopping message flows.
Follow these steps to remove an object from an execution group using the workbench.
An automatic deployment is performed for the updated broker and a BIP08921 information message is produced, which confirms that the request was received by the Configuration Manager.
Follow these steps to remove an object from an execution group using the mqsideploy command:
The command reports when responses are received from the Configuration Manager and any brokers that are affected by the deployment. If the command completes successfully, it returns 0.
import com.ibm.broker.config.proxy.*;
public class DeleteDeployedObjects {
public static void main(String[] args) {
ConfigManagerConnectionParameters cmcp =
new MQConfigManagerConnectionParameters
("localhost", 1414, "QM1");
try {
ConfigManagerProxy cmp =
ConfigManagerProxy.getInstance(cmcp);
TopologyProxy t = cmp.getTopology();
BrokerProxy b = t.getBrokerByName("broker1");
ExecutionGroupProxy e =
b.getExecutionGroupByName("default");
e.deleteDeployedObjectsByName(
new String[] { "file1.cmf",
"file2.cmf" }, 0);
}
catch (ConfigManagerProxyException e) {
e.printStackTrace();
}
}
}