You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by jlindwall <jl...@yahoo.com> on 2014/02/07 01:01:18 UTC
Where's the records in my jdbc persistence store?
I have configured activemq 5.9.0 to use jdbc persistence (oracle). I know
that part is correct because 3 ACTIVEMQ tables "magically" get created in
Oracle, and I see log messages that make me feel like jdbc is in use. So far
so good.
I am curious to see some of the queued messages in my database. I am using
a jmeter test driver that is sending persistent messages to a topic in my
activemq server. The publisher sends 100 msgs/sec, while the lone consumer
is pulling just 5 msgs/sec. With a slow consumer like this I expected to
quickly see records appearing in the ACTIVEMQ_MSGS table, yet none ever do.
Any ideas? Thanks!
--
View this message in context: http://activemq.2283324.n4.nabble.com/Where-s-the-records-in-my-jdbc-persistence-store-tp4677577.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Re: Where's the records in my jdbc persistence store?
Posted by Christian Posta <ch...@gmail.com>.
Topics are a "broadcast" model and have no notion of "persistence"
unless there is a durable subscriber... Either use a queue for your
persistent messages, or use at least one durable subscriber:
http://docs.oracle.com/javaee/1.3/jms/tutorial/1_3_1-fcs/doc/advanced.html#1024758
On Thu, Feb 6, 2014 at 5:01 PM, jlindwall <jl...@yahoo.com> wrote:
> I have configured activemq 5.9.0 to use jdbc persistence (oracle). I know
> that part is correct because 3 ACTIVEMQ tables "magically" get created in
> Oracle, and I see log messages that make me feel like jdbc is in use. So far
> so good.
>
> I am curious to see some of the queued messages in my database. I am using
> a jmeter test driver that is sending persistent messages to a topic in my
> activemq server. The publisher sends 100 msgs/sec, while the lone consumer
> is pulling just 5 msgs/sec. With a slow consumer like this I expected to
> quickly see records appearing in the ACTIVEMQ_MSGS table, yet none ever do.
>
> Any ideas? Thanks!
>
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.nabble.com/Where-s-the-records-in-my-jdbc-persistence-store-tp4677577.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
--
Christian Posta
http://www.christianposta.com/blog
twitter: @christianposta
Re: Where's the records in my jdbc persistence store?
Posted by jlindwall <jl...@yahoo.com>.
Yep, using a durable subscriber did the trick indeed! Thanks.
--
View this message in context: http://activemq.2283324.n4.nabble.com/Where-s-the-records-in-my-jdbc-persistence-store-tp4677577p4677591.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Re: Where's the records in my jdbc persistence store?
Posted by jlindwall <jl...@yahoo.com>.
Interesting. I must have a flawed understanding of durable subscribers. I
thought it signified a consumer that can disconnect/reconnect and any
messages that arrived in the time while the subscriber was disconnected will
still be delivered. Cool, but not what we thought we needed.
Intuitively to me the above "durable subscriber" concept does not preclude
having persistent messages in effect for non-durable subscribers: the
thought being if the broker crashes we still want the (in "memory")
as-yet-undelivered messages to be delivered after failover occurs. we
really have no need for disconnecting/reconnecting subscribers while our app
is running - the subscribers connect and stay connected.
I'm sure I did not explain that very clearly :) I will try using a durable
subscriber and see if my messages magically apperar in the db.
THANKS! I appreciate your response.
--
View this message in context: http://activemq.2283324.n4.nabble.com/Where-s-the-records-in-my-jdbc-persistence-store-tp4677577p4677588.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Re: Where's the records in my jdbc persistence store?
Posted by Christian Posta <ch...@gmail.com>.
I hear you.
But you have to consider the fact that *unless you use durable
subscriptions* AND send persistent messages, you will NOT see messages
stored to the DB.
On Thu, Feb 6, 2014 at 5:06 PM, jlindwall <jl...@yahoo.com> wrote:
> Some additional info: I can capture the summary information in my
> jmeter-based subscriber so we can see the JMS message headers. I am
> appending this info here in case it helps diagnose my problem.
>
> FYI There are never any records created in ACTIVEMQ_ACKS either, as far as I
> can tell. I am using the TOAD GUI to watch these tables.
>
> To reiterate: I would like to prove that jdbc persistence is working by
> forcing records to be created in ACTIVEMQ_MSGS.
>
>
> Thread Name: Subscribers 1-1
> Sample Start: 2014-02-06 16:02:49 PST
> Load time: 33
> Latency: 0
> Size in bytes: 14
> Headers size in bytes: 0
> Body size in bytes: 14
> Sample Count: 1
> Error Count: 0
> Response code: 200
> Response message: 1 message(s) received successfully
>
> Response headers:
> JMSCorrelationId null
> JMSMessageId ID:my.server.com-52812-1391730613955-9:1:1:1:15105
> JMSTimestamp 1391731369440
> JMSType null
> JMSExpiration 1391731399440
> JMSPriority 4
> JMSDestination topic://my.custom.Topic
> Properties:
> User sammy
> Id ACCT-1234567890
> Component JMeterTestFixture
> Time 1389916241828
> Creator com.mbasys.fake.creatorId.JMeter@1f4b9e9
> Create true
>
>
> SampleResult fields:
> ContentType:
> DataEncoding: null
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.nabble.com/Where-s-the-records-in-my-jdbc-persistence-store-tp4677577p4677579.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
--
Christian Posta
http://www.christianposta.com/blog
twitter: @christianposta
Re: Where's the records in my jdbc persistence store?
Posted by jlindwall <jl...@yahoo.com>.
Some additional info: I can capture the summary information in my
jmeter-based subscriber so we can see the JMS message headers. I am
appending this info here in case it helps diagnose my problem.
FYI There are never any records created in ACTIVEMQ_ACKS either, as far as I
can tell. I am using the TOAD GUI to watch these tables.
To reiterate: I would like to prove that jdbc persistence is working by
forcing records to be created in ACTIVEMQ_MSGS.
Thread Name: Subscribers 1-1
Sample Start: 2014-02-06 16:02:49 PST
Load time: 33
Latency: 0
Size in bytes: 14
Headers size in bytes: 0
Body size in bytes: 14
Sample Count: 1
Error Count: 0
Response code: 200
Response message: 1 message(s) received successfully
Response headers:
JMSCorrelationId null
JMSMessageId ID:my.server.com-52812-1391730613955-9:1:1:1:15105
JMSTimestamp 1391731369440
JMSType null
JMSExpiration 1391731399440
JMSPriority 4
JMSDestination topic://my.custom.Topic
Properties:
User sammy
Id ACCT-1234567890
Component JMeterTestFixture
Time 1389916241828
Creator com.mbasys.fake.creatorId.JMeter@1f4b9e9
Create true
SampleResult fields:
ContentType:
DataEncoding: null
--
View this message in context: http://activemq.2283324.n4.nabble.com/Where-s-the-records-in-my-jdbc-persistence-store-tp4677577p4677579.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.