Wednesday, December 14, 2016

OSB - Using DVM in 12c using qualifiers

To use a DVM in OSB 12c which requires qualifiers, specify the function as such:

dvm:lookupValue(dvm-location, src-column, src-value, target-column, default-value, qualifiers[])


dvm:lookupValue('DVMQualifiers/Proxy/dvm-cities', 'CityCode', 'KN', 'CityName', 'NA', ('Country','USA'))

Monday, August 8, 2016

SOA - Unable to edit file/jms/db adapter; shows red cross mark

Problem:
Migrated composites to the 12c version are unable to be edited, even with the <?binding.jca dbAdapter_db.jca> fix. The adapter is also showing a red cross mark.

Solution:
The solution is provided in this Oracle community post:

Open .jca file for JMS adapter  and change from  adapter="JMS Adapter" to adapter="jms" . If you use database adapter as well , then change from adapter="Database Adapter" to adapter="db". (  ... adapter="File Adapter" to adapter="file")

The adapter is now able to be edited normally.

Wednesday, July 27, 2016

FYI - JMS Polling and Error Queues

FYI:

When polling a JMS queue in OSB, in order for it to go to the configured error queue, an error must be raised. Raising an error and then handling this error won't cause the message to be sent to the error queue. If the error is handled, then a fault must be raised again.

Take this simple proxy service as an example that polls from a JMS queue configured in weblogic and calls a stored procedure to insert the polled record:



EmployeePS Pipeline:



Should an unexpected error occur somewhere in this pipeline, it will be caught by the error handler. The error will be reported in the EM Message Reports but the error is raised again so that it can be sent to the error queue.

Doing a Reply with Failure will NOT send the message to the error queue. As explained by AbhishekJ here:

In case of JMS transport the JMS Queue or Topic will receive a NACK back but the message will NOT roll back and will be removed from the destination just like in case of Reply with Success. This happens because using a Reply action is considered as an exception being handled properly and a commit will be sent back to the JMS destination. To roll back the message ensure that you use Raise Error instead of a Reply action.

Monday, July 25, 2016

Resources: Helpful Weblogic JMS Links

Creating a JMS Server and Queue in Weblogic:
https://blogs.oracle.com/soaproactive/entry/how_to_create_a_simple

Creating a JMS Error Queue:
http://middlewaremagic.com/weblogic/?p=4670