//Properties that appear in the destination above must "really" be set in a JMS adapter
JMSAdapter adapter = new JMSAdapter();
adapter.setId("jms");
// Use JMSSettings object for the <jms> properties above
JMSSettings js = new JMSSettings();
js.setDestinationType("Topic");
js.setMessageType("javax.jms.TextMessage");
String jndiAppend = "";
if (getAppServer() == "tomcat")
{
// System.out.println("***** running on TomCat - appending java:comp/env/ *****)");
jndiAppend = "java:comp/env/";
}
Log.getLogger("QE.DEBUG").debug("jndiAppend =" + jndiAppend);
System.out.println("appServer: " + getAppServer() );
if (getAppServer() == "jboss") {
// System.out.println("****running on jboss *****)");
// js.setConnectionFactory(jndiAppend + "jms/flex/TopicConnectionFactory");
// js.setDestinationJNDIName(jndiAppend + "jms/topic/flex/simpletopic");
// Changing this to match the names in jbossmq-destinations-service.xml, jms-ds.xml (in \default\deploy\jms directory),
// and messaging-config.xml on the jboss regression machine
js.setConnectionFactory("java:XAConnectionFactory");
js.setDestinationJNDIName("topic/FlexTopic");
}
else {
// System.out.println("***** not jboss *****)");
js.setConnectionFactory(jndiAppend + "jms/flex/TopicConnectionFactory");
js.setDestinationJNDIName(jndiAppend + "jms/topic/flex/simpletopic");
}
js.setDeliveryMode("NON_PERSISTENT");
js.setMessagePriority(javax.jms.Message.DEFAULT_PRIORITY);
js.setAcknowledgeMode("AUTO_ACKNOWLEDGE");
adapter.setJMSSettings(js);
adapter.getJMSSettings();
adapter.setDestination(msgDest);
return msgDest;