This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
I have created a Connection factory with jndi name 'jmsConnectionFactory1' and a jms queue with jndi name 'Queue-1' in system 10.238.115.217.
And I write the following code and run on a different system (10.238.115.201). It's throwing weblogic.jms.common.JMSException: Connection not found
But if I create those same queues in local system and change the url to t3://localhost:7001 in provider url, connectionfactory,destination queue in the same code ;it works fine,the queue in local system gets the sent message.
Context context= new InitialContext(); context.addToEnvironment(Context.INITIAL_CONTEXT_FACTORY,"weblogic.jndi.WLInitialContextFactory"); context.addToEnvironment(Context.PROVIDER_URL,"t3://10.238.115.217:7001"); context.addToEnvironment(Context.SECURITY_AUTHENTICATION,"weblogic"); context.addToEnvironment(Context.SECURITY_CREDENTIALS,"weblogic"); context.addToEnvironment(Context.SECURITY_PRINCIPAL,"weblogic");
QueueConnectionFactory conFact=(QueueConnectionFactory)context.lookup("t3://10.238.115.217:7001/jmsConnectionFactory1"); QueueConnection connection=conFact.createQueueConnection(); Queue queue=(Queue)context.lookup("t3://10.238.115.217:7001/Queue-1"); QueueSession session=connection.createQueueSession(true,Session.AUTO_ACKNOWLEDGE); QueueSender qs=session.createSender(queue); TextMessage message=session.createTextMessage("hi its very urgent please"); qs.send(message); connection.close();
please help me out..
this excepton is thrown at this statement QueueSession session=connection.createQueueSession(false,Session.AUTO_ACKNOWLEDGE);
weblogic.jms.common.JMSException: Connection not found <Nov 2, 2006 7:33:25 PM IST> <Warning> <EJB> <BEA-010096> <The Message-Driven EJ B: jms_mdb is unable to connect to the JMS destination: Queue-1. Connection fail ed after 2 attempts. The MDB will attempt to reconnect every 10 seconds. This lo g message will repeat every 600 seconds until the condition clears.> <Nov 2, 2006 7:33:25 PM IST> <Warning> <EJB> <BEA-010061> <The Message-Driven EJ B: jms_mdb is unable to connect to the JMS destination: Queue-1. The Error was: [EJB:011010]The JMS destination with the JNDI name: Queue-1 could not be found. Please ensure that the JNDI name in the weblogic-ejb-jar.xml is correct, and the JMS destination has been deployed.>
(it says that jndi name Queue-1 is not found, but I created it in the same way,as I did one in my local system) Thanks [ November 02, 2006: Message edited by: Anil B ]
- Check, you are able to see the "Queue-1" object in the JNDI tree of the source server. - You can directly refer 'Queue-1' instead of 't3://.../Queue-1'. - What type of client is this? stand alone java/ webapp? - what is the weblogic version?
Joined: Nov 02, 2006
Originally posted by gopinathang nathan: - Check, you are able to see the "Queue-1" object in the JNDI tree of the source server. - You can directly refer 'Queue-1' instead of 't3://.../Queue-1'. - What type of client is this? stand alone java/ webapp? - what is the weblogic version?
I'm running the application in action of .jpf in WEBLOGIC 8.1. I'm able to see that Queue-1 in the JNDI tree of that remote system.
Do I need to make any changes in settings of remote server so that it accepts remote connections.I have even tried by unchecking 'Guest Disabled' in compatibility tab of application wide settings.
Hi I got solution to my problem. I used bridge. These are the things U need to make sure of in configuration of bridge.
1. See that the Server names of source and Destination machines of Messaging Bridge are different.
2.See that domain names are also different.
3.See that in both the machines the Guest Disabled is Unchecked in Domain Wide Security settings of both machines, also see that credential checking tab is unchecked and the contents of credential principals in both the machines are the SAME.
4.If the connection factories on both machines are XA enabled,deploy adapters jms-xa-adp on both machines using console (Deployments-connectorModules-upload your files).jms-xa-adp is in weblogic81-server-lib.