Thursday, 5 November 2015

How to Disable OSB Services in 12c (12.2.1.0.0)

Recently I got to work on OSB Suite 12c(12.2.1.0.0) and there was a scenario where I need to disable File Polling mechanism through OSB Console.

As in OSB Suite 11g this feature was provided under Operational settings Tab and uncheck the tick mark to Disable the State.

Whereas in 12c this feature is moved to EM console.

Here are the steps to disable OSB services:

1) Logon to EM console

2) Click on Target Navigation present at top left corner as shown below




3) Expand SOA and there you can see your OSB Projects under subheading as service-bus.





   4) Click on your OSB Project will take you to the Home Page, in that click on Operations tab as
       shown below:



         
        

        On Above page check/uncheck you service State to enable/disable. (as highlighted above)



Tuesday, 6 January 2015

Setting Outbound Directory Dynamically in File Adapters - Oracle SOA Suite 11g


We often have a requirement of passing physical directory at run time so that it requires minimum code change in future.

I am listing down steps to do so in Oracle SOA Suite 11g.

In order to start with try to make a composite in order to write a file.

Once you complete your composite it will look something like this.





In this composite I  have configured File Adapter with write operation having physical path as /media/sf_SharedFolder/tempWriteFile

It's screenshot is as follows:



So when you try to open its JCA file as in my case its WriteFile_file.jca then it will look something like this.



The highlighted part in JCA file shows up Physical directory that we have mentioned while configuring write file adapter.

This is nothing but the target directory location where output file will be written, which we need to override by passing dynamic directory.

This is possible simply by setting up a Property as jca.file.Directory.



In order to do so go to your BPEL process and create a variable which is FileOutputDir of type Sting.

Assign value to this variable in assign activity which is /media/sf_SharedFolder/tempWriteFile/location  in my case.



Now we have to set this variable in jca.file.Directory property of invoke operation. 

So double click on invoke activity which open Edit Invoke activity go to its Properties tab and set jca.file.Directory property value as FileOutputDir and its Type should be input.

Apply changes and click on ok.



Save your composite and deploy it to your target server and test it.

Instead of writing file at  /media/sf_SharedFolder/tempWriteFile  your file will be written at /media/sf_SharedFolder/tempWriteFile/location 

jca.file.Directory property overwrites the default Physical Path to said Path.