On Jun 7, 2017 4:14 AM, "Bill Chen" <billc...@iii.org.tw> wrote:

Tim,

I'm sorry that confused you about the reference link.
I'm doing the ActiveMQ way, and I have encountered some questions.

First, how to set the ActiveMQ.Retain property?


You call Message.setBooleanProperty().

Second, I try to add the RetainedMessageSubscriptionRecoveryPolicy in my
configuration, but that occurred exception when activemq start. The
configuration as follows:
<destinationPolicy>
  <policyMap>
    <policyEntries>
      <policyEntry topic=">" >
        <pendingMessageLimitStrategy>
          <constantPendingMessageLimitStrategy limit="1000"/>
        </pendingMessageLimitStrategy>

        <subscriptionRecoveryPolicy>
          <retainedMessageSubscriptionRecoveryPolicy/>
        </subscriptionRecoveryPolicy>
      </policyEntry>
    </policyEntries>
  </policyMap>
</destinationPolicy>


I think I may have led you astray on this one. Per
http://rockablogbaby.blogspot.com/2014/05/scalable-iot-integration-using-apache.html?m=1,
RetainedMessageSubscriptionRecoveryPolicy is always present in the broker,
and doesn't need to be configured explicitly. I'll update the wiki to
reflect that, when I have a chance.

Third, I have successfully received the message from the topic in the
previous test. But I find the subscriber change to that queue on the web
console now.


I don't understand what you're telling me. Are you saying that you switched
to using queues instead of topics and it worked?

I'm not sure what the cause is. The data in activemq_acks table

as follows:
<http://activemq.2283324.n4.nabble.com/file/n4727144/activemq_acks.png>

Bill



--
View this message in context: http://activemq.2283324.n4.nab
ble.com/JDBC-persistence-for-postgresql-tp4727004p4727144.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to