[JBoss-user] [Messaging, JMS JBossMQ] - MDB JBoss jboss-4.0.3SP1 + ActiveMQ 3.2
Hi there, i am useing the ActiveMQ instead of the JBossMQ. The exchange of the MQ should has been correctly finished by now. I can send messages to a topic and receive them. But there is still a big problem. I am unable to use MDB's. At first i tryed to lunch a mdb wirtes data in a postgresql database (it allready worked but under JBossMQ). After getteing not even some exception i started thinging about the name of the topic, but the name of the topic in ejb-jar.xml and the one in the sender app are squaring. The problem could be caused by the xml files, i think. The ejb-jar.xml: ?xml version=1.0 encoding=US-ASCII? | | ejb-jar xmlns=http://java.sun.com/xml/ns/j2ee; |xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; |xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd; |version=2.1 | |description | A collection of simple EJBs for testing ActiveMQ integration with JBoss. |/description | |enterprise-beans | | message-driven | descriptionAn MDB listening on a topic with a non-durable subscription./description | ejb-nameMyMbean/ejb-name | ejb-classde.package.OnMessageFromTopic/ejb-class | messaging-typejavax.jms.MessageListener/messaging-type | transaction-typeContainer/transaction-type | activation-config | activation-config-property | activation-config-property-namedestination/activation-config-property-name | activation-config-property-valuetopic.testTopic/activation-config-property-value | /activation-config-property | activation-config-property | activation-config-property-namedestinationType/activation-config-property-name | activation-config-property-valuejavax.jms.Topic/activation-config-property-value | /activation-config-property | activation-config-property | activation-config-property-nameacknowledgeMode/activation-config-property-name | activation-config-property-valueAuto-acknowledge/activation-config-property-value | /activation-config-property | activation-config-property | activation-config-property-namesubscriptionDurability/activation-config-property-name | activation-config-property-valueNonDurable/activation-config-property-value | /activation-config-property | activation-config-property | activation-config-property-namemessageSelector/activation-config-property-name |activation-config-property-value/ | /activation-config-property | /activation-config | | /message-driven | |/enterprise-beans | |assembly-descriptor | container-transaction | method | ejb-nameMyMbean/ejb-name | method-name*/method-name | /method | trans-attributeRequired/trans-attribute | /container-transaction |/assembly-descriptor | /ejb-jar | and the jboss.xml: ?xml version=1.0 encoding=UTF-8? | | !DOCTYPE jboss PUBLIC | -//JBoss//DTD JBOSS 4.0//EN | http://www.jboss.org/j2ee/dtd/jboss_4_0.dtd; | | jboss |jmx-nameactivemq.rar:name=iTests/jmx-name |enterprise-beans | message-driven | ejb-nameMyMbean/ejb-name | resource-adapter-nameactivemq-ra-3.2.rar/resource-adapter-name | configuration-nameActiveMQ Message Driven Bean/configuration-name | /message-driven |/enterprise-beans | |resource-managers | resource-manager | res-nametopicfactoryref/res-name | res-jndi-namejava:/activemq/TopicConnectionFactory/res-jndi-name | /resource-manager |/resource-managers | |invoker-proxy-bindings | invoker-proxy-binding | nameactivemq-message-driven-bean/name | invoker-mbeandefault/invoker-mbean | proxy-factoryorg.jboss.ejb.plugins.inflow.JBossMessageEndpointFactory/proxy-factory | proxy-factory-config | endpoint-interceptors | interceptororg.jboss.proxy.ClientMethodInterceptor/interceptor | interceptororg.jboss.ejb.plugins.inflow.MessageEndpointInterceptor/interceptor | interceptororg.jboss.proxy.TransactionInterceptor/interceptor | interceptororg.jboss.invocation.InvokerInterceptor/interceptor | /endpoint-interceptors | /proxy-factory-config | /invoker-proxy-binding |/invoker-proxy-bindings | |container-configurations | container-configuration | container-nameActiveMQ Message Driven Bean/container-name |
[JBoss-user] [Messaging, JMS JBossMQ] - MDB with JBoss
I am trying to get the MDB example from the JBoss documentation running. Here is what I have to get a connection and a queue, etc: public void setupPTP() throws JMSException, NamingException { Properties properties = new Properties(); properties.setProperty(Context.INITIAL_CONTEXT_FACTORY, org.jnp.interfaces.NamingContextFactory); properties.setProperty(Context.PROVIDER_URL, jnp://localhost:1099/); properties.setProperty(Context.URL_PKG_PREFIXES, org.jboss.naming:org.jnp.interfaces); InitialContext iniCtx = new InitialContext(properties); Object tmp = iniCtx.lookup(ConnectionFactory); QueueConnectionFactory qcf = (QueueConnectionFactory)tmp; conn = qcf.createQueueConnection(); queA = (Queue)iniCtx.lookup(queue/A); queB = (Queue)iniCtx.lookup(queue/B); session = conn.createQueueSession(false, QueueSession.AUTO_ACKNOWLEDGE); conn.start(); } When executing Object tmp = iniCtx.lookup(ConnectionFactory) I get this exception: javax.naming.CommunicationException. Root exception is java.rmi.ConnectException: Connection refused to host: 64.91.160.168; nested exception is: java.net.ConnectException: Connection refused: connect Can anyone tell me what I am doing wrong? Where is 64.91.160.168 coming from? Thanks!! Dan View the original post : http://www.jboss.org/index.html?module=bbop=viewtopicp=3830593#3830593 Reply to the post : http://www.jboss.org/index.html?module=bbop=postingmode=replyp=3830593 --- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id=1470alloc_id=3638op=click ___ JBoss-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-user