BPM Modeling Patterns (Oracle BPM 12c) – http://bit.ly/1rglOBm

It gives me immense pleasure to let you know that my book on “BPM Modeling Patterns” has been released.

Available at all leading stores worldwide, including –

http://bit.ly/1rglOBm

https://www.packtpub.com/all-books/oracle-bpm-suite-12c-modeling-patterns

http://www.amazon.com/Oracle-BPM-Suite-Modeling-Patterns/dp/1849689024/

Title – BPM Modeling Patterns (Oracle BPM 12c)

Demonstrate the perceptible regularity in the world of BPMN design and implementation while diving into comprehensive learning path of much awaited Oracle BPM Modeling and implementation patterns where readers will discover the doing rather than reading about the doing! Spectrum of book covers patterns and features from strategic alignment (goals and strategy model) to flow patterns. From conversation, collaboration and correlation pattern to exception handling and management patterns. From human task patterns & business-IT collaboration to adaptive case management and much more.

Description – Oracle BPM Patterns title is an opportunity to demystify various patterns required to be followed while developing a professional BPM solution. . It allows you to fill the GAPS and offers contents which allow you to use BPMN to its full potential. With this title in hand you will gain details and practical experience in using Oracle BPM effectively while using patterns as best practice for implementations. Patterns like split-join, multi-instance, loop, cycle, termination etc allows you to drill into basic and advance flow based patterns. Integration, invocation, interaction and correlation patterns demonstrate collaboration and correlation of BPM with other systems, processes, events and services. Human interaction pattern topic leaves no stone touched in covering task modelling, routing, dispatching, dynamic task assignment, rule-based assignments, list building and other advance topics. Exception handling patterns is a comprehensive guide to model and implement exception handling in Oracle BPM implementation and design. Case management offers details guide to patterns handling unstructured data and unpredictable scenarios. Adaptive case management features and patterns will empower you in developing a milestone oriented, state based, rule-governed, content outbid, event-driven, case management solution. Also witness patterns which brings in enhanced and dynamic Business-IT collaboration. Experience the magic of strategic alignment features which bring close the requirement and analysis gaps and make the organizational activities very much in line with the goals, strategies and objectives.

Who this book is forThis book is an invaluable resource for enterprise architects, solution architects, developers, process analysts, application functional and technical consultants who use business process and BPMN to model and implement enterprise IT applications, SaaS and cloud applications. Primary focus is to showcase BPM patterns which are generic and can be read by anyone allied with any BPM offering and hence if you are associated with any BPM, you can relate with this title.

Custom Escalation in Oracle BPM

Read Custom Escalation in Oracle BPM @ -

http://technology.amis.nl/2014/01/29/custom-escalation-in-oracle-bpm-suite-11g-guest-post-by-vivek-acharya/

Handling Transaction Timeout in Oracle BPM

With Exception handling patterns chapter , we have covered patterns related to exception handling in Oracle BPM. Here let’s try to understand different levels of timeout and where to set the properties for them and equation to follow.

  1. Global java Transaction Timeout (JTA) :
    • Navigation: WLS Console –> Domain –> Configuration –> JTA
    • Description: You cannot catch fault if the timeout is occurring at JTA level. Neither a CATCH activity nor the fault policy will help in this scenario.
    • Effect: Instance will get rollback to last dehydration point.
  2. EJB Timeout (JTA) :
    • Navigation: WLS Console –> Deployments –> Control –> Expand SOA-INFRA –> Expand EJB node. Increase the “Transaction Timeout” (value in seconds) in the “Configuration” tab for the following EJB’s by clicking on them.
    • Description:  Many BPM engine EJB’s exist in “soa-infra” Enterprise application which process the message during runtime, each EJB has its own timeout parameter which need to configure and should be in relation with JTA and Resource timeout.
    • Effect: You cannot catch fault if the timeout is occurring at JTA level. Neither a CATCH activity nor the fault policy will help in this scenario.Instance will get rollback to last dehydration point.
  3. Resource Timeout :
  • Navigation: In composite.xml OR WLS EM –> Click on Project –> Service and References –> Click on the component. Example you are referencing a web service then you can set HTTP read timeout and HTTP Connection timeout from EM or you can set them in composite.xml at design time as properties in the reference section of the respective component.  Same can be done for another JCA adapter like database adapter. You can set query timeout from EM console for the DB adapter. You can use catch or fault policy to handle such exceptions.

Equation to follow –

If the Request pattern is as follows –

Consumer –> DMZ/Firewall/Load balancer  –> SOA Managed Server –> Provider System

Example – A portal application invokes a composite service which is referencing a database adapter to call a stored procedure.

Equation Can be –

Consumer System Timeout > DMZ System/Firewall/Load balancer timeout > JTA Timeout > EJB Timeout > Resource Timeout > Provider (Database)

Base equation to follow among the components discussed is –

JTA Timeout > EJB Timeout > Resource Timeout

———————————————————————

Understanding BPM Event

Understanding BPM Event

Collaboration is the message exchange between processes while conversation is for grouping message exchange between processes and it also defines the state of collaboration between participants and the message exchange will follow the message exchange patterns. BPEL process, BPMN process, Human tasks, Business rules and references are termed as participants in this context. Oracle BPM offers send and receive task, message events, signal events, service tasks, call activities etc. to communicate with other processes, service and events. This chapter you will expose the scenario where we have assumed that the loan origination processes gets started from the bank’s back office (customer case/ back office center). There are other ways too to initiate loan like web, branch etc. Backoffice process interacts with loan origination process and once the loan origination process gets completed, Backoffice process initiates customer feedback process. While implementing the sample due care is taken to demonstrate most of the BPM features which provisions interprocess and collaborative communications.

Oracle BPM offers four kinds of events -

  1. Start event
  2. Throw event
  3. Catch event and
  4. End event

9021_05_001

Start Event-  Message Start, Signal Start and Timer Start are used to start a new process instance. Start event can be  defined for a BPM process or can be a trigger type for the event Subprocess. Event Subprocess are used to handle a event and are referred as event Subprocess. They can either interrupt normal process flow or they can be non-interrupting. Event Subprocess can have message start, signal start, timer start and error start as the start trigger type. It’s only error trigger type for the event Subprocess which is interrupting in nature however all other trigger type can be both – interrupting and non- interrupting.

Intermediate events – Catch event and throw event are also termed as intermediate events as they establish interaction of a process with other process and services. Start events can only catch any triggers and end events which can throw triggers however intermediate events can throw and catch events.  As you will check in above table – intermediate events are of throw type and catch type to throw and catch events.

Catch event can used in many variants in Oracle BPM. Catch event can be configured as wait activities which happen to wait for message, signal or timer event to take place. OR catch events can be configured as a boundary event on various activities and sub processes. These boundary catch event can be of interrupting or  non-interrupting type , depends on the way they deal with the normal process flow. You can implement timer as boundary event to introduce a delay, SLA or a wait on an activity or a embedded Subprocess. You can use a receive activity in place of a catch event however they have there on use case which we have discussed in this chapter. Catch intermediate events are also used as boundary events to a Subprocess or activities of certain type. When any associated boundary event executes then the process flows to exception path. A boundary event can of interrupting or non-interrupting type. In non-interrupting boundary event, process flows to normal process flow and exception flow as both are mutually exclusive however in interrupting boundary event case, process flow moves to only exception flow.

Throw message intermediate event are, of asynchronous nature and can be turned into synchronous nature , used to send messages to external processes and services and a catch message intermediate event to receive callback message from other process or service.  Throw signal intermediate event is used to publish a signal while catch signal intermediate event is to subscribe and catch a broadcasted signal. When you publish and subscribe to events you are dealing with Oracle SOA’s EDN.

Timer boundary events are use to handle timeout exceptions and they can be of interrupting and non-interrupting types. Interrupting timer boundary event drags the process flow to exception path as it interrupts the normal process flow while the non-interrupting boundary timer event will allow the process to continue on normal path and in parallel also executes the exception flow. You can use non-interrupting  boundary timer in cases like notification or escalation etc.  Throw event are use to send a message or a signal in the process. They are similar to send task.

End event – They introduces normal process end if the process ends with a message or a signal. However if the process ends with a terminate or an error it;s termed as abnormal process ending.

9021_05_000

Note – N is specified for None start event as you cannot start a process instance by just having a none start event. You would need a receive task with create instance property or a initiator human task to create a process instance.

Image

Initiating Loan Origination BPM Process Over Email

Importing SSL certificates to Trust Keystore

As you would be using GMAIL, for incoming messages, you have to import gmail ssl certificates to weblogic trust store.

  1. Download the Gmail IMAP and SMTP certificates. This can be done with OpenSSL by running the following from command prompt:
  • openssl s_client -connect smtp.gmail.com:465
  • openssl s_client -connect imap.gmail.com:993

OpenSSL2. Copy the contents from –Begin Certificate– to –End Certificate– and create two text files as smtp.txt and imap.txt which contains certificates generated using openssl for SMTP and IMAP respectively.

3. Using Java Keytool, import the two certificates into trust store. You can create a new store. However we would use the exisitng DemoTrust.jks trust store. DemoTrust.jks trust store can be found at %WL_HOME%/server/lib/DemoTrust.jks and the keeytool is available @ %JAVA_HOME%/bin.

4. Use following command to import certificates to trust store-

keytool  -import -alias AliasName -keystore KeystoreLocation -file CertificateLocation

For Our example use -

keytool -import -alias gmailimap -keystore C:\Oracle\Middleware\wlserver\server\lib\DemoTrust.jks -file imap.txt

keytool -import -alias gmailsmtp -keystore C:\Oracle\Middleware\wlserver\server\lib\DemoTrust.jks -file smtp.txt

5. Enter “DemoTrustKeyStorePassPhrase” when prompt for DemoTrust store password.

6. Start/Restart the SOA server.

Configure Email Driver on WebLogic Server

  1. Login to WebLogic server as admin user (weblogic)
  2. Expand User Messaging Service
  3. Right Click usermessagingdriver-email and click on email driver properties as shown below -

EmailDriverConfiguration

4. Choose message exchange protocol as – MailAccessProtocol = IMAP

5. ReceiveFolder = INBOX

6. Furnish following details for incoming email server,port and SSL.

7. Let the incoming mail id be weblogic0009@gmail.com. You can change as per your requirements.

  1. Enter Email ID password as cleartext password in IncomingUserPasswords.
  2. Click Apply to Apply Changes.
  3. Right-click on soa-infra under SOA and navigate to the → SOA AdministrationWorkflow Notification Properties
  4. Set the Notification Mode to ‘Email’ and enter the values which you wish to use for from, actionable and reply to email addresses.

EmailDriverProperties3

  1. Click Apply and Restart SOA server for changes to persist.

Create a SOA/BPEL process to send email to “weblogic0009@gmail.com

To initiate the Loan Origination BPM process, you have to send email to weblogic0009@gmail.com’s INBOX as email driver is configured to pick messages from this box.

Download the Project – “PushToEmail” associated with this post.

  1. Open the project PushToEmail in Jdeveloper.
  2. Click on Composite.xml
  3. Open SendToEmail UMS adapter configuration
  4. It;s based on outbound JNDI – eis/ums/UMSAdapterOutbound
  5. Operation name defined is Outbound Send Notification
  6. Change following details as per your email configuration -

EmailDriverProperties4

  1. Notice the To address. It;s the address of the Loan Office which would receive the email in his/her Inbox from where the BPM process would initiate.
  2. Choose LoanOrigination schema associate with this blog and let the configuration of UMS be based on LoanOrigination schema.
  3. Create the BPEL process with default input and output
  4. Drag and assign values to UMS adapter input variable
  5. Save and Deploy the process.

Changing JCA Adapter properties using Configuration Plans

Changing JCA Adapter properties using Configuration Plans

While moving from one environment to another (DEV à TEST àPRD), you typically must modify several environment-specific values like –JDBC connection strings,

  • Host names of various servers,
  • Port details etc.

Composite.xml – Here you can replace following –

  • Any composite,
  • Service component,
  • Reference,
  • Service and
  • Binding properties.

Bindings – bindings.ws

  • Attribute values for bindings

WSDL

  • Schema Location attribute of an import in a WSDL file
  • Location attribute of an include in a WSDL fi

XSD

  • Schema Location attribute of an include, import, and redefine in an XSD file

JCA

  • Any properties in JCA adapter files

Policy

  • Modify and add policy references for the following
  • Service component
  • Service and reference binding components

Solution is to use configuration plan. Configuration plans enable you to modify these values using a single text (XML) file called a configuration plan. The configuration plan is created in either Oracle J-Developer or from the command line. During process deployment, the configuration plan is used to search the SOA project for values that must be replaced to adapt the project to the next target environment.

This blog we will check how to replace properties in JCA adapter files –

Use Case – Changing the Physical path for File Adapter from which it will read/write the contents.

While developing the Application; you design the adapter to have following path

  • /u01/fs/dev/filelocation

The .jca file in this case will look like

<connection-factory location=”eis/file/R12Fileadapter” adapterRef=””/>
<endpoint-interaction portType=”Write_ptt” operation=”Write”>
<interaction-spec className=”oracle.tip.adapter.file.outbound.FileInteractionSpec”>
<property name=”PhysicalDirectory” value=”/u01/fs/dev/filelocation “/>
<property name=”Append” value=”false”/>
<property name=”NumberMessages” value=”1″/>
</interaction-spec>
</endpoint-interaction>

  1. Generate a configuration for your composite
  2. Use the following code in configuration file to change the file location (Physical directory property of File Adapter ) –

    <wsdlAndSchema name=”SampleFileAdapter_file.jca”>
    <jca:property name=”PhysicalDirectory”><replace>/u01/fs/crp/filelocation</replace>       </jca:property>    </wsdlAndSchema> 

  3. You will get the Physical Directory path replaced to – u01/fs/crp/filelocation

Similarly; you can replace the Topic/Queue name for the JMS adapter using following

<!– replace jms destination for jms adapter –>
<wsdlAndSchema name=”JMSAdapter_jms.jca”>
<jca:property name=”DestinationName”>

<replace>jms/CRPTopic</replace>
</jca:property>
</wsdlAndSchema>

Oracle BPM – Business Value

Business finds that BPM is unavoidable and needs a reasonable explanation to – “What value organizations currently derive from BPM?”

What’s triggers BPM – Business triggers are: growth & innovation, standardization, compliance & safety, mergers & acquisitions, cost reduction, risk management, emerging competition, major business or IT transformations, major systems implementations (e.g. ERP), next generation process automation, or the decision to establish a BPM capability.

BPM is a thing of past, with CEP+BPM; vendors are offering ‘iBPM (Intelligent BPMs)’. Still no surprise that value addition is a primary concern for many.  So let’s talk about the values BPM offers –

  1. Transparency – The approach supports a better understanding of processes, and enables organizations to consider them during managerial decision-making.
  2. Streamline operations – They allow organizations to streamline operations (efficiency) and can contribute to increased quality of products, services and processes.
  3. Improved internal integration (for example, by driving the creation of employee centered processes) and external networking via tighter supply chains and an increased focus on the environmental implications of corporate operations.
  4. Agility and Predictability – BPM initiatives are essential in ensuring predictability and consistency (Compliance) as much as facilitating increased organizational agility.
  5. Visibility – BPM gives visibility of what is going on inside business processes in real-time. This means better visibility of business environment metrics and the integrated value chain, which includes forecast, supply, production, distribution, sales, invoicing, and customer service. This visibility enables us to monitor the KPIs and SLAs, and answer a wide range of questions, such as:     – How many new accounts were opened during this particular time?Are we  performing above or below the KPI?Which region is selling more?Which process is causing a bottleneck, how many transactions are blocked in and how much money do they represent?How many claims were received and how many have been resolved? How many loans are waiting for approval and how many were rejected?
  6. KPI and SLA driven business – BPM also allows managers to drive the business based on KPIs and SLAs. For example, in loan processing there are usually a lot of manual and paper-based activities. BPM replaces paper with electronic forms or scanned images that are automatically routed through the process. So if the marketing department launches a campaign promising loan approval in one day, BPM can automate that process and ensure adherence with SLAs.
  7. Optimizing business performance – BPM helps companies to drive their business according to specific objectives. BPM would enable the loan company to follow and manage each loan application in real-time through the whole approval process. Managers would be able to identify the products and the business units which are performing well, helping them to take better and faster decisions in order to increase business performance according to KPIs and SLAs.

Who don’t want its business to –

  • Identify high-impact opportunities
  • Define the best approach to exploit these opportunities (business + technology)
  • Implement solutions and continuous improvement
  • Implement change management and self-sufficiency.

Who can offer this? – BPM