You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@tomee.apache.org by bu...@apache.org on 2012/12/11 08:34:28 UTC

svn commit: r841641 - in /websites/staging/openejb/trunk: cgi-bin/ content/ content/tomee-and-webspheremq.html

Author: buildbot
Date: Tue Dec 11 07:34:27 2012
New Revision: 841641

Log:
Staging update by buildbot for openejb

Modified:
    websites/staging/openejb/trunk/cgi-bin/   (props changed)
    websites/staging/openejb/trunk/content/   (props changed)
    websites/staging/openejb/trunk/content/tomee-and-webspheremq.html

Propchange: websites/staging/openejb/trunk/cgi-bin/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Tue Dec 11 07:34:27 2012
@@ -1 +1 @@
-1420016
+1420020

Propchange: websites/staging/openejb/trunk/content/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Tue Dec 11 07:34:27 2012
@@ -1 +1 @@
-1420016
+1420020

Modified: websites/staging/openejb/trunk/content/tomee-and-webspheremq.html
==============================================================================
--- websites/staging/openejb/trunk/content/tomee-and-webspheremq.html (original)
+++ websites/staging/openejb/trunk/content/tomee-and-webspheremq.html Tue Dec 11 07:34:27 2012
@@ -147,120 +147,122 @@
 </h1>
 </div>
 
-<p><strong>Steps to integrate TomEE with Websphere MQ</strong> <br></p>
+<p><strong>Steps to integrate TomEE with Websphere MQ</strong> </p>
 
 <ol>
 <li>Unzip rar file place jars under tomee/lib</li>
 <li>Added the below to conf/tomee.xml</li>
 </ol>
 
-<p>&lt; tomee> </br>
-  &lt; Container id="wmq" type="MESSAGE"><br>
+<pre>
+    &lt;tomee&gt;     
+    &lt;Container id=&quot;wmq&quot; type=&quot;MESSAGE&quot;&gt;
     ResourceAdapter=wmqRA
     MessageListenerInterface=javax.jms.MessageListener
     ActivationSpecClass=com.ibm.mq.connector.inbound.ActivationSpecImpl
-</br>
-  &lt; /Container></p>
+    &lt;/Container&gt;
 
-<p>&lt; Resource id="wmqRA" type="com.ibm.mq.connector.ResourceAdapterImpl" <br>class-name="com.ibm.mq.connector.ResourceAdapterImpl">
-    <br>connectionConcurrency=5  </br>
-    maxConnections=10 </br>
-    logWriterEnabled=true </br>
-    reconnectionRetryCount=5 </br>
-    reconnectionRetryInterval=300000 </br>
-    traceEnabled=false </br>
-    traceLevel=3 </br>
-  &lt; /Resource></p>
-
-<p>&lt; Resource <strong>id="qcf"</strong> </br> type="javax.jms.ConnectionFactory" class-name="com.ibm.mq.connector.outbound.ManagedConnectionFactoryImpl">
-    TransactionSupport=none </br>
-    ResourceAdapter=wmqRA </br>
-    HostName=10.a.b.c </br> <br />
-    Port=1414 </br>
-    QueueManager=QM_TIERL</br>
-   Channel=SYSTEM.ADMIN.SVRCONN</br>
-   TransportType=Client</br>
-   UserName=xyz</br>
-   Password=<strong>*</strong></br>
-  </Resource></p>
-
-<p>&lt; Resource id="wmq-javax.jms.QueueConnectionFactory" </br> type="javax.jms.QueueConnectionFactory" class-name="com.ibm.mq.connector.outbound.ManagedQueueConnectionFactoryImpl">
-    TransactionSupport=xa </br>
-    ResourceAdapter=wmqRA </br>
-  &lt; /Resource></p>
-
-<p>&lt; Resource id="wmq-javax.jms.TopicConnectionFactory" </br> type="javax.jms.TopicConnectionFactory" class-name="com.ibm.mq.connector.outbound.ManagedTopicConnectionFactoryImpl">
-    TransactionSupport=xa </br>
-    ResourceAdapter=wmqRA </br>
-  &lt; /Resource></p>
-
-<p>&lt; Resource <strong>id="queue"</strong> type="javax.jms.Queue" </br> 
-class-name="com.ibm.mq.connector.outbound.MQQueueProxy"> </br>
-    arbitraryProperties </br>
-    baseQueueManagerName </br>
-    baseQueueName </br>
-    CCSID=1208 </br>
-    encoding=NATIVE </br>
-    expiry=APP </br>
-    failIfQuiesce=true </br>
-    persistence=APP </br>
-    priority=APP </br>
-    readAheadClosePolicy=ALL </br>
-    targetClient=JMS </br>
-  </Resource></p>
-
-<p>&lt; Resource id="wmq-javax.jms.Topic" type="javax.jms.Topic" class-name="com.ibm.mq.connector.outbound.MQTopicProxy">
-    arbitraryProperties </br>
-    baseTopicName </br>
-    brokerCCDurSubQueue=SYSTEM.JMS.D.CC.SUBSCRIBER.QUEUE </br>
-    brokerDurSubQueue=SYSTEM.JMS.D.SUBSCRIBER.QUEUE </br>
-    brokerPubQueue </br>
-    brokerPubQueueManager </br>
-    brokerVersion=1 </br>
-    CCSID=1208 </br>
-    encoding=NATIVE </br>
-    expiry=APP </br>
-    failIfQuiesce=true </br>
-    persistence=APP </br>
-    priority=APP </br>
-    readAheadClosePolicy=ALL </br>
-    targetClient=JMS </br>
-  </Resource> </br></p>
 
-<p>&lt; /tomee>    </p>
-
-<ol>
-<li>in web.xml add the below to access resources</br>
-&lt; resource-ref> </br>
- &lt; res-ref-name>myqcf&lt; /res-ref-name> </br>
-&lt; res-type>javax.jms.ConnectionFactory &lt; /res-type></br>
-&lt; res-auth>Container</res-auth>&lt; /br>
-&lt; res-sharing-scope>Shareable&lt; /res-sharing-scope></br>
-&lt; mapped-name>qcf&lt; /mapped-name></br>
-&lt; /resource-ref></p>
-
-<p>&lt; resource-env-ref></br>
-&lt; resource-env-ref-name>myqueue&lt; /resource-env-ref-name></br>
-&lt; resource-env-ref-type>javax.jms.Queue&lt; /resource-env-ref-type></br>
-&lt; mapped-name>queue&lt; /mapped-name></br>
-&lt; /resource-env-ref></br></li>
-</ol>
-
-<p><strong>Java Code: </br></strong></p>
-
-<p>@Resource(name = "qcf") </br>
-private ConnectionFactory connectionFactory; </br>
-@Resource(name = "queue") </br>
-private Queue queue;</br></br>
-Connection connection = connectionFactory.createConnection();</br>
-Session session = connection.createSession(false, QueueSession.AUTO_ACKNOWLEDGE);
-MessageProducer producer = session.createProducer(queue);</br>
-TextMessage message = session.createTextMessage();</br>
-message.setText("Test Message");</br>
-connection.start();</br>
-producer.send(message);</br>
-session.close();</br>
-connection.close();</br></p>
+   &lt;Resource id=&quot;wmqRA&quot; type=&quot;com.ibm.mq.connector.ResourceAdapterImpl&quot; class-name=&quot;com.ibm.mq.connector.ResourceAdapterImpl&quot;&gt;
+    connectionConcurrency=5  
+    maxConnections=10 
+    logWriterEnabled=true 
+    reconnectionRetryCount=5 
+    reconnectionRetryInterval=300000 
+    traceEnabled=false 
+    traceLevel=3 
+   &lt;/Resource&gt;
+
+   &lt;Resource **id=&quot;qcf&quot;**  type=&quot;javax.jms.ConnectionFactory&quot; class-name=&quot;com.ibm.mq.connector.outbound.ManagedConnectionFactoryImpl&quot;&gt;
+    TransactionSupport=none 
+    ResourceAdapter=wmqRA 
+    HostName=10.a.b.c   
+    Port=1414 
+    QueueManager=QM_TIERL
+   Channel=SYSTEM.ADMIN.SVRCONN
+   TransportType=Client
+   UserName=xyz
+   Password=*****
+  &lt;/Resource&gt;
+
+  &lt;Resource id=&quot;wmq-javax.jms.QueueConnectionFactory&quot;  type=&quot;javax.jms.QueueConnectionFactory&quot; class-name=&quot;com.ibm.mq.connector.outbound.ManagedQueueConnectionFactoryImpl&quot;&gt;
+    TransactionSupport=xa 
+    ResourceAdapter=wmqRA 
+  &lt;/Resource&gt;
+
+  &lt;Resource id=&quot;wmq-javax.jms.TopicConnectionFactory&quot;  type=&quot;javax.jms.TopicConnectionFactory&quot; class-name=&quot;com.ibm.mq.connector.outbound.ManagedTopicConnectionFactoryImpl&quot;&gt;
+    TransactionSupport=xa 
+    ResourceAdapter=wmqRA 
+  &lt;/Resource&gt;
+
+  &lt;Resource **id=&quot;queue&quot;** type=&quot;javax.jms.Queue&quot;  
+class-name=&quot;com.ibm.mq.connector.outbound.MQQueueProxy&quot;&gt; 
+    arbitraryProperties 
+    baseQueueManagerName 
+    baseQueueName 
+    CCSID=1208 
+    encoding=NATIVE 
+    expiry=APP 
+    failIfQuiesce=true 
+    persistence=APP 
+    priority=APP 
+    readAheadClosePolicy=ALL 
+    targetClient=JMS 
+  &lt;/Resource&gt;
+
+  &lt;Resource id=&quot;wmq-javax.jms.Topic&quot; type=&quot;javax.jms.Topic&quot; class-name=&quot;com.ibm.mq.connector.outbound.MQTopicProxy&quot;&gt;
+    arbitraryProperties 
+    baseTopicName 
+    brokerCCDurSubQueue=SYSTEM.JMS.D.CC.SUBSCRIBER.QUEUE 
+    brokerDurSubQueue=SYSTEM.JMS.D.SUBSCRIBER.QUEUE 
+    brokerPubQueue 
+    brokerPubQueueManager 
+    brokerVersion=1 
+    CCSID=1208 
+    encoding=NATIVE 
+    expiry=APP 
+    failIfQuiesce=true 
+    persistence=APP 
+    priority=APP 
+    readAheadClosePolicy=ALL 
+    targetClient=JMS 
+  &lt;/Resource&gt; 
+
+ &lt;/tomee&gt;  
+
+3. In web.xml add the below to access resources
+ &lt;resource-ref&gt; 
+     &lt;res-ref-name&gt;myqcf&lt; /res-ref-name&gt; 
+    &lt;res-type&gt;javax.jms.ConnectionFactory &lt; /res-type&gt;
+    &lt;res-auth&gt;Container&lt;/res-auth&gt;&lt; /br&gt;
+    &lt;res-sharing-scope&gt;Shareable&lt; /res-sharing-scope&gt;
+    &lt;mapped-name&gt;qcf&lt; /mapped-name&gt;
+  &lt;/resource-ref&gt;
+
+ &lt;resource-env-ref&gt;
+   &lt;resource-env-ref-name&gt;myqueue&lt; /resource-env-ref-name&gt;
+   &lt;resource-env-ref-type&gt;javax.jms.Queue&lt; /resource-env-ref-type&gt;
+   &lt;mapped-name&gt;queue&lt; /mapped-name&gt;
+  &lt;/resource-env-ref&gt;
+</pre>
+
+<p><strong>Code:</strong></p>
+
+<pre>    
+    @Resource(name = &quot;qcf&quot;) 
+    private ConnectionFactory connectionFactory; 
+    @Resource(name = &quot;queue&quot;) 
+    private Queue queue;
+    Connection connection = connectionFactory.createConnection();
+    Session session = connection.createSession(false, QueueSession.AUTO_ACKNOWLEDGE);
+    MessageProducer producer = session.createProducer(queue);
+    TextMessage message = session.createTextMessage();
+    message.setText(&quot;Test Message&quot;);
+    connection.start();
+    producer.send(message);
+    session.close();
+    connection.close();
+</pre>