[
https://issues.apache.org/activemq/browse/AMQ-1137?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_37974
]
Helmut Janknecht commented on AMQ-1137:
---------------------------------------
When taking a {{jstack}} snapshot while producer is running I can see that it
spents a lot of time in {{java.util.concurrent.ArrayBlockingQueue.take()}}:
{noformat}
Thread 11071: (state = BLOCKED)
- java.lang.Object.wait(long) @bci=0 (Interpreted frame)
- java.lang.Object.wait() @bci=2, line=474 (Interpreted frame)
- edu.emory.mathcs.backport.java.util.concurrent.locks.CondVar.await()
@bci=72, line=75 (Interpreted frame)
- edu.emory.mathcs.backport.java.util.concurrent.ArrayBlockingQueue.take()
@bci=16, line=318 (Interpreted frame)
- org.apache.activemq.transport.FutureResponse.getResult() @bci=4, line=42
(Interpreted frame)
- org.apache.activemq.transport.ResponseCorrelator.request(java.lang.Object)
@bci=8, line=75 (Interpreted frame)
-
org.apache.activemq.ActiveMQConnection.syncSendPacket(org.apache.activemq.command.Command)
@bci=20, line=1171 (Interpreted frame)
- org.apache.activemq.TransactionContext.commit() @bci=55, line=260
(Interpreted frame)
- org.apache.activemq.ActiveMQSession.commit() @bci=25, line=464 (Interpreted
frame)
- ProducerTool.sendLoop(javax.jms.Session, javax.jms.MessageProducer) @bci=126
(Interpreted frame)
- ProducerTool.run() @bci=353 (Interpreted frame)
- ProducerTool.main(java.lang.String[]) @bci=52 (Interpreted frame)
{noformat}
I also tried to set "tcp://localhost:61616?tcpNoDelay=true" so use this
TCP_NODELAY option - no improvement at all :-(
> Transactional, non persistent queing very slow under Linux
> ----------------------------------------------------------
>
> Key: AMQ-1137
> URL: https://issues.apache.org/activemq/browse/AMQ-1137
> Project: ActiveMQ
> Issue Type: Bug
> Components: Broker
> Affects Versions: 4.1.0
> Reporter: Helmut Janknecht
>
> h2. USE CASE
> # Take 4.1.0 Release from
> http://people.apache.org/repo/m2-incubating-repository/org/apache/activemq/apache-activemq/4.1.0-incubator/apache-activemq-4.1.0-incubator.zip
> and unzip on a Linux box (SuSE 10.1, Kernel 2.6.16 with 2GB RAM and
> Xeon(TM) CPU 2.80GHz
> # Edit {{conf/activemq.xml}} and disable ssl and stomp transport
> # Start broker: {{apache-activemq-4.1.0-incubator/bin> java -jar run.jar}}
> # Edit {{example/build.xml}} and set max=1000 (send 1000 messages to queue)
> and *transacted=true*
> # Run producer: {{ant producer}}
> h2. Results
> {code:title=broker logfile}
> ACTIVEMQ_HOME: /home/janknecht/tmp/apache-activemq-4.1.0-incubator
> Loading message broker from: xbean:activemq.xml
> INFO BrokerService - ActiveMQ 4.1.0-incubator JMS Message
> Broker (localhost) is starting
> INFO BrokerService - For help or more information please
> see: http://incubator.apache.org/activemq/
> INFO ManagementContext - JMX consoles can connect to
> service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi
> INFO JDBCPersistenceAdapter - Database driver recognized:
> [apache_derby_embedded_jdbc_driver]
> INFO DefaultDatabaseLocker - Attempting to acquire the exclusive
> lock to become the Master broker
> INFO DefaultDatabaseLocker - Becoming the master on dataSource:
> [EMAIL PROTECTED]
> INFO JournalPersistenceAdapter - Journal Recovery Started from: Active
> Journal: using 5 x 20.0 Megs at:
> /home/janknecht/tmp/apache-activemq-4.1.0-incubator/activemq-data/journal
> INFO JournalPersistenceAdapter - Journal Recovered: 0 message(s) in
> transactions recovered.
> INFO TransportServerThreadSupport - Listening for connections at:
> tcp://acxlin.wu.ssn:61616
> INFO TransportConnector - Connector openwire Started
> INFO NetworkConnector - Network Connector default-nc Started
> INFO BrokerService - ActiveMQ JMS Message Broker
> (localhost, ID:acxlin.wu.ssn-60609-1169619821670-1:0) started
> {code}
> {code:title=producer output}
> producer:
> [echo] Running producer against server at $url = tcp://localhost:61616
> for subject $subject = TEST.FOO
> [java] Connecting to URL: tcp://localhost:61616
> [java] Publishing a Message with size 1000 to queue: TEST.FOO
> [java] Using non-persistent messages
> [java] Sleeping between publish 0 ms
> [java] Sending message: Message: 0 sent at: Wed Jan 24 07:28:14 CET 2007
> ...
> [java] Sending message: Message: 1 sent at: Wed Jan 24 07:28:14 CET 2007
> ...
> [java] Sending message: Message: 2 sent at: Wed Jan 24 07:28:14 CET 2007
> ...
> [java] Sending message: Message: 3 sent at: Wed Jan 24 07:28:15 CET 2007
> ...
> [java] Sending message: Message: 4 sent at: Wed Jan 24 07:28:15 CET 2007
> ...
> [java] Sending message: Message: 5 sent at: Wed Jan 24 07:28:15 CET 2007
> ...
> ...
> [java] Sending message: Message: 998 sent at: Wed Jan 24 07:28:55 CET
> 2007...
> [java] Sending message: Message: 999 sent at: Wed Jan 24 07:28:55 CET
> 2007...
> [java] Done.
> [java] connection {
> [java] session {
> [java] messageCount{ count: 1000 unit: count startTime:
> 1169620094893 lastSampleTime: 1169620135606 description: Number of messages
> exchanged }
> [java] messageRateTime{ count: 1000 maxTime: 126 minTime: 4
> totalTime: 40688 averageTime: 40.688 averageTimeExMinMax: 40.63927855711423
> averagePerSecond: 24.57727093983484 averagePerSecondExMinMax:
> 24.606736032348735 unit: millis startTime: 1169620094893 lastSampleTime:
> 1169620135606 description: Time taken to process a message (thoughtput rate) }
> [java] pendingMessageCount{ count: 0 unit: count startTime:
> 1169620094893 lastSampleTime: 1169620094893 description: Number of pending
> messages }
> [java] expiredMessageCount{ count: 0 unit: count startTime:
> 1169620094893 lastSampleTime: 1169620094893 description: Number of expired
> messages }
> [java] messageWaitTime{ count: 0 maxTime: 0 minTime: 0 totalTime: 0
> averageTime: 0.0 averageTimeExMinMax: 0.0 averagePerSecond: 0.0
> averagePerSecondExMinMax: 0.0 unit: millis startTime: 1169620094893
> lastSampleTime: 1169620094893 description: Time spent by a message before
> being delivered }
> [java] durableSubscriptionCount{ count: 0 unit: count startTime:
> 1169620094893 lastSampleTime: 1169620094893 description: The number of
> durable subscriptions }
> [java] producers {
> [java] producer queue://TEST.FOO {
> [java] messageCount{ count: 1000 unit: count startTime:
> 1169620094918 lastSampleTime: 1169620135606 description: Number of messages
> processed }
> [java] messageRateTime{ count: 1000 maxTime: 126 minTime: 4
> totalTime: 40688 averageTime: 40.688 averageTimeExMinMax: 40.63927855711423
> averagePerSecond: 24.57727093983484 averagePerSecondExMinMax:
> 24.606736032348735 unit: millis startTime: 1169620094918 lastSampleTime:
> 1169620135606 description: Time taken to process a message (thoughtput rate) }
> [java] pendingMessageCount{ count: 0 unit: count startTime:
> 1169620094918 lastSampleTime: 1169620094918 description: Number of pending
> messages }
> [java] messageRateTime{ count: 1000 maxTime: 126 minTime: 4
> totalTime: 40688 averageTime: 40.688 averageTimeExMinMax: 40.63927855711423
> averagePerSecond: 24.57727093983484 averagePerSecondExMinMax:
> 24.606736032348735 unit: millis startTime: 1169620094918 lastSampleTime:
> 1169620135606 description: Time taken to process a message (thoughtput rate) }
> [java] expiredMessageCount{ count: 0 unit: count startTime:
> 1169620094918 lastSampleTime: 1169620094918 description: Number of expired
> messages }
> [java] messageWaitTime{ count: 0 maxTime: 0 minTime: 0
> totalTime: 0 averageTime: 0.0 averageTimeExMinMax: 0.0 averagePerSecond: 0.0
> averagePerSecondExMinMax: 0.0 unit: millis startTime: 1169620094918
> lastSampleTime: 1169620094918 description: Time spent by a message before
> being delivered }
> [java] }
> [java] }
> [java] consumers {
> [java] }
> [java] }
> [java] }
> {code}
> As you can see very bad performace, ot took about 40s to send this 1000
> transacted queue messages :-(
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.