Error trying to start/stop ESB process from a program

Posted by teeljb on 08-Mar-2012 17:00

I'm running ESB V7.6, and I'm trying to start/stop an ESB process from an "outside" (not within a custom service) Java program. I used the "Deployment.java" sample program as a starting point, and basically replaced the config calls with runtime calls. Basically, my program does:

ESBAPIFactory fact = ESBAPIFactory.createESBAPIFactory();

ESBAPI api = fact.createAPI(domain, url, user, password);

IContainerRuntimeAPI runApi = api.getContainerRuntimeAPI(mfCtName, esbCtName);

ESBArtifactInfo [] esbAInfo = runApi.startProcesses(pNames);

The last statement causes a ESBAPIException:

com.sonicsw.esb.mgmtapi.ESBAPIEsception: com.sonicsw.mf.jmx.client.CommunicationException: Failed invoke

  at com.sonicsw.esb.mgmtapi.runtime.impl.EsbContainerRuntimeAPI.modifyArtifacts(EsbContainerRuntimeAPI.java:135)

  at com.sonicsw.esb.mgmtapi.runtime.impl.EsbContainerRuntimeAPI.stopProcesses(EsbContainerRuntimeAPI.java:102)

  at com.superioressex.SonicMgmt.SonicMgmt.stopProcess(SonicMgmt.java:149)

  at com.superioressex.SonicMgmt.SonicMgmt.main(SonicMgmt.java:70)

Caused by: com.sonicsw.mf.jmx.client.CommunicationException: Failed invoke

  at com.sonicsw.mf.jmx.client.JMSConnectorClient.invoke(Unknown Source)

  at com.sonicsw.mf.jmx.client.JMSConnectorClient.invoke(Unknown Source)

  at com.sonicsw.esb.mgmtapi.impl.DSConfigSPIImpl.invoke(DSConfigSPIImpl.java:208)

  at com.sonicsw.esb.mgmtapi.runtime.impl.EsbContainerRuntimeAPI.invokeLifecycleMethod(EsbContainerRuntimeAPI.java:160)

  at com.sonicsw.esb.mgmtapi.runtime.impl.EsbContainerRuntimeAPI.invokeMethod(EsbContainerRuntimeAPI.java:146)

  at com.sonicsw.esb.mgmtapi.runtime.impl.EsbContainerRuntimeAPI.modifyArtfacts(EsbContainerRuntimeAPI.java:131)

  ... 3 more

There doesn't seem to be much in the way of documentation for ESB administrative programming (at least for V7.6); I found the Javadoc for it, but there is no ESB Admin programming guide.

Does anybody have any ideas?

Thanks and regards,

Jim

All Replies

Posted by teeljb on 08-Mar-2012 19:42

Upon further testing/debugging, I find that the process(es) I'm trying to start/stop ARE actually getting altered; I just receive the exception nonetheless.

I'm beginning to suspect the error is related to the IConnectionListener...which I've not set (nor even understand what it's for.)

This thread is closed