Thursday, June 04, 2009

BPEL Process for HA


Purpose

In a HA Deployments, when a bpel process is executed you cannot identify which server is currently executing of a given instance. It's often a requirement to test a BPEL Process in HA Environment and prove that which server is actually executing. As you may be aware when you execute a BPEL Process you cannot tell which node has executed that at any given time.

The following example helps you identifying which server is executing so that you can do some HA testing.


Step 1

Create a Simple Synchronous BPEL Process and name it as "HAHelloWorld"


Step 2

Drag and Drop "Java Embedding" Activity between "receive" and "reply".


Step 3

Drag and Drop "Assign" Activity and Initialize the Variable "result" with some text (Note: anything it doesn't matter all you are doing here is initializing the result variable)


Step 4

Double click on "Java Embedding"Activity and copy the following details


/*Set Title*/
String prop = System.getProperty("server.id");
setVariableData("outputVariable", "payload", "/client:HAHelloWorldProcessResponse/client:result", prop);
setTitle("Server:"+prop);



Step 5

Make sure your BPEL Process looks like below





Step 6

Goto opmn.xml in SOA Installation under opmn\conf directory on Node1 and peform the following.
Edit opmn.xml and add "-Dserver.id=vm104" in the "java-options" of process-type "OC4J_SOA"

It should look like below see the highlighted in red




Perform the same above operations in opmn.xml in SOA Installation under opmn\conf directory on Node2 just make the servier.id=vm105


Step 7

Restart both nodes


Step 8

Deploy the BPEL Process & Test.
When you run the BPEL Test and go to Instances tab you will see below





Download

You can download the complete code Here

Thursday, May 07, 2009

New JDeveloper Plugin for Visual Schema Print


Need

In Jdeveloper we can create schemas using Schema Designer, but there is no option to print the schema. Visual Schema Print will help in design discussions with functional/technical folks as they see the structure in visual rather than looking at source. This will be good for documentation purpose as well..

This Plugin adds this capability.


How to use

Follow the Instructions on
How Install Plugin from Update Center

or

Follow the Instructions on
How Install Plugin Manually


How Install Plugin From Update Center

Install the plugin as you would normally install any plugin in Jdeveloper. If you do not know or this is the first time follow the instruction below.

Steps


Click on "Check For Updates" on Help Toolbar



Select "Open Source adn Partner Extensions" and click on "Next"





Scroll down to find "Print/Save XML Schema", select checkbox and click Next.





Click on "Finish"





Click on "Yes" and restart JDeveloper





How Install Plugin Manually

Download the plugin from below link and save.
http://kalyan.bitra.googlepages.com/com.kalyan.ide.jdev.schema.zip

Steps


Click on "Check For Updates" on Help Toolbar



Click on "Next" on the following page





Select "Install From Local Files" and browse to where you saved the plugin.





Click on "Finish"





Click on "Yes" and restart JDeveloper





How to Use

Open any schema and right click on the designer you will see the "As PDF, As JPG" pr
"As Print" that's it.


Sunday, April 12, 2009

How-To Reload Fault Policy in 10.1.3.4

In 10.1.3.4 you can reload the fault polcies that are changed and does not need a system restart simply access the following JSP page and all the fualt-policies are reloaded.


http://<YourHost>:<YourPort>/BPELConsole/<YourDomainName>/doReloadFaultPolicy.jsp