|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Integration API |
« View previous topic :: View next topic » |
Author |
Message
|
mail2me.venky |
Posted: Wed Jul 29, 2015 6:36 pm Post subject: Integration API |
|
|
Apprentice
Joined: 11 May 2012 Posts: 26
|
Hi,
I took the IntegrtaionApi jar file alone from the IIB10 installed in my pc. Then i try to connect WMB7.1 remote broker using my below written java code. I got the below shown exception message. Then I started adding org.eclipse.jetty.websocket.api.Session jar file, again compiled and run the code. Its started asking many supportive jar files one after other.
I need to fix this asap. Correct my mistake please.
Error Message:
Exception in thread "main" java.lang.Exception: Unable to connect ESB Broker with HostName :172.13.325.122 and Port No 45000
at ConnectESBBroker.ConnectESBBroker(ConnectESBBroker.java:2
at HelloWorld.main(HelloWorld.java:25)
Caused by: com.ibm.broker.config.proxy.ConfigManagerProxyLoggedSocketException: org.eclipse.jetty.websocket.api.Session
at com.ibm.broker.config.proxy.IntegrationNodeConnectionParameters.checkJettyMissingClass(IntegrationNodeConnectionParameters.java:565)
at com.ibm.broker.config.proxy.IntegrationNodeConnectionParameters.getSender(IntegrationNodeConnectionParameters.java:504)
at com.ibm.broker.config.proxy.BrokerProxy.<init>(BrokerProxy.java:355)
at com.ibm.broker.config.proxy.BrokerProxy.getInstance(BrokerProxy.java:982)
at ConnectESBBroker.ConnectESBBroker(ConnectESBBroker.java:23)
... 1 more
Source code:
import com.ibm.broker.config.proxy.BrokerConnectionParameters;
import com.ibm.broker.config.proxy.BrokerProxy;
import com.ibm.broker.config.proxy.IntegrationNodeConnectionParameters;
/**
*
* Connection Class
*/
public class ConnectESBBroker {
private static BrokerProxy brokerProxy = null;
//private static final BrokerConnectionParameters brkConnParam = new MQPropertyFileBrokerConnectionParameters() {};
public static synchronized BrokerProxy ConnectESBBroker(String qMngrHostName, int qMngrPortNo)
throws Exception {
try {
if (brokerProxy == null) {
brokerProxy = BrokerProxy.getInstance(new IntegrationNodeConnectionParameters(qMngrHostName, qMngrPortNo));
System.out.println("Is the broker running fine ?" + brokerProxy.isRunning());
}
} catch (Exception e) {
throw new Exception("Unable to connect ESB Broker with HostName :" + qMngrHostName
+ " and Port No " + qMngrPortNo,e
);
}
return brokerProxy;
}
}
 |
|
Back to top |
|
 |
stoney |
Posted: Wed Jul 29, 2015 9:03 pm Post subject: |
|
|
Centurion
Joined: 03 Apr 2013 Posts: 140
|
If you are trying to connect to a WMB V7 broker (there is no WMB V7.1, maybe you meant V7.0.0.1?), then you cannot use IntegrationNodeConnectionParameters.
IntegrationNodeConnectionParameters can only connect to V10 integration nodes over HTTP.
In order to connect to WMB V7 brokers, you must connect over MQ - you need to use either MQBrokerConnectionParameters or MQPropertyFileBrokerConnectionParameters.
There are multiple JAR files required to use the Integration API. If you run mqsiprofile, then it sets the CLASSPATH environment variable for you.
I think you need the following JARs in order to use the Integration API:
/common/jetty/lib/websocket-common.jar
/common/jetty/lib/websocket-client.jar
/common/jetty/lib/websocket-api.jar
/common/jetty/lib/jetty-util.jar
/common/jetty/lib/jetty-io.jar
/common/classes/IntegrationAPI.jar
Because you are connecting via MQ, you will also need the MQ classes available on the class path. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|