Ace-T's Blog 내 검색 [네이버 커넥트 이웃 합니다~^-^/ 요청 大 환영~~]

HornetQ, JMS Client using Springframework and Maven

OpenSource/Spring 2013. 3. 22. 17:58
[Good Comment!!, Good Discussion!!, Good Contens!!]
[ If you think that is useful, please click the finger on the bottom~^-^good~ ]
by ace-T

spring에서 JMS > HornetQ를 쓸려고 찾아보다 보니..

요런 튜토리얼이 있었고 거기에는..
  • /lib/hornetq-bootstrap.jar
  • /lib/hornetq-core.jar
  • /lib/hornetq-jms.jar
  • /lib/hornetq-logging.jar
  • /lib/jnpserver.jar
  • /lib/netty.jar
  • 요런것들이 필요하다~~라고 되어있었지만..현재 프로젝트는 메이븐 프로젝트였다..

    다시 찾아봤더니..아래에 좋은 사이트를 발견하였다^^

    외국인 친구 땡큐!


    I’ve just been working getting working in our project. We are using Spring and Maven.

    Here is an example to get it working:

    Maven dependency configuration:

        <!-- JMS -->
        <!-- HornetQ -->

    Note you *DON’T* need the hornetq-transports dependency. There is a lot of old ‘help’ with only seems to work using version 2.0.0.GA with did use that JAR.

    Spring configuration:

        <bean name="qConnectionFactory" class="org.hornetq.jms.client.HornetQXAConnectionFactory" >
        <constructor-arg value="false" />
            <bean name="transportConfiguration" class="org.hornetq.api.core.TransportConfiguration">
                <constructor-arg value="org.hornetq.core.remoting.impl.netty.NettyConnectorFactory" />
                    <map key-type="java.lang.String" value-type="java.lang.Object">
                        <entry key="host" value="" />
                        <entry key="port" value="5445" />
        <bean name="theQueue" class="org.hornetq.jms.client.HornetQQueue">
           <constructor-arg value="someName" />
        <bean name="jmsTemplate" class="org.springframework.jms.core.JmsTemplate">
            <property name="connectionFactory" ref="qConnectionFactory" />
            <property name="defaultDestinationName" value="theQueue" />

    Note the class used to configure the netty connector factory. That’s what is different between the 2.2.18 version (it’s in the core now) and the 2.0.0.

    'OpenSource > Spring' 카테고리의 다른 글

    @Vaild 처리 시 주의 할 사항!!  (0) 2013.06.21
    Spring jmsTemplate 사용하기  (0) 2013.03.26
    HornetQ, JMS Client using Springframework and Maven  (0) 2013.03.22
    @XMLAccessorType, @XMLRootElement  (0) 2013.01.21
    spring bean 등록 방법  (0) 2013.01.04
    decompiler for eclipse  (0) 2012.11.14

    acet 박태하가 추천하는 readtrend 추천글!




    :::: facebook을 이용하시는 분들은 로그인 후 아래에 코멘트를 남겨주세요 ::::