Announcement Announcement Module
Collapse
No announcement yet.
DefaultMessageListenerContainer102 and reconnect on JMS Server down Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • DefaultMessageListenerContainer102 and reconnect on JMS Server down

    Environment: Spring 2.0.3, JBoss 4.0.2

    Based on all the documentation for DefaultMessageListenerContainer102 class, it is supposed to
    reconnect to the JMS server after restart until successful. For some reason that does not seem to happen.
    I don't see any exceptions whatsoever (log level set to DEBUG on org.springframework.jms) and I don't see my delegate getting called.


    Spring Configuration:

    <!-- JMS Setup -->
    <bean id="jndiTemplate" class="org.springframework.jndi.JndiTemplate">
    <property name="environment">
    <props>
    <prop key="java.naming.factory.initial">
    org.jnp.interfaces.NamingContextFactory
    </prop>
    <prop key="java.naming.provider.url">
    jnp://127.0.0.1:1099
    </prop>
    <prop key="java.naming.factory.url.pkgs">
    org.jboss.naming:org.jnp.interfaces
    </prop>
    </props>
    </property>
    </bean>

    <!-- JMS Topic Connection Factory -->
    <bean id="connectionFactory" class="org.springframework.jndi.JndiObjectFactoryB ean">
    <property name="jndiTemplate">
    <ref bean="jndiTemplate"/>
    </property>
    <property name="jndiName">
    <value>ConnectionFactory</value>
    </property>
    </bean>

    <bean id="topicConnectionFactory" class="org.springframework.jms.connection.UserCred entialsConnectionFactoryAdapter">
    <property name="targetConnectionFactory" ref="connectionFactory"/>
    <property name="username" value="events"/>
    <property name="password" value="events"/>
    </bean>

    <!-- JMS Destination -->
    <bean id="destination" class="org.springframework.jndi.JndiObjectFactoryB ean">
    <property name="jndiName">
    <value>topic/ControlEvents</value>
    </property>
    </bean>

    <bean id="attributedModelMessageDelegate" class="com.personal.configmgr.integration.jms.list ener.AttributedModelEventMessageDelegate"/>

    <bean id="attributedModelMessageListener" class="org.springframework.jms.listener.adapter.Me ssageListenerAdapter102">
    <property name="delegate" ref="attributedModelMessageDelegate"/>
    <property name="defaultListenerMethod" value="delegate"/>
    </bean>

    <!-- and this is the message listener container... -->
    <bean id="attributeModelListenerContainer" class="org.springframework.jms.listener.DefaultMes sageListenerContainer102">
    <property name="connectionFactory" ref="topicConnectionFactory" />
    <property name="destination" ref="destination" />
    <property name="messageListener" ref="attributedModelMessageListener" />
    <property name="messageSelector" value="eventName='DCSPartIPersistedEvent'"/>
    <property name="receiveTimeout" value="-1"/>
    <property name="pubSubDomain" value="true"/>
    </bean>


    Is there something obvious I am doing wrong in my configuration?

    Please help

    - Ravi

  • #2
    I don't see any responses, Is it something basic I am doing wrong?

    Since there are no responses to my post, I am assuming that I am doing something very basic wrong. Could one of you experts please point me the mistake or to some documentation?

    Thanks
    Ravi.

    Comment

    Working...
    X