Thursday, December 31, 2009

HAPPY NEW YEAR

Keep learning and stay connected to Oracle SOA.
May each day brings happiness, prosperity and continued success...


WISHING ALL BLOG READERS...
A
VERY
HAPPY
AND
PROPSPEROUS
NEW
YEAR 2010.

Logging System.out statements

Problem:
Need to log System.out statements under Oracle Application Server 10g.

Thoughts:
For this requirement, I was searching on Internet and I got a solution which worked. Just thought of publishing this on this blog for readers.

This entry which give you an insight view about how to log system.out outputs on our SOA Servers. By default, this is not logged anywhere. For example, a Java code might include the following line:-
System.out.println("Test_123");

Solution:
You can configure this in two ways, either manually updating SOA Server files or via Enterprise Manager Console.

Configure System.out logging manually on SOA Server:
1) Stop the SOA Server
2) Navigate to <SOA_HOME>\opmn\conf
3) Open and edit opmn.xml file
4) Add the following entry to the start-parameters section of the container.
For example:
<data id="oc4j-options" value="-out d:\oracle\product\SOA\j2ee\<container_name>\log\Custom_log\systemout.log"/>
5) Restart SOA Server

Configure System.out logging via EM Console:
1) Log in to the EM Console
2) Click on proper container name
3) Click on Administration tab
4) Click on Server Properties link
5) Add the following under Start-parameters:- OC4J Options;
For example:
-out d:\oracle\product\SOA\j2ee\<container_name>\log\Custom_log\systemout.log
6. Restart the SOA Server

The output should now appear in the log file you configured:
<SOA_HOME>\j2ee\<container_name>\log\Custom_log\systemout.log

Wednesday, December 30, 2009

ORABPEL-05250

Problem:
BUILD FAILED
D:\Abhi\RatingCheck\build.xml:79: A problem occured while connecting to server "localhost" using port "80": bpel_RatingCheck_v2009_12_12__74238.jar failed to deploy. Exception message is: Error deploying BPEL suitcase.
An error occurred while attempting to deploy the BPEL suitcase file "D:\oracle\product\soa\bpel\domains\default\tmp\bpel_12757142.tmp"; the exception reported is: archive cannot rename D:\oracle\product\soa\bpel\domains\default\tmp\.bpel_RatingCheck_v2009_12_12__74238_a4ef0434bf12f22a3374aab6a0a942a1

If you check the server log file - domain.log, you will see ORABPEL-05250 error.

Thoughts:
This error is encountered with SOA 10.1.3.5. You will see this error once you try to redeploy your project on the server i.e. whenever a BPEL process is already deployed on the server and you are trying to replace it with newer version or trying to deploy over it. Even in Jdeveloper you will not see the small version window poping up when you try to deploy the project.

But why this problem is there?
Possibly there is a bug with this SOA version. I think whenever we try to redeploy the project it tries to rename the existing project before replacing it with the new one. Some unknown Java process within the BPEL server locks the bpelclasses.jar file and one of your project WSDLs preventing the renaming of the parent directory.

Solution:
Possible solution (as we are doing for our projects)for this error is:
1) Undeploy the process from the console
2) Shutdown SOA Suite Server
3) Bring the Server up. (This will release the process lock).
4) Try to deploy the project.

I know this is quite painful during development. One more pain is that you cannot have multiple versions of your project on console. That means if you want to refer any instance after redeploying, forget it.

So according to me, avoid applying Patch Set 10.1.3.5 on Windows (I have not tried this on other OS). I hope Oracle will look into this matter soon.

Wednesday, December 23, 2009

ORABPEL-04077

Problem:
ORABPEL-04077
Cannot fetch a datasource connection.
The process domain was unable to establish a connection with the datasource with the connection URL "jdbc/BPELServerDataSource". The exception reported is: javax.resource.ResourceException: RollbackException: Transaction has been marked for rollback: Timed out

Thoughts:
Sometimes deploying a bpel project of bigger size using JDeveloper throws exception: javax.resource.ResourceException: RollbackException: Transaction has been marked for rollback: Timed out. This is due to the fact that JDeveloper takes too much time and fails to deploy the project.

Solution:
To solve the issue we need to change values of some configuration files of SOA Server. Follow the below mentioned steps:

1) Stop the SOA Server

2) Open the transaction-manager.xml file present under location:-
<SOA_HOME>\j2ee\oc4j_soa\config\transaction-manager.xml

3) Change the transaction-timeout attribute value to some higher value, viz. transaction-timeout="7200"

4) Now open the orion-ejb-jar.xml file present under location:-
<SOA_HOME>\j2ee\oc4j_soa\application-deployments\orabpel\ejb_ob_engine\orion-ejb-jar.xml

5) Change the transaction-timeout attribute to some higher value, viz. transaction-timeout="3600"

6)There will be 6 entries of transaction-timeout attributes in the file. You have to change all the 6 attributes.

7) Save the files.

8) Restart the SOA Server.

9) Now try to deploy the BPEL project using JDeveloper. It should work.

Tuesday, December 22, 2009

Application Server HTTP 404 problem - Part 2

Follow this post if the solution published on my blog dated 16th April 2009 is not working.

If making changes to default-web-site.xml file does not work, then try to change an entry in the server.xml file. The file is located under:
<SOA_HOME>\j2ee\home\config\server.xml

Note: Stop the server before making any changes to the server files.

In the file, change the below property to true:
application name="ascontrol" path="../../home/applications/ascontrol.ear" parent="system" start="true" /

Now start the SOA Server and try launching the enterprise manager. You should be able to see the AS control page now.