Monday, November 05, 2012

How to change the date format and get previous date in OSB

fn-bea:date-to-string-with-format("dd-MM-yyyy",fn:current-date())

fn:concat(fn:day-from-dateTime(fn:current-dateTime() - xdt:dayTimeDuration("PT24H")),'-',fn:month-from-dateTime(fn:current-dateTime()),'-',fn:year-from-dateTime(fn:current-dateTime()))

This decreases 24 hour from the existing date

xdt:dayTimeDuration("PT24H")

Friday, November 02, 2012

How to pass header from OSB to SOA


In order to pass header from OSB to SOA

We have to pass the header element using Trasport header in OSB.

Use transport header in communication and pass the inbuilt header field.

Now in SOA go to the invoke activity which is trying to receive the data from these header.

Go to properties and for the same header fields assign some varilabe and get those valuess.

In order to pass these header from one process to another use the follwing code

<property name="passThroughHeader">true</property>

 to pass the header variables to different components.

 Make sure to pass the value in next invoke too.


<component name="MessageReprocessor"></component>
<implementation .mediator=".mediator" src="MessageReprocessor.mplan"></implementation>
<property name="passThroughHeader">true</property>