Hi again guys,
I'm developing a service on OSB 12c that is supposed to read messages from one JMS queue and then write them to another queue. It should have two operations: moveMessage that takes the ID of the message to be moved, and moveAll, which is self-explanatory.
I'm having a hard time on figuring how to do that. Writing to the destination queue is easy, but how can I read from the source queue? I've tried creating a JMS adapter with sync_consume_message operation type. Jdev then created a business service that points to the queue, but when I tried to call the service (operation sync_consume_message) it returns nothing. Any insight on what could be wrong? I'm not very familiar with the semantics of sync_consume_message operation, but it's my understanding that it should return all the messages on the queue (I checked and there are a few there). Also, any idea on how I could implement the second operation, removeMessage(ID)?
One last thing that I maybe should mention is that I didn't define any schema for the messages when creating the adapter, just opaque (because I'm not going to process the messages, just move it from one queue to the other). However, the business service created expects a payload of
<opaq:empty xmlns:opaq="http://xmlns.oracle.com/pcbpel/adapter/opaque/"/>
I'm not editing this in any way before calling the service.
Thanks in advance!
Pedro