Tuesday, June 3, 2014

In Oracle SOA Suite we use “Move” operation to move large files from one location to another. But in Oracle Service Bus we don’t have that option available. In this post, I will show you how to move large files using Content Streaming option available in file protocol.

There are some Best Practices to use Content Streaming Option which are mentioned in below Oracle link.

http://docs.oracle.com/cd/E13159_01/osb/docs10gr3/userguide/context.html#wp1110513

First create a Business  service which will write the file to required location. Name your business service, choose “Messaging Service” as service Type.

Choose “Binary” as Request Message Type and “None” as Response Message Type.




Choose “file” from protocol drop down and specify Endpoint URI. Also specify the file name.



Now create a proxy service which will read the file and pass it to business service.

Name your proxy service and choose “Business Service” as Service Type. Browse earlier created business service and choose “Binary” as Request Message Type and “None” as Response Message Type.

Specify the Endpoint URI, where we need to read the file.

Specify file name, polling interval, read limit, stage & error directory.



To enable content streaming, check “Enabled” check box for content streaming.

Choose “Disk Buffer” as Buffer Type and enable compression.




Sample code can be downloaded from here.



2 comments :

  1. Hi.. Good post.. in SOA where do we have "move " operation?Thanks

    ReplyDelete
    Replies
    1. To move large file from one location to another in SOA using file/ftp adapter, refer my below post

      http://soawork.blogspot.com/2012/12/move-file-using-file-adapter.html

      Vivek

      Delete