Tuesday, September 2, 2014

Lots of new features are introduced in Oracle SOA 12c, one of it is Service Bus integration with Jdeveloper. Earlier in 11g version we used to develop service bus project in eclipse i.e. eclipse was used as IDE tool for service bus but in 12c we need not to use eclipse anymore; all service bus development is done in Jdeveloper 12c itself. Service bus project has SCA architecture i.e. service bus composite.xml file where we can drag and drop business service, pipeline and proxy service. Click here to see how to create service bus project from Jdeveloper 12c. Since we use Jdeveloper 12c for service bus integration that allow service bus to use MDS files, this feature was not there before. Click here to see how to use MDS in OSB.

In SOA 12c, Service Bus console is also redesigned, earlier in 11g version we used to do development and monitoring work in one console only but in 12c we do service bus monitoring in em console and service bus development from service bus console that means all kinds of alerts (SLA etc) are there in em console but if you need to test proxy, business or pipeline then you need go to service bus console. In this post, we will see how to use service bus console to create a sample service bus project.

To create a service bus, first open the service bus console (http://localhost:port/sbconsole), service bus console is same as we had in 11g version, but 12c service bus console interface is totally changed. You can see all the projects which are already deployed to service bus in left pane.

Let’s start with the sample, to create the service bus project we first need to create a session, we will not be able to start with the development unless we start a new session or edit an existing session. Click on create to create a new session as highlighted in below screen shot. This activates the create button from where we create a new service bus project. Click on create project button and provide the project name.

Create Service Bus Project

Service Bus Project

Once you have service project created, you can start adding required stuff to it. Add required folder structure as per your naming standards if you need to add. To add a new folder, right-click on the project, click on Create and choose Folder option. Repeat this step to add other folders.

Import Service Bus Resources

In this sample, we invoke SOA composite from business service so we need to import SOA composite artifacts in the service bus project if we need to invoke that service. There are different options to add SOA composite resources to service bus project, we choose URL option  that means we provide the SOA composite wsdl path and this automatically import all the artifacts to service bus folder. To import the resources, right-click on resource folder, click on “Import” and choose “From URL” option. Provide SOA composite WSDL file URL and provide resource name, this imports all the artifacts under resource folder.

Import Resources

Create Business service

Once we are done with resource import, we create a business service which invokes SOA composite. We use above imported WSDL file to create the business service. To create the business service, right-click on the folder, click on Create and choose “Business Service” option. Provide business service name and choose the above imported wsdl file to create it.

Create Business service

Provide business service name and choose the above imported wsdl file to create it.

Service Bus Business service

Accept the default transport.

Service Bus Transport

Once we are done with business service, we create pipeline and expose that as a proxy service. Expose pipeline as proxy service feature was not there earlier, it is introduced in 12c only. Now let’s create a new pipeline, to create it right-click on the folder, click on Create and choose “Pipeline” option. You can also create pipeline and proxy services separately but for this post, we create pipeline and expose it as proxy service.

Create New Pipeline

We need to specify WSDL file to create pipeline, we use above imported WSDL file which is there under resources folder. Provide the pipeline name and description, browse the SOA composite WSDL file and click on “Expose as proxy service” checkbox, this option expose pipeline as proxy service. Once done click on create, this will create pipeline and proxy service.

Create proxy Service

SOA12c Service Bus Project

Now you can test the proxy service and see the response. You can also test pipeline and business service, earlier there were no provision to test pipeline alone but in 12c we can test pipeline alone also.


  1. Error 401--Unauthorized

    From RFC 2068 Hypertext Transfer Protocol -- HTTP/1.1:

    10.4.2 401 Unauthorized

    The request requires user authentication. The response MUST include a WWW-Authenticate header field (section 14.46) containing a challenge applicable to the requested resource. The client MAY repeat the request with a suitable Authorization header field (section 14.8). If the request already included Authorization credentials, then the 401 response indicates that authorization has been refused for those credentials. If the 401 response contains the same challenge as the prior response, and the user agent has already attempted authentication at least once, then the user SHOULD be presented the entity that was given in the response, since that entity MAY include relevant diagnostic information. HTTP access authentication is explained in section 11.

    getting above error while logging into localhost;7001/servicebus

    1. If you are using integrated server then you are using wrong port.

    2. I am using a standalone server

  2. This comment has been removed by the author.

  3. Why Oracle still wants to use sbconsole to do development when we can do it in JDEV, even they are investing time to modify the look and feel of sbconsole.

  4. Hi Vivek,
    I followed the above steps and when i try to activate my changes am finding the below error.

    [Deployer:149150]An IOException occurred while reading the input. : with response code '-1' : with response message 'null'

    Please help me sort the above issue.