Skip to content
业余布道师 edited this page Dec 12, 2017 · 3 revisions

RocketMQ DefaultMQProducer, config like this

<!-- RocketMQ DefaultMQProducer-->
<bean id="rocketmqProducer" class="org.apache.rocketmq.client.producer.DefaultMQProducer" init-method="start"
          destroy-method="shutdown">
        <property name="producerGroup" value="prospringtest"/> <!-- Your producer id -->
        <property name="namesrvAddr" value="localhost:9876"/> <!-- Your name server address-->
</bean>

RocketMQ TransactionMQProducer, config like this

<!-- RocketMQ TransactionMQProducer-->
<bean id="rocketmqProducer" class="org.apache.rocketmq.client.producer.TransactionMQProducer" init-method="start"
          destroy-method="shutdown">
        <property name="producerGroup" value="prospringtest"/> <!-- Your producer id -->
        <property name="namesrvAddr" value="localhost:9876"/> <!-- Your name server address-->
        <property name="transactionCheckListener" ref="transactionCheckListener"/> <!-- Your listener -->
</bean>

Other config see Apache RocketMQ.