You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by ENP <pr...@stc.donpac.ru> on 2006/06/02 13:35:43 UTC
Persistance problems
I have incubator-activemq-4.0 with config:
<beans xmlns="http://activemq.org/config/1.0">
<broker useJmx="true">
<persistenceAdapter>
<journaledJDBC journalLogFiles="5" dataDirectory="../activemq-data"/>
</persistenceAdapter>
<transportConnectors>
<transportConnector name="default" uri="tcp://localhost:61616"/>
</transportConnectors>
</broker>
</beans>
After running with code:
ActiveMQConnection connection = ActiveMQConnection.makeConnection();
connection.start();
Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
Destination destination = session.createTopic("monitoring.m1");
MessageProducer producer = session.createProducer(destination);
String text = "Hello world! From: " + Thread.currentThread().getName();
TextMessage message = session.createTextMessage(text);
System.out.println("Sent message: "+ message.hashCode() + " : " +
Thread.currentThread().getName());
producer.send(message);
session.close();
connection.close();
I see new message via JMX (I use jManage)
After restarting AMQ I can't see this message and I can't see topic
"monitoring.m1"!
Why can it be?
--
View this message in context: http://www.nabble.com/Persistance-problems-t1722163.html#a4678101
Sent from the ActiveMQ - User forum at Nabble.com.
Re: Persistance problems
Posted by Hiram Chirino <hi...@hiramchirino.com>.
When you browse messages in a amq 4 topic with jmx, your, browsing the
messages that are being held in the subscription recovery policy
configured for that topic. We don't provide a way to browse the
messages being help for a durable topic subscription yet.
On 6/2/06, ENP <pr...@stc.donpac.ru> wrote:
>
> I have incubator-activemq-4.0 with config:
>
> <beans xmlns="http://activemq.org/config/1.0">
> <broker useJmx="true">
> <persistenceAdapter>
> <journaledJDBC journalLogFiles="5" dataDirectory="../activemq-data"/>
> </persistenceAdapter>
> <transportConnectors>
> <transportConnector name="default" uri="tcp://localhost:61616"/>
> </transportConnectors>
> </broker>
> </beans>
>
> After running with code:
>
> ActiveMQConnection connection = ActiveMQConnection.makeConnection();
> connection.start();
> Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
> Destination destination = session.createTopic("monitoring.m1");
> MessageProducer producer = session.createProducer(destination);
> String text = "Hello world! From: " + Thread.currentThread().getName();
> TextMessage message = session.createTextMessage(text);
> System.out.println("Sent message: "+ message.hashCode() + " : " +
> Thread.currentThread().getName());
> producer.send(message);
> session.close();
> connection.close();
>
> I see new message via JMX (I use jManage)
>
> After restarting AMQ I can't see this message and I can't see topic
> "monitoring.m1"!
>
> Why can it be?
> --
> View this message in context: http://www.nabble.com/Persistance-problems-t1722163.html#a4678101
> Sent from the ActiveMQ - User forum at Nabble.com.
>
>
--
Regards,
Hiram