Friday, November 5, 2010

Sharing models in BizAgi Studio Xpress

We have started to evaluate BizAgi Studio Xpress for a prototype we are building. The tool is easy to use for business analysts: they can download it themselves and just press ‘Next’ to install it on their machine. Really.

Next you start by modeling your process, define the data model and design the screens for human interaction. I will talk about the pros and cons of this approach in the next post. Today I want to talk about sharing the projects you create with Studio Xpress with other people.

BizAgi Studio Xpress stores the meta data (the process, the data and the screens) in a SQL Server database. If you get the enterprise edition you have more choices: you can use an Oracle database and application server platforms. Because I am working remotely on the prototype with our business partner Creetion, we needed to share the project we defined. This means we have to export the database and import it again at ‘the other side’.

The BizAgi website explains how to do this: you need to download SQL Server Management Studio. So far so good: I downloaded the SQL Server Management Studio and tried to install it. I have Windows7 installed on my laptop, and have (of course) administrator rights. However, when I run the msi, I get error-code 29506: “The installer has found an unexpected error while installing this package.” Apparently, you need system rights to install the application. The solution is to run the msi as an administrator. Bizagi has written in more detail how to accomplish this here.

Luckily a lot of people ran into this problem :-( , so there is plenty of information about this topic . Once I installed it, I tried to run the SQL Server Management Studio to create a backup of my project. Again, I got an error because I need to run the application as an administrator. This drives me nuts in Windows7: I have defined myself as an administrator but still I need to run a lot of software ‘as an administrator’! The platform is nice to edit Office documents and to surf the net. But when you trying to use version control systems, databases or any other advanced tool, the OS gets in the way.

Creating the backup is not hard. Yo do have to make sure you put ‘.bak’ as an extension in the filename, the SQL Server Management Studio does not do this for you. When you restore the database, it won’t show up in the list if you didn’t add this extension.

I am not sure where to put the blame: with Microsoft for the lousy user permission and security scheme in Windows7 or with Microsoft for the lousy integration of SQL Server Management Studio with the Windows7 user permission and security scheme….. wait: I can blame Microsoft either way :-)

But, we can now work remotely (but not at the same time) on the same database: everytime one of us updates the project, we create a backup and store this in our shared Dropbox folder.

A nice addition to BizAgi Studio Xpress would be an option to create the backup and restore directly from the Studio menu. I don’t mind installing database management software. But my colleagues, who are more business oriented, don’t appreciate this at all.

Friday, October 8, 2010

Highlights from the SOA Symposium

Tuesday October 5th and Wednesday October 6th, the third edition of the SOA & Cloud symposium took place in Berlin. The location was really nice: at Alexander Platz, close to the train station and with plenty of hotels in the vicinity of the conference center.

I presented the case study Service Orientation in the Dutch Government.But I also attended many interesting sessions and talked to interesting people.

Build schools not prisons

The session Deriving Agility from SOA and BPM – Ten Things That Separate the Winners from the Losers, by Manas Deb and Clemens Utschig-Utschig was a very pleasant suprise. Instead of using agility as a buzz word to justify SOA and BPM, they actually spent time to explain what they mean by an agile organization. They used the sense-and-respond model by Haeckel for this. Then they proceeded to explain the things that separate the winners from the losers, with clear examples that people could relate to. A solid presentation, with some nice one-liners for the twittering audience (my tweet “governance: build schools, not prisons” in the heading came from this presentation)

BPM: Top Seven Architectural Discussions in 2010, touched upon a number of interesting topics. A highlight for me: most of the ‘business beef’(value) in BPM projects comes from the task flow level, optimizing the human tasks. This ties in nicely with the Approach vision about the need for user experience in solutions ;-)

The last session I attended the first day was Open Source Process Execution. Unfortunately, only two delegates were attending: someone from ASR and me. The talk was really on Activiti, an open source project that looks very promising. Coincidently, I ran into again someone who was using that in a meeting today. So the stuff I learned was already useful the same week!

Look bored if you already know this

Ralph Schafermeier talked about corporate semantic web: Corporate Semantic Web – The Semantic Web Meets the Enterprise. He started with an introduction of semantic web, and announced that he would skip it if we looked bored. This introduction was good. The only bad thing was there were a couple of people in the room, they wanted every definition to be phrased ‘exactly right’. This took up valuable time. I guess this is to be expected from semantic web people, to discuss semantics :-( . It distracted the attention from the real topic: application of this concept to BPM and CEP. Ralph showed a really interesting concept of adding semantic web annotations in BPMN models. This sounds to me as a very powerful concept that we will hear much more about in the future. If you want to check it out right now visit the Oryx site here. I did not look bored during this session, on the contrary!

BPM with REST, investigated if and how REST can be applied in an BPM engine. This is very interesting from a perspective of change management and creating more flexible interactions than with ‘traditional ‘ WSDL based integration. Solid speaker, solid presentation. Again an interesting research topic that will become applicable in the future. Maybe in case management this is a much better solution than in orchestration? I am still thinking about the concepts…

The last session I attended was Modern SOA Infrastructure and Open Source by Mark Little. This was not a very compelling story; personally I believe there are plenty of use cases where Open Source infrastructure is more than a viable option. However, the reasoning that was used in this presentation was full of circular logic: the definition of open is that the code is open source. Therefore Oracle can’t claim they are ‘open’. Or: “open source is built by real world developers”, as if closed sourced developers are not in the real world?!? This was I think a missed opportunity: it was based on prejudice and I doubt he convinced anybody who was not already convinced of the value of open source infrastructure.

All in all a great two days, and I even went home with a helicopter from the Oracle stand!

Friday, September 24, 2010

Random thoughts about Oracle OpenWorld, Oracle Develop and JavaOne 2010

Today was the last day of Oracle OpenWorld. It was the fifth time for me, so the amazing crowd that floods San Francisco doesn’t surprise me anymore. There was a big difference this time, though: it was the first time that JavaOne was part of the conference. I had visited JavaOne twice before. Both times the conference was in Moscone. For obvious reasons, this was not possible this time. Moscone is big, but not that big….

They moved JavaOne over to the Hilton, Park 55 hotel, and Nikko hotel where Oracle Develop also took place. Being in these hotel feels smaller and less ‘buzzing with energy’ compared to Moscone. It didn’t bother me, because I am used to it: they did this before with Oracle Develop. But for the JavaOne visitors, it was a step back. I attended a session about SOAP versus REST webservices. The session was very well attended, it was a repeat from the day before. The room was small and one of the presenters had to leave early because he had a plane to catch. I think that if this session would have been located at Moscone, it would probably have fitted all the people that wanted to attend on Wednesday. This would have improved the quality: the story became a little one-sided because the SOAP guy left..

The problem of finding sessions that you want to attend was even bigger this time than last year: adding JavaOne to the mix increased the amount of sessions you have to chose from to an incredible number. The schedulebuilder doesn’t help. In fact it seems to deteriorate evey year: I missed some sessions I would have liked to attend: for example the session by Mark Simpson on Governance. Some sessions ‘dispappeared’ from the schedule: for example the ADF session by Sten Vesterli.

Now let’s take a look at the bright side:


I loved meeting all the Oracle Ace Directors, Oracle Productmanagers and the people from Oracle Technology Network again. Meeting here every year really makes the community sustainable. You can do a lot of stuff online, but it really helps if you meet people in person once or twice a year. I even bumped into some Dutch people I hadn’t seen in a while. It feels like one big reunion all week long.

We had our first ‘official’ session of the new SOA BPM enterprise methodology group at the unconference sessions. We talked about best practices for using existing database logic in a SOA environment, and tips for communication with .NET services in your enterprise.

I attended interesting sessions (in random order, since this blog contains random thoughts):

  • Dirk Staehler showed the methodology Opitz uses with Oracle BPA Suite for enterprise architecture, SOA and BPM.
  • A nice overview of use cases for SOAP and use cases for REST webservices
  • A demo showing the use of UCM, more specifically the imaging solution with the prebuilt integration with Oracle BPM for invoice processing
  • The BPM CAB where I met with the people responsible for the integration between Oracle BPA Suite11g and Oracle SOA suite11g and Oracle BPM Suite11g.
  • The partner council that was organized by Juergen Kress. Dave Shaffer was doing a great job getting the feedback from the partners and explaining the roadmap and other stuff that I can’t talk about ;-)

Of course, it was not all work: I had great breakfast, lunches, dinners and coffees with friends. I visited the Oakland museum to check out the awesome Pixar exposition and of course went to the appreciation event at Treasure Island!

All in all, the conference was a huge success for me and I am already looking forward to next year!

Monday, September 20, 2010

Fault handling in Oracle SOA Suite 11g - Part IV

See part I, part II, and part III of this blog for more information on fault handling. The last component of our fault handling framework is the SCA composite that acts as generic fault handler. An example of such a composite would roughly do the following:

  • Dequeue an event from the fault queue causing an instance of this composite to be created;
  • Retrieve the fault information using the event payload and Oracle SOA Suite API’s;
  • Initiate a Human Task to notify administrators a fault has occurred in some composite instance.

You could either choose to pass the fault information to the Human Task itself or leave this to the application displaying the Human Task and the relevant information to deal with this task. In this case the fault information.

Since most of the above is straight-forward we will focus on retrieving the fault information using the Oracle SOA Suite API’s.

Retrieving fault information
Here are some snippets from a Java class that retrieves the fault information. This Java class could be exposed as Web Service, EJB Session Bean, or some other technology so it can be invoked from SCA composites.

Locator locator = LocatorFactory.createLocator();
FaultFilter faultFilter = new FaultFilter();
faultFilter.setECID(ecid);
List faults = locator.getFaults(faultFilter);

You could extend this example and use the Locator API to retrieve additional information such as the composite sensor data belonging to the composite instance that faulted. That way the administrators will have more information on the SCA composite instance.

Locator locator = LocatorFactory.createLocator();
Composite composite = locator.lookupComposite(compositeDN);
CompositeInstanceFilter compositeInstanceFilter = new CompositeInstanceFilter();
compositeInstanceFilter.setECID(ecid);
List instances = composite.getInstances(compositeInstanceFilter);
List sensors = instances.get(0).getSensorData();

And that concludes the final component of our generic fault handler!

Some notes that were acquired during the further implementation of this fault handler:

Faults that occur in BPEL flows -other then Invoke activities- will not be caught by the fault handling framework. An example would be an incorrect XPath expression in an Assign activity. You will need to use some other mechanism such as the Catch and CatchAll activities for that. These handlers could then enqueue an event on the same fault queue as our fault handler does. Or you could test your SCA composites using the out-of-the-box SOA Suite’s test framework to minimize the chance of errors in the BPEL flow itself. Usually there is a higher occurrence of runtime or unexpected faults when invoking external components such as Web Services then in your own BPEL components (given of course that you test your software).

It seems that not all faults are registered in the SOAINFRA database when “ora-terminate” is used as fault action. Especially faults that occur in Invoke activities of BPEL flows (compared to faults in Mediators and Adapters). When switching to “ora-retry” instead, faults and their information are stored in the COMPOSITE_INSTANCE_FAULT table. Switching from terminate to retry as outcome would mean the SOA composite in which the fault occurred will remain in “RUNNING” state according to the Enterprise Manager and will not be terminated.

Wednesday, September 15, 2010

Fault handling in Oracle SOA Suite 11g - Part III

Let's pick up the previous posts on fault handling (part I and part II) from where we left off: our custom Java class that handles faults. Remember that our class is supposed to enqueue an event containing the fault’s identifier and return the action to be executed by Oracle SOA Suite’s fault handling framework. Retrieval of the fault information itself is done by the SCA composite that acts as generic fault handler. This composite will be initiated based on the fault event and retrieve the fault information based on its identifier in the event payload using the Oracle SOA Suite API’s. The composite will then initiate a Human Task to notify administrators that there was a fault in one our composite instances.

Note that we enqueue a fault identifier (its ECID) instead of the fault information itself. When executing the Java class, Oracle SOA Suite is still in the middle of the fault handling mechanism. That means the fault and its corresponding information is not yet fully stored and accessible. After the event is published and control is returned from the Java fault handler class, Oracle SOA Suite will complete the fault handling mechanism and all fault information will be accessible using for instance the SOA Suite API’s.

The Java code
The Java class needs to implement the “IFaultRecoveryJavaClass” interface and its handleFault method. This method receives the fault context. The method enqueues an event on an AQ queue containing the fault identifier and returns “ora-terminate” to the fault handling framework. Alternatively you can also use JMS or EDN as queuing infrastructure. The choice depends on requirements, durability, personal flavor, and so on. For an example on publishing events on the Event Delivery Network using Spring you can read this blog by Guido Schmutz.

You will need to import the following libraries and JAR files to make the class compile:

  • SOA Runtime
  • Oracle JDBC
  • Java EE 1.5 API
  • Oracle XML Parser v2
  • SOA Designtime
  • SOA Workflow
  • WebLogic 10.3 Remote-Client


The class roughly looks like this:

package nl.vennster;


public class MyFaultPolicyJavaAction implements IFaultRecoveryJavaClass {

public String handleFault(IFaultRecoveryContext ctx) {
    UUID uuid = UUID.randomUUID();
    enqueueAqEvent(createEventPayload(ctx), uuid);
    return "ora-terminate";
}

}

The helper method to create the AQ event looks like the following:

private String createEventPayload(IFaultRecoveryContext context) {


String eventPayload = " UNKNOWN_ECID";
if (context instanceof RejectedMsgRecoveryContext) {
RejectedMsgRecoveryContext rejectedMessageContext = (RejectedMsgRecoveryContext) context;
String ecid = null;
if (rejectedMessageContext.getRejectedMessage() != null &&
    rejectedMessageContext.getRejectedMessage().getEcid() != null) {
    ecid = rejectedMessageContext.getRejectedMessage().getEcid();
}
else if (rejectedMessageContext.getFault() != null &&
    rejectedMessageContext.getFault().getECID() != null) {
    ecid = rejectedMessageContext.getFault().getECID();
    eventPayload = eventPayload.replace("UNKNOWN_ECID", ecid);
}
else if (context instanceof BPELFaultRecoveryContextImpl) {
    BPELFaultRecoveryContextImpl bpelFaultRecoveryContextImpl = (BPELFaultRecoveryContextImpl) context;
    eventPayload = eventPayload.replace(“UNKNOWN_ECID”, bpelFaultRecoveryContextImpl.getECID());
}

return eventPayload;
}

Finally, the helper method to enqueue the event on AQ:

public void enqueueAqEvent(String input, UUID uuid) throws JMSException, NamingException, IOException {
Session session = null;
MessageProducer publisher = null;
TextMessage message = null;
Context context = new InitialContext();
Properties properties = new Properties();
InputStream is = this.getClass().getClassLoader().getResourceAsStream(“aq.datasource.properties”);
properties.load(is);
QueueConnectionFactory connectionFactory = (QueueConnectionFactory)context.lookup((String) properties.get(“aq.queueconnectionfactory”));
javax.jms.Connection connection = connectionFactory.createConnection();
Queue queue = (Queue) context.lookup((String) properties.get(“aq.queue”));
session = connection.createSession(true, 0);
publisher = session.createProducer(queue);
message = session.createTextMessage(input);
message.setJMSCorrelationID(uuid.toString());
publisher.send(message);
}

I used the following properties file that defines the AQ connection factory and queue itself. You need to make sure these JNDI destinations exist on the Oracle WebLogic Server on which Oracle SOA Suite runs:

aq.queueconnectionfactory = aqjms/XAQueueConnectionFactory
aq.queue = eis/aqjms/ALG_ADMIN_QUEUE

Deploying the Java Fault Handler
You cannot just deploy the resulting JAR file containing the above Java class to Oracle SOA Suite. As documented in the Oracle Fusion Middleware Developer’s Guide for Oracle SOA Suite 11g you need to do the following:
You can add custom classes and JAR files to an SOA composite application. A SOA extension library for adding extension classes and JARs to an SOA composite application is available in the $ORACLE_HOME/soa/modules/oracle.soa.ext_11.1.1 directory. 
To add custom JARs:
  1. Copy the JAR files to this directory or its subdirectory.
  2. Run ant.
  3. Restart Oracle WebLogic Server.
This is required because of library classloading among others.

Read more on fault handling in part IV of this blog series.

Sunday, August 1, 2010

Fault handling in Oracle SOA Suite 11g - Part II

This previous blog explained why it is a good idea to address -and handle- business faults separately from technical errors. It also introduced a mechanism used in real life Oracle SOA Suite 11g projects to deal with technical errors in a generic way without having to add this functionality to all our SCA composites again and again. Now it is time to dive into the technical implementation of that mechanism and some nitty gritty details.

First things first: How do we get a hold of these technical errors and how can we determine what to do with them?

Oracle SOA Suite 11g offers a unified fault handling framework for SCA composites and their references, service adapters and components such as BPEL and Mediator components. The framework provides hooks you can use to configure fault handling and possibly call out to your own fault handling code. The unified framework is an improvement compared to the SOA Suite 10g stack that consisted of less integrated components (ESB, BPEL) that had their own fault handling mechanisms. The framework is heavily based on BPEL PM’s 10g fault handling framework.

In SOA Suite 11g you configure the fault handling framework on the level of SCA composites using two files: fault-policies.xml and fault-bindings.xml. By default these files need to be in the same directory as the composite.xml file.

Note that you can place these files somewhere else and have multiple SCA composites point to the same fault handling configuration. MDS is a nice candidate since it is a repository for shared artefacts such as reusable XSD’s, DVM’s, and so on. To do this you need to set the “oracle.composite.faultPolicyFile” and “oracle.composite.faultBindingFile” properties in the composite.xml files and point them to fault binding and policy files in the central MDS location. Whether you use this feature mostly depends on how unique your fault handling per SCA composite will be. For now, we will continue with the basic scenario in which we define fault policies per SCA composite.

First of all we will configure the fault-bindings.xml file. This file defines what elements are bound to what fault policy. Elements can be components, references, service adapters or an entire composite. The actual fault policy that is referred to will be defined later on in the fault-policies.xml file. Since business faults can be dealt with using BPEL activities such as Throw and Catch activities we want to have all remaining faults (all unexpected faults) in the entire composite to be handled the same way.

Let’s say we have a simple SCA composite with an inbound file adapter called “MyInboundFileService” and some other components such as a BPEL and Mediator components. Our fault-bindings.xml file could look like the following:


<?xml version="1.0" encoding="UTF-8"?>
<faultPolicyBindings version="2.0.1"
                     xmlns="http://schemas.oracle.com/bpel/faultpolicy">
    <composite faultPolicy="MyCompositeFaultPolicy"/>
</faultPolicyBindings>


In this example we bind fault handling for the entire composite to the -yet to be defined- policy “MyCompositeFaultPolicy”. Instead of the “composite” element you can use the “component” or “reference” elements to apply fault handling on a more granular level.

Next we need to define the fault-policies.xml file. This file defines the actual policies and the conditions when these policies should be executed.

Following the example we will define a single policy, namely “MyCompositeFaultPolicy”:



As you can see from the example we first define the criteria when the policy should be executed. In this case we want it to be executed in case of any technical error. More specifically in case the error is of type “mediatorFault”, “bindingFault” or “runtimeFault”. Note that we can define more intelligent conditions that can be content-based (e.g. based on process instance variables).


<?xml version="1.0"?>
<faultPolicies xmlns="http://schemas.oracle.com/bpel/faultpolicy">
  <faultPolicy version="2.0.1" id="Subsidie_FaultPolicy">
    <Conditions>
      <faultName xmlns:medns="http://schemas.oracle.com/mediator/faults"
 name="medns:mediatorFault">
        <condition>
          <action ref="MyFaultPolicyJavaAction"/>
        </condition>
      </faultName>
      <faultName xmlns:bpelx="http://schemas.oracle.com/bpel/extension"
 name="bpelx:bindingFault">
        <condition>
          <action ref="BPELJavaAction"/>
        </condition>
      </faultName>
      <faultName xmlns:bpelx="http://schemas.oracle.com/bpel/extension"
 name="bpelx:runtimeFault">
        <condition>
          <action ref="MyFaultPolicyJavaAction"/>
        </condition>
      </faultName>
    </Conditions>
    <Actions>
      <Action id="ora-terminate">
        <abort/>
      </Action>     
      <Action id="MyFaultPolicyJavaAction">
        <javaAction className="nl.vennster.MyFaultPolicyJavaAction"
                    defaultAction="ora-terminate">
          <returnValue value="ora-terminate" ref="ora-terminate"/>
        </javaAction>
      </Action>
    </Actions>
  </faultPolicy>
</faultPolicies>


When the error meets any of these criteria the actions within the “Actions” element will be executed. Instead of configuring default actions such as abort, retry or rethrow we redirect the fault to our own Java class called “MyFaultPolicyJavaAction”. This is allowed as long as such a class implements the “IFaultRecoveryJavaClass” class containing the methods “handleFault” and “handleRetrySuccess”. Since the fault may occur within synchronous processes the fault handling framework needs to know what to do after it delegates the fault to some external piece of code. In order to do so the “handleFault” method needs to return the outcome as String. This outcome should map to a predefined fault action. In our example we abort the process instance after our custom Java class has been executed by returning “ora-terminate” that is mapped to the default abort action. Next to that, Java actions need to define a “defaultAction” attribute in case the outcome cannot be mapped to a predefined fault policy.

For some reason rejected messages need to be defined separately. In other words, such faults remain uncaught when using the above fault handling configuration. An example of a rejected message can be an inbound file that cannot be parsed correctly by a File Adapter. To have rejected messages handled we need to specifically include it using the exact name of the adapter service or reference. In our case the inbound file adapter is named “MyInboundFileService”. Our fault-bindings.xml file now looks like this:


<?xml version="1.0"?>
<faultPolicyBindings version="2.0.1"
                     xmlns="http://schemas.oracle.com/bpel/faultpolicy">
    <composite faultPolicy="MyCompositeFaultPolicy"/>
    <service faultPolicy="RejectedMessages">
        <name>MyInboundFileService</name>
    </service>
</faultPolicyBindings>


Note that you can add more than one adapter name to the “service” element. That way all rejected messages of all adapters can be handled the same way. So for instance you can add “MyOutboundDatabaseService” to the “RejectedMessages” policy too.


<?xml version="1.0" encoding="UTF-8"?>
<faultPolicyBindings version="2.0.1"
                     xmlns="http://schemas.oracle.com/bpel/faultpolicy">
    <composite faultPolicy="MyCompositeFaultPolicy"/>
    <service faultPolicy="RejectedMessages">
        <name>MyInboundFileService</name>
<name>MyOutboundDatabaseService</name>
    </service>
</faultPolicyBindings>


We need to add a fault policy to the fault-policies.xml file so our Java class is executed:


<?xml version="1.0"?>
<faultPolicies xmlns="http://schemas.oracle.com/bpel/faultpolicy">
  <faultPolicy version="2.0.1" id="Subsidie_FaultPolicy">
    <Conditions>
      <faultName xmlns:medns="http://schemas.oracle.com/mediator/faults"
 name="medns:mediatorFault">
        <condition>
          <action ref="MyFaultPolicyJavaAction"/>
        </condition>
      </faultName>
      <faultName xmlns:bpelx="http://schemas.oracle.com/bpel/extension"
 name="bpelx:bindingFault">
        <condition>
          <action ref="BPELJavaAction"/>
        </condition>
      </faultName>
      <faultName xmlns:bpelx="http://schemas.oracle.com/bpel/extension"
 name="bpelx:runtimeFault">
        <condition>
          <action ref="MyFaultPolicyJavaAction"/>
        </condition>
      </faultName>
    </Conditions>
    <Actions>
      <Action id="ora-terminate">
        <abort/>
      </Action>     
      <Action id="MyFaultPolicyJavaAction">
        <javaAction className="nl.vennster.MyFaultPolicyJavaAction"
                    defaultAction="ora-terminate">
          <returnValue value="ora-terminate" ref="ora-terminate"/>
        </javaAction>
      </Action>
    </Actions>
  </faultPolicy>
  <faultPolicy version="2.0.1" id="RejectedMessages">
    <Conditions>
      <faultName xmlns:rjm="http://schemas.oracle.com/sca/rejectedmessages">
        <condition>
          <action ref="MyFaultPolicyJavaAction"/>
        </condition>
      </faultName>
    </Conditions>
    <Actions>
      <Action id="ora-terminate">
        <abort/>
      </Action>
      <Action id="MyFaultPolicyJavaAction">
        <javaAction className="nl.vennster.MyFaultPolicyJavaAction"
                    defaultAction="ora-terminate">
          <returnValue value="ora-terminate" ref="ora-terminate"/>
        </javaAction>
      </Action>
    </Actions>
  </faultPolicy>  
</faultPolicies>

Read more on fault handling in part III and part IV of this blog series.

Thursday, July 1, 2010

Fault handling in Oracle SOA Suite 11g - Part I

You generally want to differentiate between technical errors and functional faults within your processes and services. Functional faults are those that have meaning to the business and might be expected. Functional faults and handling these faults can be part of a process. Consider the example of electronic invoice handling in which an invoice is processed that has a total amount of $2000 while an organization only approved an amount of $1500. In this scenario we can use a human task to halt this particular process instance and assign it to the finance department. An employee of the finance department acquires the task and investigates the issue. He or she may conclude that the client sending the invoice was mistaken, that the invoice approval was not entered correctly in our backend IT-systems or that someone put a coffee mug on the invoice and hence the amount was wrongly interpreted by our scanning and OCR software. In any case, after this human intervention the process may continue again and follow the “happy flow” in our BPEL or BPM processes.

When it comes to technical faults you probably do not want to design error handling in the process itself. If you do, your processes and services will end up being cluttered with all kinds of additional process logic such as while loops, gotos, catches, event handling, and so on to try to recover from technical errors. Technical errors might not be recoverable at all; think of an invoice file that is incorrectly formatted, an invoice file that contains negative numbers while your service or process only accepts positive values, or an invoice file that is mangled during transport. Besides, trying to handle these errors makes your SCA composites look like a mix of spaghetti and circuit boards. Not exactly flexible, agile and manageable: the things we wanted to achieve with service- and process-orientation in the first place.

This blog series contains a possible mechanism to generically handle technical errors in your processes and services -that are wrapped as SCA composites- in Oracle SOA Suite 11g.

In one of our projects we came across a scenario in which administrators need to be notified in case of technical errors in any of the SCA composites. Next to the notification they want the corresponding composite to be terminated. Administrators then investigate the cause of the problem and possibly restart the process instances that are involved. Since every employee uses a task-driven portal, administrators want the error to be presented as a human task in this portal instead of receiving a bunch of e-mails. This needed to be implemented with a minimum of additional (business or process) logic.

To achieve this the following mechanism is used:

  • Use Oracle SOA Suite’s Fault Management Framework to redirect (technical) errors to a custom Java class;
  • Have the Java class fire an event containing the unique id of the instance using the Event Delivery Network (EDN) or Advanced Queuing (AQ);
  • Terminate the composite instance by using the Fault Management Framework and the outcome of the custom Java class;
  • Create a single SCA composite to handle all technical errors. This composite subscribes to the event, gathers information on the faulted composite instance, and presents this information as a human task that is assigned to administrators.


Read more on fault handling in part IIpart III and part IV of this blog series.

Thursday, June 10, 2010

Experiencing Coaching an User Experience Graduate

Excitement...

The moment I was asked to coach an User Experience graduate from the Hogeschool Rotterdam, I was enthusiastic. In my professional career I’ve been coaching several students and to me this has always been very inspiring. When you are working in the area of User Experience for quite some years like me, working together with students provides me with new viewpoints and insights. These new insights stimulate me to look differently to my own assignments and that is very refreshing.

Feeling of insufficiency...

This time there was one difference with all the other student projects I’d coached before. This specific graduation assignment was defined by my UX colleague at Vennster without my consolidation, because I was involved in other assignments at that time. Thereby this graduation project consisted of a topic of which I had very little knowledge. This definitely was a hurdle to take, especially at the start of the project. Regarding the content I wasn’t able to give the graduate much of advice. That felt as a shortcoming on my behalf.

Fortunately Vennster employs more professionals, who were able to help the graduate with his topic. By asking relevant and provocative questions, we tried to stimulate him to focus his research and come up with refreshing insights and conclusions.

Tip: As a graduation coach you don’t need to know all about the subject. In the end the graduate will be more experienced on the topic than you are anyway. However with your knowledge and experience, you can still stimulate the graduate to explore all far corners of the subject by asking the right questions.

No sense of urgency...

It’s in a sponsor’s interest to keep the graduate on the right track regarding the planning and deliverables within a graduation project which should come to an end within a specific amount of months. Some graduates might find this quite a difficult task to accomplish, possibly because their school assignments mostly have predefined milestones and shorter time spans. Therefore I requested him to set up a planning. Being his sponsor from Vennster, I wanted him to think about what he expected to deliver to me. I also asked him when he would deliver. Due to my experience in coaching other graduation projects, I noticed that for graduates, content often is more important than planning. In a business however as well content as planning are both of equal importances. If the agreed content isn’t delivered in time, it might not be useful/relevant/valid anymore.

Tip: As a graduation coach you need to stimulate (help) the graduate to set up a planning including deliverables and liaisons. The planning should be fine-tuned during the graduation process and deadlines should be kept.

Desperateness...

I expected/asked the graduate to keep me informed about his way of working and his progress. Most of the working hours we were sitting in the same office, so I expected communication would not be a problem.

During their education UX students appear to learn a lot about gathering content and applying design methods. However they seem to have hardly any experience in dealing with a sponsor and the related communication expectations.

Despite of, maybe even due to, all my experience with experienced professionals, I didn’t realize that. I waited in vain until the graduate would keep me posted about the outcomes and hands-on deliverables. I repeatedly asked for information, but it didn’t help. Like this, I didn’t get any information. Instead, I should have planned a regular meeting, at least once every two weeks.

Fortunately, social media can be of great help. I started to follow my graduate on Twitter. I tried to figure out what the problem was. I gave tips and tricks to support his way of working. I gave him deadlines. I felt I wasn’t able to coach him properly. I had become a policewoman.

Tip: In case of a graduation project it sometimes is better to assign the coaching and the sponsoring task to two different people within the guiding company. Then the coaching professional can focus on coaching, while the sponsor plays the role of the ordering customer.

Relief...

Together with my UX colleague Nils Vergeer within Vennster, we each took on one task. This worked great. Nils told the graduate what he as a sponsor expected him to deliver at what time and told him what would happen if he didn’t. In the meantime I could go on supporting the graduation process and supply him with tips and tricks on how to deliver in time.

Tip: As a sponsor you have to be clear in expressing your professional expectations according to deliverables and planning.

Joy...

This worked remarkably well. The graduate found his way and graduated in time by presenting a great report on the subject, supported by a tool he designed to support UX-designers and software developers working closely together.