I meet a problem ,please refer to the following codes
| Object tmp = iniCtx.lookup(TOPIC_CONNECTION_FACTORY_KEY); | | String connectStatusTopicName = | ConfigUtils.getProperties().getProperty("ConnectStatusTopicName", | "TopicStatus"); | TopicConnectionFactory tcf = (TopicConnectionFactory) tmp; | topic2 = (Topic) iniCtx.lookup(connectStatusTopicName); | conn = tcf.createTopicConnection(); | session = conn.createTopicSession(false, TopicSession.AUTO_ACKNOWLEDGE); | conn.start(); | TopicSubscriber topicSubscriber = session.createDurableSubscriber( | topic2, "health"); | topicSubscriber.setMessageListener(receiver2); | all is the default configure. when TOPIC_CONNECTION_FACTORY_KEY is "ConnectionFactory" ,it's ok. but when TOPIC_CONNECTION_FACTORY_KEY is "java:/JmsXA", I will meet the following problem caused by "topicSubscriber.setMessageListener(receiver2);" javax.jms.IllegalStateException: This method is not applicable inside the application server. See the J2EE spec, e.g. J2EE1.4 Section 6.6 at org.jboss.resource.adapter.jms.JmsSession.checkStrict(JmsSession.java:531) at org.jboss.resource.adapter.jms.JmsMessageConsumer.setMessageListener(JmsMessageConsumer.java:135) ...................................... after I checked the J2ee1.4 spec section6.6, I still don't understand . can you help me ??? thank you .l " View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3932849#3932849 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3932849 ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user