Friday, October 10, 2008

Connecting From Weblogic Server to Tibco through JMS :

From TIBCO Server Side:

1. Install Tibco EMS 4.2.0
2. Start the TIBCO Enterprise Message Server by selecting Start->Programs->TIBCO Enterprise Message Service 4.2->Start EMS Server from the Windows Start menu.
3. Start the TIBCO Enterprise Message Service administration tool by selecting Start->Programs->TIBCO Enterprise Message Service 4.2->Start EMS Administration Tool from the Windows Start menu.
4. Enter the following commands: ( From Tibco side )

> connect :7222
> create factory XAQueueConnectionFactory XAQueueConnectionFactory
> create queue TibcoRequestQueue

Recommendations
Note: The following modification is required for any scenario which uses an external Tibco EMS server.
Tibco EMS Configuration
During the process of integrating BEA WebLogic and Tibco EMS, it was discovered that the application was not connecting properly to the JMS queues. Error messages were being logged in the WebLogic application stating that no connection to 'localhost' was available:
“NestedException Message is: Failed to connect to the server at tcp://localhost:7222>
The problem is that the default URL property for a queue connection factory in Tibco EMS is invalid for scenarios using an external server. This was fixed by modifying the configuration on the EMS server in the following manner:
• Log in to the Tibco EMS administration console
• Add the appropriate URL property to the newly created factory
addprop factory XAQueueConnectionFactory url=tcp://
:7222
This configuration change is reflected in the factories.conf file located in the C:\tibco\ems\bin or /opt/tibco/ems/bin directory.

5. Include at least tibjms.jar file, and other jars if needed in the classpath of the WebLogic server:


set TIBCO_EMS_DIR=C:\tibco\ems\clients\java
set PRE_CLASSPATH=%PRE_CLASSPATH%;%TIBCO_EMS_DIR%\tibcrypt.jar;%TIBCO_EMS_DIR%\tibjms.jar;%TIBCO_EMS_DIR%\tibjmsadmin.jar;%TIBCO_EMS_DIR%\tibjmsapps.jar;%TIBCO_EMS_DIR%\tibrvjms.jar



4. Make sure TIBCO EMS server (tibemsd) is running. Create a new JMS system module SystemModuleTestTibcoEMS deployed on the cluster.

From weblogic Side :


Foreign JMS server:
Name: “ForeignServerTibco”
JNDI Initial Context Factory: "com.tibco.tibjms.naming.TibjmsInitialContextFactory"
JNDI Connection URL: "tibjmsnaming://
:7222"

Foreign Connection Factories:
Name: “TIBCO XAQueueConnectionFactory”
Local JNDI Name: “TIBCO.xaqcf”
Remote JNDI Name: “XAQueueConnectionFactory”

Foreign Destinations:
Name: “TIBCO JMSQueue TibcoRequestQueue:
Local JNDI Name: “TIBCO.TibcoRequestQueue”
Remote JNDI Name: “TibcoRequestQueue”


2 comments:

Anonymous said...

Hi,
I've done this and am getting


...the url *is specified in the foreign server JNDI Connection URL.

Any idea why?

Thanks

Anonymous said...

sorry error :
The Message-Driven EJB: MessageReceiver is unable to connect to the JMS destination: LOCAL-JNDI-DRD-RFI-QUEUE. The Error was:
Can not get distribute destination information. The destination JNDI name is LOCAL-JNDI-DRD-RFI-QUEUE, the provider URL is null