XQuery notes

Check if Integer

Whitespaces, Tabs and Return trim or replace

DateTime to Date

Date to DateTime

Formatted string to Date

Faults
1. code and string from OSB

2. Standart Soap Fault

OSB 11g Send GET request with dynamic parameters

So we need to send GET request like this http://10.0.0.2/app/v1/serice_action?service_id=1&msisdn=7916777777 so that URI will dynamically formed.

First we need to create business service with Service Type Messaging service, request mesage type text, and in my case I got XML in response. Also the main thing here is to set Endpoint URI in Transport inset to http://10.0.0.2.

osb1osb2osb3

That’s all we need for business service.

Next, for proxy service we do Routing node with Routing to our business service.

I have a flow like on picture below.

To send dynamic GET request is to put some Insert nodes on request action lane and send it to outbound.

osb4

Location and XPath is always as last child of and ./ctx:transport/ctx:request and of cause In variable outbound.

and Expressions:

  1. <http:relative-URI>{concat( ‘/app/v1/’, $request_type) }</http:relative-URI>
    $request_type is the variable that point to right service_action
  2. <http:query-string>{concat(‘service_id=1’, ‘&amp;’,
    ‘&msisdn=7916777777’)}</http:query-string>
  3. <http:http-method>GET</http:http-method>

UPD 18.03.2016.

If you change request mesage type to none

and set request method to GET from HTTP Transport tab

you can remove last insert node

Eclipse The WSDL for the typed transport endpoint could not be accessed java.lang.NoClassDefFoundError: com/sun/javadoc/Type

In Oracle Enterprise Pack for Eclipse (OEPE) Indigo 3.7 with Oracle Service Bus 11gR1 I had a problem “The WSDL for the typed transport endpoint could not be accessed java.lang.NoClassDefFoundError: com/sun/javadoc/Type”

Screenshot_2

Global java version was set to 8
Screenshot_3

Screenshot_4

To fix this you need to add path to bin folder of a 6th java version C:\Java\jdk6\bin; in the beginning of Path in System Properties, then restart Eclipse.

Screenshot_5