Absent Member.
Absent Member.
500 views

ACTIVE MQ:Getting Error:Failed to send message javax.naming.NameNotFoundException

Hi All,

 

I have installed Active MQ and created a Queue named GURU and trying to send a message using Loadrunner Webservice PROTOCOL script,i have configured the below runtime settings:-

 

JNDI initial context factory: org.apache.activemq.jndi.ActiveMQInitialContextFactory
 
 
JNDI provider URL: tcp://127.0.0.1:61616
 
 
JMS connection factory: ConnectionFactory
 
 
JMS security principal : admin
 
 
JMS security credentials: admin

 

My Loadrunner script:-

Action()
{

    jms_set_general_property("Attempt1", 
        "JMS_MESSAGE_TYPE", 
        "TextMessage");
    jms_send_message_queue("Send2", 
        "HI THIS FROM LR", 
        "GURU");    
    return 0;
}

When i ran the above code i am getting the following error:-

 

Error:Failed to send message HI THIS FROM LR to GURU due to the following exception : javax.naming.NameNotFoundException: GURU
javax.naming.NameNotFoundException: GURU
 at org.apache.activemq.jndi.ReadOnlyContext.lookup(ReadOnlyContext.java:235)
 at javax.naming.InitialContext.lookup(Unknown Source)
 at com.mercury.ws.jms.SessionManagerImpl.getQueue(SessionManagerImpl.java:94)
 at com.mercury.ws.jms.JMSSupportImpl.sendMessageQueue(JMSSupportImpl.java:96)
 at com.mercury.ws.jms.JMSBridge.send_message_queue(JMSBridge.java:43)
Action.c(23): Error:JMS call execution failed
Ending action Action.

 

Please let me know what went wrong here.

 

NOTE:-I am able to send a message to Queue named GURU by ACTIVE MQ web console.

 

 

0 Likes
0 Replies
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.