camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mam1 <dbra...@novator.com>
Subject camel-activemq java.util.Map over JMS
Date Sun, 15 Mar 2009 02:38:05 GMT

Hi.

I have a problem using camel activemq/jms components. I used to have a low
level socket communication using Java serialization. One of responses
contained a Serializable object that had a Map<Long, List<Long>> as its
member. 

When I use camel activemq/jms the returned object contains a Map<String,
List<Long>>. Did anybody encounter similar problem? Is it possible to
configure jms/activemq to use Java serialization? Any ideas. BTW using
jms/activemq on both (client/server) sides of the channel results in
aforementioned behavior only on the client side. Server side accepts
Map<Long, List<Long>>  parameter as expected. 

Camel configuration is as following: 

client:  

    <camel:camelContext trace="true">
        <camel:proxy id="test_remoting_service_proxy"
                     serviceInterface="a.b.c.TestService"
                   
serviceUrl="activemq:queue:test.serviceQueue?exchangePattern=InOut"/>
    </camel:camelContext>

server:

    <camel:camelContext>
        <camel:export id="remoting_service"
                serviceRef="test_remoting_service"
                serviceInterface="a.b.c.TestService"
                uri="activemq:queue:test.serviceQueue?exchangePattern=InOut"
/>
    </camel:camelContext>

    <beans:bean id="test_remoting_service" class="a.b.c.TestServiceImpl"/>

    <broker:broker useJmx="false" persistent="false" brokerName="localhost" 
cacheTempDestinations="true" enableStatistics="false">
        <broker:transportConnectors>
            <broker:transportConnector name="tcp"
uri="tcp://localhost:61616?trace=true"/>
        </broker:transportConnectors>
    </broker:broker>


    <!-- configure the activemq component -->
    <beans:bean id="activemq"
class="org.apache.activemq.camel.component.ActiveMQComponent">
        <beans:property name="maxConcurrentConsumers" value="10"/>
        <beans:property name="deliveryPersistent" value="true"/>
        <beans:property name="concurrentConsumers" value="5"/>
        <beans:property name="cacheLevelName" value="CACHE_CONNECTION"/>
        <beans:property name="connectionFactory">
            <beans:bean
class="org.apache.activemq.spring.ActiveMQConnectionFactory">
                <beans:property name="brokerURL"
value="tcp://localhost:61616"/>
            </beans:bean>
        </beans:property>
    </beans:bean>

Thanks in advance. 

-- 
View this message in context: http://www.nabble.com/camel-activemq-java.util.Map-over-JMS-tp22519506p22519506.html
Sent from the Camel - Users (activemq) mailing list archive at Nabble.com.


Mime
View raw message