title: Spring-JMS(Websphere MQ)
body: <p>I have the below configurations in Spring , it is working fine but performance is too low (it takes 1 min for 20 messages). Can you please suggest me changes to increase the performance.</p>
  
  <pre><code>&lt;bean id="jmsConnectionFactory" class="com.ibm.mq.jms.MQQueueConnectionFactory"&gt; 
          &lt;property name="transportType"&gt;&lt;value&gt;1&lt;/value&gt;&lt;/property&gt; 
          &lt;property name="queueManager"&gt;&lt;value&gt;&lt;/value&gt;&lt;/property&gt; 
          &lt;property name="hostName"&gt;&lt;value&gt;&lt;/value&gt;&lt;/property&gt; 
          &lt;property name="port"&gt;&lt;value&gt;&lt;/value&gt;&lt;/property&gt; 
          &lt;property name="channel"&gt;&lt;value&gt;&lt;/value&gt;&lt;/property&gt; 
          &lt;property name="clientId"&gt;&lt;value&gt;&lt;/value&gt;&lt;/property&gt;        
      &lt;/bean&gt;
          &lt;bean id="SenderJMSTemplate" class="org.springframework.jms.core.JmsTemplate"&gt; 
          &lt;property name="connectionFactory"&gt;&lt;ref bean="jmsConnectionFactory" /&gt;  &lt;/property&gt; 
          &lt;property name="pubSubDomain"&gt;&lt;value&gt;false&lt;/value&gt;&lt;/property&gt; 
          &lt;property name="defaultDestination"&gt;&lt;ref bean="senderQueue" /&gt;&lt;/property&gt; 
      &lt;/bean&gt;  
  &lt;bean id="senderQueue" class="com.ibm.mq.jms.MQQueue"&gt; 
          &lt;constructor-arg value="TEST" /&gt; 
          &lt;property name="baseQueueManagerName"&gt;&lt;value&gt;tree.queue.manager&lt;/value&gt;&lt;/property&gt; 
          &lt;property name="baseQueueName"&gt;&lt;value&gt;ORANGE.QUEUE&lt;/value&gt;&lt;/property&gt;  
      &lt;/bean&gt; 
      &lt;bean id="jmsSender" class="org.tree.jms.spring.JMSSender"&gt; 
          &lt;property name="jmsTemplate"&gt;&lt;ref bean="SenderJMSTemplate"/&gt;&lt;/property&gt;     
      &lt;/bean&gt;
  </code></pre>
  
  <p>I am calling from spring as </p>
  
  <pre><code>JMSSender obj = (JMSSender) context.getBean("jmsSender");
  </code></pre>
  
  <p>And My Sender program is :</p>
  
  <pre><code>        @Cacheable("message")
  
       public void sendMesage() {
  
          jmsTemplate.send(new MessageCreator() {
          public Message createMessage(Session session)throws JMSException {
          message = (Message) session.createTextMessage(stringBuffer.toString());
          return message;
          }
          });
  
      }
  }
  </code></pre>