Thursday, 21 November 2013

Oracle SOA Suite 11g Translation Error - Error while translating. Translation exception. Error occurred while translating content from file.

Recently we have faced a translation error in PRODUCTION as below.

"" Error while translating. Translation exception. Error occured while translating content from file /home/ftp/prod/in/invoices/Sample.xml Please make sure that the file content conforms to the schema. Make necessary changes to the file content or the schema. ""

All files are getting processed except this file. I have checked in all the ways , everything looks pretty well .
 I have tried multiple times pushing the same file in FTP location but the same error is repeating.

I have struggled 5 hours to find the Issue root cause - Finally I got it as the file Encoding Style is in UTF-8 not the ANSI as UTF-8.

The translation errors will come with the Encoding style fault.

Usually Oracle SOA Adapters supports only ANSI as UTF-8 formats .If the file coming with UTF-8 format it will not be processed by Composite as it can not translate to the native schema in the adapter .
While configuring the Adapters in Oracle SOA Suite by default it will take the ANSI format. So the incoming file format should be in ANSI as UTF-8 format .

To check the above case open the error file with Notepad++ and observed the below issue.

And the I opened the success file with Notepad++ i could see the difference in Encoding style  as shown below.

So Guys please be careful about the Encoding style in the files .It will make you MAD in some cases.

Happy Learning - Fun Sharing.

Tuesday, 12 November 2013

Exposing BPEL Service as HTTP service In Oracle SOA 11g

Hi Folks .

Now I am going to explain about BPEL service expose as a HTTP service.

Actually the BPEL service would invoke from SOAP service .It can not accept REST request or HTTP request because it does not contains the SOAP headers etc. So we will go in another approach to expose the BPEL service as a HTTP service to accept the request from HTTP client.

Below are the steps to expose the BPEL service as HTTP service:-

1.Create an empty BPEL process
2.Create the desired schema.

2.Drag n drop a HTTP Binding Adapter into Exposed services.

3.Give service name.

 4.Give interface as "Define from operation and schema(specified later)"

5. Select the options as shown below.

6.Browse the Request Message schema  and Reply Message schema from the Type chooser

7.Once you completed the configuration of HTTP binding you can see the below screen.

8.Drag n drop a BPEL component to Components and select the options like below screen.
   Do not expose as a SOAP service

9.The Composite looks like the below.

10.Drag n drop a Webservice in External References -Give the Concrete WSDL on which BPEL process           you are going to expose as a HTTP service.

11.Finally the composite design is completed.Looks like the below screenshot.

12.Open the BPEL-Add a Invoke activity in between Receive and Reply.

13.Edit Invoke as below.

14.Wire it to Reference web service.

15.Add transformations to Transform the Request and Response message from SOAP  to HTTP vice-versa.

 16.Edit the transformation like below.

 17.Map the corresponding elements to the desired format.

18.Yooo--- The BPEL design is completed successfully.
 19.Finally Deploy it to WebLogic server .Test it from UI or Adavnced REST Client - Its a Google chrome         extension which  allow you to test the Webservice.

Done... Happy learning.-----

Thursday, 7 November 2013

How to start BAM server in Weblogic 11 g

Hi Folks,

Today we will learn how to start BAM server in Weblogic 11g.

When you login into http://localhost:port/em you can see the following screen.

After you start the Admin server from $Oracle_Home/user_projects/domains/soadomain/startWebLogic.cmd (or) -based on your OS running on your machine.

The above screenshot shows you that the BAM server is down .
You can start the BAM server in 2 ways.

Way 1:- If your node manager is up n running then you can start BAM server like below screenshot.

If your node manager is not up n running then you can go for way 2 .

Way 2:-
1.Open CMD.
2.go to C:\Oracle_Home\\user_projects\domains\soa_domain\bin\startManagedWebLogic bam_server1
(This location may vary as per you installation way-Check the location in your machine)
3.Enter Username to boot WebLogic server
4.Enter Password to boot WebLogic server
After this you BAM server starts up.

Instead of entering the username and password every time you can create under security folder.
The path would be

If the file or folder doesn't exist you need to create them manually.
The content of the file is here.

When you starts the server next time it will take the credentials from file then starts.

This procedure will be applicable to all Managed servers and all servers .

Happy Learning Folks.....