Java Integration
Transform Anything with Java
Consume Message from JMS Queue using OSB
1. Login to SB Console and create a session.
2. Create a New Project named ConsumeJMS. Also create a folder named ProxyServices within the ConsumeJMS project.
3. Create a Resource > Proxy Service. The Proxy Wizard will appear.
4. In General Configuraion, choose Service Type as Messaging Service.
5. Name the service ReadFromJMSQueue.

6. In Transport Configuration, choose jms as protocol.
7. Set the Endpoint URI as jms://localhost:7001/weblogic.jms.XAConnectionFactory/jms.SourceQueue. I have already created a queue named SourceQueue.

8. In JMS Transport Configuration, select Destination Type as Queue. Goto the last step and save.
9. Open the Message flow of the Proxy Service.
10. Add a Request/Response Pipeline.
11. Add a stage to Request Pipeline. Edit the stage
12. Add an Action > Reporting > Log


13. Update the expression as $body and update the Annotation too.
14. Activate the session.
15. Goto Weblogic Console and place a message in the queue. The Message should get printed in the log.


******************* START DUMP GlobalOperationsPOJO **********************
<xml-fragment xmlns:con="http://www.bea.com/wli/domain/config"><con:monitoring>true</con:monitoring><con:reporting>true</con:reporting><con:logging>true</con:logging><con:sla-alerting>true</con:sla-alerting><con:pipeline-alerting>true</con:pipeline-alerting><con:result-caching>true</con:result-caching></xml-fragment>
******************** END DUMP GlobalOperationsPOJO **********************
<Sep 23, 2014 2:37:43 PM PDT> <Warning> <ALSB Logging> <BEA-000000> < [PipelinePairNode1, PipelinePairNode1_request, stage1, REQUEST] content of $body from Reuquest: <soapenv:Body xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">This is a message from Javatweaks.com</soapenv:Body>>