title: ActiveMQ Running on AWS - EC2 instance, Producer Performance Improvement
body: <p>I am currently working on an assignment which requires me to benchmark response times between apache activemq and aws-sqs.</p>
  
  <p>In my finding I found that, activemq 
  producer takes 35 sec / 1000 messages [120 bytes each]
  consumer takes 250 ms / 1000 messages [120 bytes each]</p>
  
  <p>I am using Maven + Git + Java based project structure. I am creating a session from connectionfactory in a following way:</p>
  
  <pre><code>cFactory.createSession(false, Session.AUTO_ACKNOWLEDGE);
  </code></pre>
  
  <p>Connection is synchronous, message reliability is important. Can someone tell me the logic or reason behind this behavior? </p>
  
  <p>I suspect that producer takes time because it has to not only send but also wait for the acknowledgement from amq service running on ec2 about the fact that it has journaled the message.</p>
  
  <p>Please let me know why the producer is slow and how can I improve upon it.</p>