P. 1
7106514 Tib Bw Process Design Guide

7106514 Tib Bw Process Design Guide

|Views: 340|Likes:
Published by Swit Tei

More info:

Published by: Swit Tei on Aug 26, 2011
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as PDF, TXT or read online from Scribd
See more
See less

05/25/2012

pdf

text

original

Sections

  • How to Contact TIBCO Customer Support
  • Chapter1 Getting Started With TIBCO Designer
  • Welcome to TIBCO Designer
  • Starting TIBCO Designer
  • Starting the Program
  • Startup Options
  • Figure1 TIBCO Designer startup panel
  • Table1 Startup panel Project options
  • TIBCO Designer Administration
  • Table2 Startup panel Administration options
  • TIBCO Designer Interface Overview
  • Main Window
  • Figure3 The TIBCO Designer window
  • Project Panel
  • Project Display
  • Resources
  • Palette Panel
  • Design Panel
  • Configuration Panel
  • Customizing the Display
  • Choosing Panel Layout
  • Choosing Palette Mode or Non-palette Mode
  • Displaying Palettes in a Separate Window
  • Working With User Palettes
  • Documentation
  • Chapter2 Managing Projects and Resources
  • Overview of Projects
  • Project Structure
  • Using a Version Control System
  • Project Templates
  • Creating Projects
  • Validating Projects
  • Saving Projects
  • Saving a Project as a Template
  • Project Settings
  • Opening and Reopening Projects
  • Adding Resources To Your Project
  • If Adding a Resource Results in an Error
  • Deleting Projects
  • Tips and Tricks for Working With Projects
  • Chapter3 Processes
  • Business Process Modeling
  • TIBCO BusinessWorks Solves Enterprise Integration Problems
  • Overview of Processes
  • Process Definitions
  • •Activities
  • Activities
  • Transitions
  • Groups
  • Shared Configuration Resources
  • Subprocesses
  • Developing Process Definitions
  • Chapter4 Activities
  • Activity Overview
  • Activity Icons
  • Configuration
  • Advanced
  • Event
  • Editor
  • Table6 Content types for schema elements
  • Input
  • Mapping and Transforming Activity Input Data
  • Output
  • Process Starters
  • Misc Tab
  • Start Activity
  • Output Editor
  • End Activity
  • •Configuration
  • •Input Editor
  • Input Editor
  • Error Schemas
  • Chapter5 Transitions and Conditions
  • Creating a Transition
  • Conditions
  • Chapter6 Grouping Activities
  • Overview of Groups
  • Activity Output and Groups
  • Group Configuration Tab
  • No Action Groups
  • Overview of Loops
  • Index Variable
  • Accumulate Output
  • Iterate Loop
  • Iteration Element
  • Repeat Until True Loop
  • Repeat On Error Until True Loop
  • Suspend If Still Error Option
  • Critical Section Groups
  • Synchronization Options
  • Usage Guidelines
  • Pick First Groups
  • Chapter7 Working With Variables
  • Overview of Variables
  • Global Variables
  • Advanced Variables Editor
  • Changing Global Variable Values at Runtime
  • Process Variables
  • •Activity Output
  • •Predefined Process Variables
  • Activity Output
  • Predefined Process Variables
  • Error Process Variables
  • User-Defined Process Variables
  • Memory Usage of Process Variables
  • Shared Variables
  • •Shared Variable
  • Shared Variable
  • Job Shared Variable
  • Configuring Shared Variables
  • Assigning and Retrieving the Variable’s Value
  • Synchronizing Access to Shared Variables
  • Chapter8 Mapping and Transforming Data
  • Overview of Mapping and Transformation
  • Process Data Panel
  • Activity Input Panel
  • Mapping and Transforming Process Data to Activity Input
  • Statements, Hints, and Errors
  • Buttons, Menus, and Icons
  • Toolbar and Right-Click Menu on the Input Tab
  • Icons for Schema Element Datatypes
  • Qualifier Icons
  • Specifying Constants
  • Date and Datetime Strings in Constants
  • Data Validation
  • Repairing Incorrect Mappings
  • Shortcuts
  • Right-Click Menu
  • Dragging to the Left
  • Cutting and Pasting
  • Automatic Testing
  • Example of Mapping Required, Optional, and Nillable Elements
  • Examples of Mappings
  • Using XPath
  • Setting an Element Explicitly to Nil
  • Merging Input from Multiple Sources
  • Converting a List Into a Grouped List
  • Merging Two Corresponding Lists
  • Coercions
  • XSLT Statements
  • Attribute
  • Choose
  • Comment
  • Copy
  • Copy-Contents-Of
  • Copy-Of
  • Element
  • For-Each
  • For-Each-Group
  • Generate Comment
  • Generate PI
  • If
  • Value-Of
  • Variable
  • Chapter9 XPath
  • XPath Basics
  • Addressing Schema Elements
  • Evaluation Context
  • Namespaces
  • Search Predicates
  • Testing For Nil
  • Comments
  • The XPath Formula Builder
  • Table14 XPath formula builder elements
  • String Representations of Datatypes
  • Date and Time Functions
  • Table15 Formatting characters in date or time strings
  • Chapter10Error Handling
  • Overview of Error Handling
  • The Error Process Variables
  • $_error Process Variable
  • $_error_<activityName> Process Variables
  • Error Propagation
  • Group Error Propagation
  • Called Process Error Propagation
  • Process Error Schemas
  • Chapter11Transactions
  • Overview of Transactions
  • Types of Transactions
  • JDBC
  • Multiple JDBC Connections In Transaction Groups
  • Configuring JDBC Transactions
  • Java Transaction API (JTA) UserTransaction
  • Configuring JTA UserTransaction Transactions
  • XATransaction
  • Configuring XA Transactions
  • Configuring Third-Party Transaction Managers
  • Transaction Recovery
  • Nested Transactions
  • Table17 Effects of nesting transaction groups
  • Summary of Transactions
  • Table18 JDBC transaction type
  • Table20 JTA UserTransaction type
  • Chapter12Process Instance Execution
  • Detecting Duplicate Process Instances
  • When to Perform Checkpoints
  • Specifying the Duplicate Key
  • Transactions and Duplicate Detection
  • Handling Duplicate Messages
  • Process Engine Properties for Duplicate Detection
  • Sequencing Process Instances
  • Example 1: Processing Orders As They Are Received
  • Example 2: Periodic Processing
  • Example 3: Handling Client Messages
  • Logging for Third-Party Components
  • Chapter13Inter-Process Communication
  • Overview of Inter-Process Communication
  • Data for Inter-Process Communication
  • Coordinating Inter-Process Communication
  • Specifying the Key
  • Timeouts for Notify and Wait
  • Database Storage for Wait/Notify/Receive Notification Information
  • Examples of Inter-Process Communication
  • Enforcing Order for Process Execution
  • Multiple Types of Incoming Events Resume a Running Process
  • Scalability With Incoming Events
  • Specific Protocol Requirements
  • Chapter14Testing Process Definitions
  • Overview of Testing
  • Breakpoints
  • The Test Panel
  • Process Instances During Testing
  • Loading Processes to Test
  • Creating Process Instances
  • Working With Process Instances
  • Stepping Through a Process
  • Colors in Test Mode
  • Test Mode Buttons and Menus
  • AppendixAWorking with a Revision Control System
  • Overview
  • Icons Used by RCS Projects
  • Deleting RCS Projects
  • File Sharing
  • •Preparing for File Sharing on Microsoft Windows on page216
  • •Preparing for File Sharing on UNIX on page216
  • •Using File Sharing on page216
  • Preparing for File Sharing on Microsoft Windows
  • Preparing for File Sharing on UNIX
  • Using File Sharing
  • Microsoft Visual SourceSafe
  • •Visual SourceSafe Setup on page218
  • Visual SourceSafe Setup
  • Using Microsoft Visual SourceSafe
  • Perforce Fast Software Configuration Management System
  • Prerequisites
  • Using Perforce
  • Figure47 Save Project Options for Perforce Version Control System
  • XML Canon
  • Features
  • Checking In and Acquiring Resources
  • Step 2: Check in the project
  • Viewing Revision Control Information
  • Table24 Revision control system information
  • Deleting XML Canon Projects
  • Tips and Tricks
  • Tips and Tricks for Using Version Control Systems
  • Access Rights on Resources
  • AppendixBCustom Engine Properties
  • Overview of Custom Engine Properties
  • Setting Custom Engine Properties for the Testing Environment
  • Setting Custom Engine Properties in Deployed Projects
  • Available Custom Engine Properties
  • Engine Properties
  • TIBCO Hawk Properties
  • Trace Properties
  • TIBCO Rendezvous Advisory Messages
  • HTTP Properties
  • JDBC Properties
  • JMS Properties
  • Mail Properties
  • Properties for Backwards Compatibility
  • AppendixCTIBCO Hawk MicroAgent Methods
  • Enabling TIBCO Hawk
  • TIBCO Hawk Microagent Methods
  • GetExecInfo
  • GetProcessDefinitions
  • GetStaticActivityInfo
  • GetProcesses
  • GetActivities
  • GetProcessStarters
  • GetProcessesExceptions
  • SuspendAll
  • ResumeAll
  • KillAllProcesses
  • SuspendProcess
  • ResumeProcess
  • KillProcess
  • SuspendProcessStarter
  • ResumeProcessStarter
  • ListTraceProperties
  • SetTraceProperty
  • ListInstrumentProperties
  • SetInstrumentProperty
  • ListAllRoles
  • ListUserDefinedRoles
  • GetProcessCount
  • GetMemoryUsage
  • stopApplicationInstance
  • DelayedStopApplicationInstance
  • GetStatus
  • OnProcessStatusChanged
  • OnProcessActivity
  • getHostInformation
  • ConfigureAllTracing
  • ConfigureActivityTracing
  • ConfigureProcessStarterTracing
  • ConfigureUserDefinedTracing
  • ConfigureRole
  • IsAllTracingEnabled
  • IsActivityTracingEnabled
  • IsProcessStarterTracingEnabled
  • IsRoleEnabled
  • ResetActivityStats
  • ResetProcessDefinitionStats
  • OnProcessAdded
  • OnProcessRemoved
  • _onUnsolicitedMsg

TIBCO® BusinessWorks Process Design Guide

Software Release 5.2.1 May 2005

Important Information
SOME TIBCO SOFTWARE EMBEDS OR BUNDLES OTHER TIBCO SOFTWARE. USE OF SUCH EMBEDDED OR BUNDLED TIBCO SOFTWARE IS SOLELY TO ENABLE THE FUNCTIONALITY (OR PROVIDE LIMITED ADD-ON FUNCTIONALITY) OF THE LICENSED TIBCO SOFTWARE. THE EMBEDDED OR BUNDLED SOFTWARE IS NOT LICENSED TO BE USED OR ACCESSED BY ANY OTHER TIBCO SOFTWARE OR FOR ANY OTHER PURPOSE. USE OF TIBCO SOFTWARE AND THIS DOCUMENT IS SUBJECT TO THE TERMS AND CONDITIONS OF A LICENSE AGREEMENT FOUND IN EITHER A SEPARATELY EXECUTED SOFTWARE LICENSE AGREEMENT, OR, IF THERE IS NO SUCH SEPARATE AGREEMENT, THE CLICKWRAP END USER LICENSE AGREEMENT WHICH IS DISPLAYED DURING DOWNLOAD OR INSTALLATION OF THE SOFTWARE (AND WHICH IS DUPLICATED IN THE TIBCO BUSINESSWORKS CONCEPTS). USE OF THIS DOCUMENT IS SUBJECT TO THOSE TERMS AND CONDITIONS, AND YOUR USE HEREOF SHALL CONSTITUTE ACCEPTANCE OF AND AN AGREEMENT TO BE BOUND BY THE SAME. This document contains confidential information that is subject to U.S. and international copyright laws and treaties. No part of this document may be reproduced in any form without the written authorization of TIBCO Software Inc. TIB, TIBCO, Information Bus, The Power of Now, TIBCO Rendezvous, TIBCO InConcert,TIBCO Administrator, TIBCO Adapter, and TIBCO BusinessWorks are either registered trademarks or trademarks of TIBCO Software Inc. in the United States and/or other countries. EJB, J2EE, JMS and all Java-based trademarks and logos are trademarks or registered trademarks of Sun Microsystems, Inc. in the U.S. and other countries. All other product and company names and marks mentioned in this document are the property of their respective owners and are mentioned for identification purposes only. This software may be available on multiple operating systems. However, not all operating system platforms for a specific software version are released at the same time. Please see the readme.txt file for the availability of this software version on a specific operating system platform. THIS DOCUMENT IS PROVIDED “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT. THIS DOCUMENT COULD INCLUDE TECHNICAL INACCURACIES OR TYPOGRAPHICAL ERRORS. CHANGES ARE PERIODICALLY ADDED TO THE INFORMATION HEREIN; THESE CHANGES WILL BE INCORPORATED IN NEW EDITIONS OF THIS DOCUMENT. TIBCO SOFTWARE INC. MAY MAKE IMPROVEMENTS AND/OR CHANGES IN THE PRODUCT(S) AND/OR THE PROGRAM(S) DESCRIBED IN THIS DOCUMENT AT ANY TIME. Copyright © 2001-2005 TIBCO Software Inc. ALL RIGHTS RESERVED. TIBCO Software Inc. Confidential Information

| iii

Contents

Figures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xiii Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xv Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xvii
Related Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xviii TIBCO BusinessWorks Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xviii Other Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xviii How to Contact TIBCO Customer Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xix

Chapter 1 Getting Started With TIBCO Designer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Welcome to TIBCO Designer. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 Starting TIBCO Designer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 Starting the Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 Startup Options. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 TIBCO Designer Administration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 TIBCO Designer Interface Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 Main Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 Project Panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 Palette Panel. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 Design Panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Configuration Panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Customizing the Display . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Choosing Panel Layout. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Choosing Palette Mode or Non-palette Mode. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Displaying Palettes in a Separate Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Working With User Palettes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 13 15 17 17

Documentation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

Chapter 2 Managing Projects and Resources. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Overview of Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Project Structure. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Using a Version Control System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Project Templates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20 20 21 21

Creating Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
TIBCO BusinessWorks Process Design Guide

iv

| Contents
Validating Projects. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 Saving Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 Saving a Project as a Template . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Project Settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Opening and Reopening Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 Adding Resources To Your Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 If Adding a Resource Results in an Error. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Deleting Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Tips and Tricks for Working With Projects. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

Chapter 3 Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Business Process Modeling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 TIBCO BusinessWorks Solves Enterprise Integration Problems. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 Overview of Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 Process Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 Transitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 Shared Configuration Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38 Subprocesses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 Developing Process Definitions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

Chapter 4 Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
Activity Overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 Activity Icons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 Configuration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 Advanced . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 Event . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 Editor. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 Mapping and Transforming Activity Input Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 Process Starters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 Misc Tab. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 Start Activity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Output Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 61 61 61

TIBCO BusinessWorks Process Design Guide

Contents v

|

End Activity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Input Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Error Schemas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

62 62 62 63 63

Chapter 5 Transitions and Conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Transitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 Creating a Transition. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68

Chapter 6 Grouping Activities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
Overview of Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72 Activity Output and Groups. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74 Group Configuration Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 No Action Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 Overview of Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80 Index Variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81 Accumulate Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81 Iterate Loop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82 Iteration Element. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83 Repeat Until True Loop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84 Repeat On Error Until True Loop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86 Suspend If Still Error Option . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87 Critical Section Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 Synchronization Options. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 Usage Guidelines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89 Pick First Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90

Chapter 7 Working With Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93
Overview of Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 Global Variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 Advanced Variables Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96 Changing Global Variable Values at Runtime. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97 Process Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Activity Output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Predefined Process Variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Error Process Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 User-Defined Process Variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Memory Usage of Process Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100

TIBCO BusinessWorks Process Design Guide

vi

| Contents
Shared Variables. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Shared Variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Job Shared Variable. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Configuring Shared Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Assigning and Retrieving the Variable’s Value. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 101 101 101 103

Chapter 8 Mapping and Transforming Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
Overview of Mapping and Transformation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Process Data Panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Activity Input Panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Mapping and Transforming Process Data to Activity Input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Statements, Hints, and Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Buttons, Menus, and Icons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Toolbar and Right-Click Menu on the Input Tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Icons for Schema Element Datatypes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Qualifier Icons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106 106 107 107 108 108 108 111 112

Specifying Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114 Date and Datetime Strings in Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114 Data Validation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115 Repairing Incorrect Mappings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117 Shortcuts. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Right-Click Menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Dragging to the Left . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Cutting and Pasting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Automatic Testing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Examples of Mappings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Using XPath . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Setting an Element Explicitly to Nil . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Merging Input from Multiple Sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Converting a List Into a Grouped List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Merging Two Corresponding Lists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Coercions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XSLT Statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Attribute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Choose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Comment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Copy. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Copy-Contents-Of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Copy-Of . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Element . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . For-Each . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . For-Each-Group . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119 119 119 120 121 124 124 124 126 131 134 137 141 141 142 142 142 142 143 143 143 144

TIBCO BusinessWorks Process Design Guide

. . . . . . . . . . . . Generate PI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169 Configuring JDBC Transactions . . . . . . . . 167 Overview of Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164 Process Error Schemas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Contents vii | Generate Comment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168 Types of Transactions . . . . . . . . . . . . . . . . . . . . . Search Predicates . . . . . If . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 151 String Representations of Datatypes . 172 172 174 176 Nested Transactions . . . . . . . 179 TIBCO BusinessWorks Process Design Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155 Chapter 10 Error Handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 168 JDBC . . . 161 Error Propagation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Configuring XA Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Testing For Nil. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 148 148 149 149 150 150 150 The XPath Formula Builder . . . . . . . . . . . . . . . . . . . . . 170 Configuring JTA UserTransaction Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Variable. . . . . . . . Namespaces. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169 Multiple JDBC Connections In Transaction Groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153 Date and Time Functions. . . . . . . . . . . . . . . . . . . . . . . . . . 163 Called Process Error Propagation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170 XATransaction . . . . . . . . . . . . . . . . . . . . . . . . . Transaction Recovery . 160 The Error Process Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Addressing Schema Elements . . 159 Overview of Error Handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Value-Of . . . . . . . . . . . . . . . . . Configuring Third-Party Transaction Managers . . . . . . . . . . . . . . . . . . . 160 $_error Process Variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162 Group Error Propagation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161 $_error_<activityName> Process Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144 144 144 145 145 Chapter 9 XPath . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164 Chapter 11 Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . 147 XPath Basics . . . . . . . . . . . . . . . . Evaluation Context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 169 Java Transaction API (JTA) UserTransaction . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Specifying the Duplicate Key . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192 Data for Inter-Process Communication . 193 Coordinating Inter-Process Communication . . . . . . . . . . . . . . . . . . . . . . 194 Timeouts for Notify and Wait . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Scalability With Incoming Events . . . . . . . . . . . . . . . . . . . . . . 194 Database Storage for Wait/Notify/Receive Notification Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Multiple Types of Incoming Events Resume a Running Process. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203 203 203 204 Stepping Through a Process. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Example 2: Periodic Processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200 Breakpoints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207 TIBCO BusinessWorks Process Design Guide . . . . . . . . . . Working With Process Instances . . . . . . . . . . . . . Sequencing Process Instances. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Process Engine Properties for Duplicate Detection . 195 Examples of Inter-Process Communication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184 185 185 186 186 187 187 188 188 189 Logging for Third-Party Components . . . . . . . . . . . . . . . When to Perform Checkpoints . . . . . . . . . . . . . . . . 206 Test Mode Buttons and Menus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Specific Protocol Requirements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183 Detecting Duplicate Process Instances. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201 The Test Panel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .viii | Contents Summary of Transactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Example 1: Processing Orders As They Are Received . . . . . . . . . . . . . . . . . . . . 190 Chapter 13 Inter-Process Communication . . . . . . . . . . . . . . . . 191 Overview of Inter-Process Communication. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Enforcing Order for Process Execution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194 Specifying the Key . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195 196 196 197 198 Chapter 14 Testing Process Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Creating Process Instances . . . . . . . . . . . . . . . . . . . . . 205 Colors in Test Mode . . . . . . . . . . . . . . . . . . . . . . . . . . . Handling Duplicate Messages . . . . . . . . . . . Transactions and Duplicate Detection . . . . . . . . . . . . . . . 202 Process Instances During Testing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199 Overview of Testing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Loading Processes to Test. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180 Chapter 12 Process Instance Execution . . . . . . . . . . . Example 3: Handling Client Messages . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Engine Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Mail Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234 Appendix B Custom Engine Properties . . . . . . . . . . . . . . . . . . 224 225 225 225 231 233 233 Tips and Tricks for Using Version Control Systems . . . . . . . . . . . . . . . . . . . . . . . . . . 213 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234 Access Rights on Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255 Enabling TIBCO Hawk . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Tips and Tricks . Viewing Revision Control Information . . . . . . . 241 241 242 244 246 247 249 250 250 251 Appendix C TIBCO Hawk MicroAgent Methods . . . . . . . . 221 Using Perforce . . . 222 XML Canon . . 219 Perforce Fast Software Configuration Management System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215 Deleting RCS Projects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . TIBCO Rendezvous Advisory Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Using File Sharing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215 File Sharing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Prerequisites. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Preparing for File Sharing on Microsoft Windows. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214 Icons Used by RCS Projects . . . . . . . . . . . . . . . . . . . . . . .Contents ix | Appendix A Working with a Revision Control System . . . . . . . . . . . . Trace Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Deleting XML Canon Projects. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216 216 216 216 Microsoft Visual SourceSafe . . . . . . . . . . . . . . . . . . . . . . . . . . 221 Prerequisites. 238 Setting Custom Engine Properties in Deployed Projects. . . . . . . . . . . . . . . . . . . . . . . 240 Available Custom Engine Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . JMS Properties . 237 Overview of Custom Engine Properties. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218 Using Microsoft Visual SourceSafe . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238 Setting Custom Engine Properties for the Testing Environment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Checking In and Acquiring Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 256 TIBCO BusinessWorks Process Design Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Features . . . JDBC Properties. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Preparing for File Sharing on UNIX . . . . . TIBCO Hawk Properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218 Visual SourceSafe Setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Properties for Backwards Compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . HTTP Properties. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ResetActivityStats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . IsProcessStarterTracingEnabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . DelayedStopApplicationInstance . . . . . . . . . . . . . . . . . . . . . . . . KillAllProcesses . . . . . . . . . . . . IsAllTracingEnabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ConfigureProcessStarterTracing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . OnProcessAdded. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . OnProcessActivity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ConfigureUserDefinedTracing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ListTraceProperties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . GetStaticActivityInfo. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . _onUnsolicitedMsg. . . . . . . . . . . . GetProcessStarters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ResumeProcessStarter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ResetProcessDefinitionStats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . SuspendProcessStarter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . SuspendAll. . . . . . . . . . . . . . .x | Contents TIBCO Hawk Microagent Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . OnProcessRemoved . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ResumeAll . . . . . . . . . . . . . SetTraceProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . GetProcessCount . . . . . . . . . . . ListUserDefinedRoles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ConfigureRole . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ListAllRoles . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . stopApplicationInstance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 256 256 257 259 259 261 262 264 264 265 265 266 266 267 267 268 268 268 269 269 270 270 271 271 272 272 272 273 274 274 275 275 276 277 277 277 278 278 279 279 280 280 280 281 TIBCO BusinessWorks Process Design Guide . . . . . . . . . . ResumeProcess. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . GetProcesses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . IsRoleEnabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . GetActivities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . GetExecInfo . . . . . . . . . . . . . GetProcessesExceptions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ConfigureAllTracing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . SetInstrumentProperty. . . . . . . . . OnProcessStatusChanged . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . KillProcess . . . . . . ListInstrumentProperties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . IsActivityTracingEnabled . . . GetMemoryUsage . . . . . . . . . . . . . . SuspendProcess . . . . . . . . . . . . . . . . . . . . . . . . . GetStatus . . . . . . . . . . . . . . . . . . . . . GetProcessDefinitions . . . getHostInformation. . . . . . . . . . . . . . . . . . . . . . ConfigureActivityTracing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283 TIBCO BusinessWorks Process Design Guide . . . . .Contents xi | Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

xii | Contents TIBCO BusinessWorks Process Design Guide .

. . 10 Palette panel changed depending on current selection . . . . . . . . . . 12 The three-panel view . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Assigning a value to a user-defined process variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Valid transitions . . . . . . . . . . . . . . . . . . 67 An invalid transition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . non-palette mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 122 The XPath formula builder . . 32 A business process flow of an example enterprise . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 Minimizing and maximizing groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 Layout options . . . . . . . . . . . . . . . . . . . . . . . . . 120 Examples of mapping required. . . 15 Palette mode vs. . . . . . . . . . . . . . . . . . . . . . . . . . 27 An example enterprise computing environment . . . . . and nillable elements . . . 67 The transition dialog. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 Adding a resource to a project . . . . . . . . . . . . . . . . . . . . . . .| xiii Figures Figure 1 Figure 2 Figure 3 Figure 4 Figure 5 Figure 6 Figure 7 Figure 8 Figure 9 Figure 10 Figure 11 Figure 12 Figure 13 Figure 14 Figure 15 Figure 16 Figure 17 Figure 18 Figure 19 Figure 20 Figure 21 Figure 22 Figure 23 Figure 24 Figure 25 Figure 26 Figure 27 Figure 28 TIBCO Designer startup panel . . . 40 Developing process definitions . . . . . . . . . . . . . . . 106 Mapper check and repair dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 The TIBCO Designer window. . . . . 14 Three-panel view with palettes selected . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118 Dragging to the left to change a hint to a statement . . . . . . . . . . . . . . . . . . . . . . . 9 Global variables in project panel . . . . . . . . . . . . . . . . . . . . . 100 An activity’s input tab . . . . . . . . . . . . . . 8 Project tree in the project panel . . . . . . . . . . . . . . . . . 33 A process engine creating process instances . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 A newly created process definition. . . . 151 TIBCO BusinessWorks Process Design Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 Startup panel Administration options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . optional. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74 Creating a process variable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 A main process calling a subprocess . . . . . . . . . . . . . . . . . . .

. . . . . 227 XML Canon Check In Dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219 Save Project Options for Perforce Version Control System . . . . . . . . . . . 163 Propagating errors from a called process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202 The test panel . . . . 164 The Error Schemas tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .xiv | Figures Figure 29 Figure 30 Figure 31 Figure 32 Figure 33 Figure 34 Figure 35 Figure 36 Figure 37 Figure 38 Figure 39 Figure 40 Figure 41 Figure 42 Figure 43 Figure 44 Figure 45 Figure 46 Figure 47 Figure 48 Figure 49 Figure 50 Figure 51 Figure 52 Creating an XPath formula . . . . . . . . . . . . . . . . . 196 Multiple event sources to continue a process . . . . . . . . . . . . . . . . 202 Multiple process instances in the test panel . . . . . . . . . . . . . . . . . . . . . . . . . 153 A simple error-handling procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229 Acquire failed . . . . . . . . . . . . . . . . 228 A project checked into XML Canon. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165 Example of process data for error schemas . . . . . . . . . . . . . . . . . . . . . 188 Example of periodic processing. 165 The Generate Error Configuration tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201 Setting a breakpoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231 TIBCO BusinessWorks Process Design Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . 197 Set BreakPoints dialog . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226 Browse for an XML Canon category . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189 Ordering incoming events . . . . . . . . . . . . . . . . . . . . . . . . . . . 160 Propagating errors from a group . . . 202 Process instance stopped at a breakpoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166 Example order-entry system . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223 XML Canon tab . . . . . . . . . . . . . . . 189 Example of handling incoming messages . . . . . . . . . 204 Save Project Options for Microsoft VSS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . 181 Colors in test mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180 JTA UserTransaction type . . . . . . . . . . . . . . . . . . 44 Activity icon elements. . . . . . . . . . . . . . . . 6 Example activities . . . . . . . . 235 Actions on locked resources . . . . . . . . . . . . . 111 Additional icons for hints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54 Process starters . . . . . . . . . . . . . . . . . . . .| xv Tables Table 1 Table 2 Table 3 Table 4 Table 5 Table 6 Table 7 Table 8 Table 9 Table 10 Table 11 Table 12 Table 13 Table 14 Table 15 Table 16 Table 17 Table 18 Table 19 Table 20 Table 21 Table 22 Table 23 Table 24 Table 25 Table 26 Startup panel Project options . . . . . . . . 151 Formatting characters in date or time strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235 TIBCO BusinessWorks Process Design Guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207 Test panel icons . . . . . . . . . . . . . . . . 52 Icons for schema datatypes . . . . . . . . . . . . . . 208 Revision control system information. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 Startup panel Administration options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 Input tab toolbar buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157 Effects of nesting transaction groups . . . . . . . . . . . 109 Icons for schema items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 Content types for schema elements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179 JDBC transaction type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 Group Configuration tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115 XPath formula builder elements . . . . . . . . . . . . . . . . . . . 231 Actions on resources that are not locked . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155 Example date and time format patterns . . . . . . . . . . . . . . . . . . . . . . . . . 180 XA transaction type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 Activities with Event tabs . . 206 Toolbar icons for testing . . . . . . . . . . . . . 113 Datatype validation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

xvi | Tables TIBCO BusinessWorks Process Design Guide .

easy to deploy solution for companies looking to integrate their enterprise computing environment and automate their business processes.| xvii Preface TIBCO BusinessWorks is a standards-based. This manual describes how to create process definitions using TIBCO BusinessWorks. page xix TIBCO BusinessWorks Process Design Guide . Topics • • Related Documentation. page xviii How to Contact TIBCO Customer Support.

xviii | Preface Related Documentation You may find the following documentation resources useful. TIBCO BusinessWorks Installation Read this manual for information on installing one or more components of TIBCO BusinessWorks and setting up a TIBCO BusinessWorks domain. TIBCO Designer is an easy to use graphical user interface for design-time configuration of TIBCO applications. TIBCO BusinessWorks Quick Start This manual steps you through a very simple example of designing. This document also contains lists of known issues and closes issues for this release. TIBCO Administrator is the monitoring and managing interface for new-generation TIBCO products such as TIBCO BusinessWorks. TIBCO BusinessWorks Release Notes Read the release notes for a list of new and changed features. This manual describes terminology and concepts of TIBCO BusinessWorks. and monitoring a TIBCO BusinessWorks process. TIBCO Designer includes online help for each palette. TIBCO BusinessWorks Documentation In addition to this manual. and the other manuals in the documentation set assume you are familiar with the information in this manual. • • • • • Other Documentation TIBCO BusinessWorks is bundled with other products. TIBCO BusinessWorks Palette Reference This manual describes each of the palettes available in TIBCO BusinessWorks. TIBCO BusinessWorks Error Codes This manual describes errors returned by TIBCO BusinessWorks. TIBCO Adapter product documentation • • TIBCO BusinessWorks Process Design Guide . the following documents are part of the TIBCO BusinessWorks documentation set: • TIBCO BusinessWorks Concepts Read this manual before reading any other manual in the documentation set. TIBCO Administrator documentation. deploying. You will therefore find the documentation for those products useful: • TIBCO Designer documentation.

visit this site: http://www. visit this site: http://support.com Entry to this site requires a username and password. please contact TIBCO Support Services as follows.tibco.jsp • If you already have a valid maintenance or support contract. and information about getting started with TIBCO Product Support.tibco.com/services/support/default. If you do not have a username. you can request one. TIBCO BusinessWorks Process Design Guide . • For an overview of TIBCO Support Services.How to Contact TIBCO Customer Support xix | How to Contact TIBCO Customer Support For comments or problems with this manual or the software it addresses.

xx | Preface TIBCO BusinessWorks Process Design Guide .

This chapter and the next give an introduction to TIBCO Designer that is product independent. page 3 TIBCO Designer Administration. page 2 Starting TIBCO Designer. You drag and drop components into a project and then specify configuration information for each component. In the next chapter. you learn about creating and managing projects and working with global variables. page 6 Customizing the Display. page 6 TIBCO Designer Interface Overview. page 13 Documentation. you learn about TIBCO Designer basics. Product-specific information is available in the product-specific manuals. In this chapter. page 7 TIBCO Designer Administration.|1 Chapter 1 Getting Started With TIBCO Designer TIBCO Designer is an easy to use graphical user interface for creating ActiveEnterprise integration projects. page 18 TIBCO BusinessWorks Process Design Guide . Topics • • • • • • • Welcome to TIBCO Designer.

measure their efficiency. Adapters are available as separate products. The product facilitates complete visibility into business activities. TIBCO BusinessWorks also includes an engine that executes the process. deploy. TIBCO BusinessWorks Workflow uses TIBCO Designer for configuration of FormFlows processes and for preparing Enterprise Archive files. Custom adapters are created using the TIBCO Adapter SDK. You can prepare an adapter configuration for custom adapters using the Adapter Resources and Adapter Schemas palettes. and run integration projects. TIBCO BusinessWorks Process Design Guide . for example. and optimize them over time. • • • This chapter describes starting TIBCO Designer and explains the basic navigation model. TIBCO Designer is used for adapter configuration. along with the ability to collaborate on the modeling and modification of the rules and flows that define business those activities. and a web-based GUI for monitoring and managing run-time components. • TIBCO BusinessWorks is a scalable. TIBCO Designer is the graphical user interface (GUI) for defining business processes.2 | Chapter 1 Getting Started With TIBCO Designer Welcome to TIBCO Designer TIBCO Designer allows you to easily create integration projects for your enterprise computing environment. and the TIBCO ActiveEnterprise environment. which are discussed in the TIBCO Designer Palette Reference. Adapters allow you to configure the interface between an external system.. use TIBCO Designer to create TIBCO BusinessWorks process definitions or create or modify adapter configurations. Depending on the product you installed. and easy to use integration platform that allows you to develop. you can. TIBCO Designer is available as a GUI (Graphical User Interface) to different TIBCO products and is used by those products for configuration. TIBCO BusinessWorks Workflow gives companies the ability to coordinate business activities. such as an SAP R/3 applications or a database. extensible.

TIBCO BusinessWorks).g. Startup Options When you launch TIBCO Designer. Windows 1. you may be able to access TIBCO Designer via the Start menu option for that product (e. Navigate to the <tibco_core_home>/designer/<version>/bin directory. Type . See Startup Options on page 3. Click Start>Programs>TIBCO>Designer_version If you have installed TIBCO Designer palettes for another TIBCO product. See Startup Options on page 3./designer 3. UNIX 1. 2. 2. Select one of the Startup Options. Starting the Program Start TIBCO Designer using the steps for the platform you are using.Starting TIBCO Designer 3 | Starting TIBCO Designer The following sections describe how to start TIBCO Designer and explain the options available once TIBCO Designer starts. Select one of the Startup Options. the startup panel is displayed: TIBCO BusinessWorks Process Design Guide .

choose Edit>Preferences>General and unselect Show save dialog for new project. Table 2.4 | Chapter 1 Getting Started With TIBCO Designer Figure 1 TIBCO Designer startup panel Table 1 describes the startup options. TIBCO BusinessWorks Process Design Guide . Table 1 Startup panel Project options Option New empty project Description Opens a new empty project in TIBCO BusinessWorks. An empty project includes the TIBCO Designer default palettes and their resources. By default when you open a new project. You may provide the location or click the Cancel button. describes the options available when you select the Administration tab. Startup panel Administration options. TIBCO Designer prompts you immediately where you wish to save it. If you do not want to see this dialog each time you create a new project.

this panel reappears when no other TIBCO Designer windows are open. If unchecked. Allows you to choose from a list of recently saved projects. Web Services configuration. Using a template makes it possible to leverage an existing configuration when creating new projects. May prompt for information. If checked. Exit Show this panel only on startup Exits TIBCO Designer. After that. TIBCO Designer remembers the location even if you uninstall the current version and install a new version. It can contain folders. You may be prompted for your browser if you are using TIBCO Designer for the first time on a machine. Leaving the panel on screen can be useful for project maintenance.Starting TIBCO Designer 5 | Table 1 Startup panel Project options Option New project from template Description Opens a predefined project template. the startup panel is only displayed during startup and closed after you’ve made your selection. TIBCO BusinessWorks Process Design Guide . See Saving a Project as a Template on page 24 for information on creating project templates. Information on browser locations on some operating systems is included in the prompt screen. a password. Resources are the components of each project (see Resources on page 10). and partially configured resources. for example. A project template can be preconfigured to include all the resources you may need for a certain type of project such as. Note: You need to specify this path only once. A project template is a pre-built project. Allows you to delete a project. See Deleting Projects on page 28. configured resources. Displays TIBCO Designer documentation. See Opening and Reopening Projects on page 25. Open existing project Reopen project Delete project Help Opens an existing project.

you must convert to a multi-file project before you can open a project from TIBCO Designer. the panel presents the choices shown in Figure 2: Figure 2 Startup panel Administration options Table 2 Startup panel Administration options Option Convert DAT to files Description Displays a dialog that lets you specify the .dat files are a legacy format.6 | Chapter 1 Getting Started With TIBCO Designer TIBCO Designer Administration When you start TIBCO Designer.dat file you wish to convert and the folder for the multi-file project. When you select the Administration tab. TIBCO BusinessWorks Process Design Guide . Because . You can also use the startup panel to perform some TIBCO Designer administrative tasks. the startup panel allows you to open projects (see Startup Options on page 3).

User Directory—Default location for the application to store files. Maximum Heap Size—Maximum JVM heap size.zip and . When you specify both. Command Line Arguments—Allows command line arguments to be passed to Designer. See TIBCO Designer User’s Guide for more information. Currently -d (debug) is supported. You have these options: • Extended Class Path—classpath to be used by TIBCO Designer. . TIBCO BusinessWorks Process Design Guide .jar files will be loaded. Users can specify file names or directories. Allows you to configure the TIBCO Designer runtime environment. Palette Path—Location from which TIBCO Designer loads palettes. Displays the Preferences dialog. the log that is sent to the Console becomes more detailed. This section describes the TIBCO Designer main window and explains what you see in each of its panels. If they specify directories then all . The order in which they are loaded depends on the file system.class. If you specify -d. • • • • TIBCO Designer Interface Overview The TIBCO Designer interface allows you to perform various functions.dat file. TIBCO Designer converts the multi-file project in the directory to the .dat file.TIBCO Designer Interface Overview 7 | Table 2 Startup panel Administration options Option Convert files to DAT Configure preferences Configure runtime Description Displays a dialog that lets you choose a project directory and a .

When you select an item in the design panel or the configuration panel. • Four panels. Figure 3 The TIBCO Designer window Menu bar Toolbar Tabs Design panel Project panel Palette panel Configuration panel The TIBCO Designer window has these components: • • • Menu bar and Menus. See Customizing the Display on page 13. Tabs in the leftmost area allow you to change what is displayed in the panel. For example. This helps you see at one glance where the focus is. which are (starting in the top left corner and continuing clockwise): — Project panel (can display the project tree or the project’s global variables) — Design panel — Configuration panel — Palette panel You can rearrange the panels and what they display. See TIBCO Designer User’s Guide. the project panel and palettes can be combined to share one set of tabs. TIBCO BusinessWorks Process Design Guide . See Customizing the Display on page 13 for more information.8 | Chapter 1 Getting Started With TIBCO Designer Main Window Figure 3 illustrates the TIBCO Designer window. See TIBCO Designer User’s Guide. Toolbar icons. the panel is highlighted.

Figure 4 illustrates an example project. Figure 4 Project tree in the project panel ProcessNewComputer project Global Variables Display Global variables are associated with each project. the project panel allows you to view the Project Display or Global Variables Display. Multiple TIBCO products were used to create the integration project — it contains two TIBCO BusinessWorks process definitions (ProcessOrder and ProcessSoap) and a Siebel adapter (SBLAccount). and deployment information. the panel may be used for other purposes. Project Panel A project contains resources that implement the enterprise integration. in conjunction with the TIBCO BusinessWorks tester. ProcessNewComputer. TIBCO BusinessWorks Process Design Guide . any business logic that may be applied to that information. By default. for example. click the Global Variables tab of the project panel. Project Display With the Project tab selected.TIBCO Designer Interface Overview 9 | The following sections explain the contents of each panel. This includes the top-level (root) folder and the hierarchy of resources. the project panel displays the project tree. in the project panel. When used in conjunction with other project. See Global Variables on page 94 for more information. This includes services (producers and consumers of information). The hierarchy of folders and resources corresponds to the hierarchy of folders and files in the project folder. To display them.

each adapter configuration) corresponds to a file in the hierarchy of files in the project directory. such as an adapter configuration. a process definition. an adapter service. For example. thus sharing their work. much like a folder can contain other folders on your computer's file system. or an FTP activity. TIBCO BusinessWorks Process Design Guide . A simple TIBCO Designer resource corresponds to an object in a TIBCO application. This design allows developers to use a source control system and to check out only the top-level resources they are working with from a source control system.10 | Chapter 1 Getting Started With TIBCO Designer Figure 5 Global variables in project panel Resources Resources are the components of a project. Resources can be complex and contain other resources. Each top-level resource (for example. an adapter configuration may contain multiple folders with multiple publisher or subscriber service resources.

for example. TIBCO BusinessWorks Process Design Guide . that the palette for that resource is not installed. If you open a Designer project that was under source control without the revision control system. source control systems may hide files from the user.TIBCO Designer Interface Overview 11 | Most resources have context-sensitive help available for the configuration of that resource. TIBCO Designer contains a small number of native palettes. Right-click on the resource and choose What Is This? from the popup menu for more information on configuring the resource. the current selection in the project tree determines which palettes are displayed in the palette panel. each TIBCO application you install adds one or more palettes during installation. these files will become visible and treated as unknown resources. Which palettes are displayed depends on: • • • the installed TIBCO products the resource selected in the project tree your preferences (see Customizing the Display on page 13) Current Selection and Palette Panel Display When the default view is set as your view preference. that the file is not really part of your project. You select resources in the palette panel and drag and drop them into the design panel to add them to your project. If TIBCO Designer cannot determine the type of a resource. This can mean. For example. or that it has a misleading extension. Palette Panel Palettes organize resources and allow you to add them to your project. it displays it as a special icon. In addition.

its contents is displayed. The type and the purpose of the selected resource determine the contents of the configuration panel. See Customizing the Display on page 13 for more information about how TIBCO Designer functions in palette mode. Select the Adapter Services folder of an adapter in the project tree to see a palette of service resources. You can click the question mark (?) in the top right corner of the configuration panel for online help on the current selection. Design Panel The design panel displays the current resource selected in the project panel. if you select a folder.12 | Chapter 1 Getting Started With TIBCO Designer Figure 6 Palette panel changed depending on current selection Top-level folder selected Adapter Services folder selected For example: • • Select the top-level project folder to see a palette for each adapter and some other palettes for general resources. Drag any service resource into the design panel to add that resource to that adapter. The tabs organize the configuration options for the resource. Usually there are one or more tabs in the configuration panel that allow you to access the various configuration options. the contents of the selected resource are shown in the design panel. TIBCO BusinessWorks Process Design Guide . Configuration Panel The configuration panel allows you to specify various configuration options for each resource. You can change your view preferences to change what’s displayed in the palette panel. For example. For resources that contain other resources.

you must click the Apply button for each tab. Display preferences are maintained for each user. Customizing the Display You can customize how TIBCO Designer displays panels and palettes. Display preferences and other preferences are saved when you exit TIBCO Designer. you can set TIBCO Designer to display the three-panel view shown in Figure 7. To return to the default settings. click Reset before you apply any changes to return to the previous values for each field in the tab. TIBCO BusinessWorks Process Design Guide .Customizing the Display 13 | After you have added the configuration information. even if you do not save your project. This section gives an overview of the most frequently used display preferences. select Edit > Preferences and click Restore Default Settings. Choosing Panel Layout If you prefer to view either the project tree or the palette panel. but not both in the left panel. If you decide you do not want to add the configuration information. even if that user completely uninstalls the product and installs a different version.

2. select the appropriate icon and click OK. click the Palettes tab on the left (see Figure 8).14 | Chapter 1 Getting Started With TIBCO Designer Figure 7 The three-panel view Project panel Design panel Configuration panel To choose the three-panel view: 1. Choose Edit>Preferences>View. The next diagram shows the results of this action. Under Layout. To navigate to palettes in this view. Figure 8 Three-panel view with palettes selected Select Palettes TIBCO BusinessWorks Process Design Guide .

each resource is shown in the palette it belongs to. resources are displayed directly in the panel. unusable resources are grayed out. TIBCO BusinessWorks Process Design Guide . In that case. In non-palette mode. and only currently usable resources are displayed.Customizing the Display 15 | Additional layout options are available when you choose Edit > Preferences > View. Figure 9 Layout options Choosing Palette Mode or Non-palette Mode TIBCO Designer allows you to change the palette panel display to use palette mode or non-palette mode. and each palette shows all resources. • • In palette mode. Figure 10 illustrates the palette panel in palette mode and non-palette mode.

non-palette mode Palette mode All resources display in each palette Non-palette mode Only currently usable resources display Close box To switch palette modes: • Choose Palettes>Options>Switch Palette Modes or • Click the Switch Palette Modes button located in the tool bar.16 | Chapter 1 Getting Started With TIBCO Designer Figure 10 Palette mode vs. TIBCO BusinessWorks Process Design Guide .

3. To redisplay a closed palette. You can also access this menu command from the right-button menu of any palette in the palette panel. choose Palettes > Options> Show Close Boxes. if you closed the Adapter Resources palette. When you later save your project. Specify the name of the palette. Drag resources from the project tree or from the design panel into the user palette. Displaying Palettes in a Separate Window You can display the palette panel in a separate window by choosing Palettes > Options > Show Palettes in New Window. follow these steps: 1. To restore the palette panel to its location in the main window. TIBCO BusinessWorks Process Design Guide . choose Palettes > General > Adapter Resources to redisplay it. you can close individual palettes using the Close marker (X) on the right. Choose Palettes > My Palettes > New Palette. Creating User Palettes To add a user palette. 2. For example. Working With User Palettes User palettes allow you to save a collection of resources to a predefined location and either share it with other users or use it yourself at a later time. If Close markers are not visible.Customizing the Display 17 | While in palette mode. choose Palettes. then select the palette either from the top-level menu or from the submenu. the palette is saved to the location specified by the User Palette Directory General Preference. close the separate window in which the palette panel is displayed.

2. — Right click on most resources and choose the What Is This? menu item to view specific help for that resource. From TIBCO Designer: — Use Help > Designer Help at any time to view this manual. You only need to supply this location once. follow these steps: 1. you can also choose the Help button for online help. If information is displayed in the Configuration panel. Location information for many operating systems is included in the prompt. Place the palette in the directory specified by the User General Preference.18 | Chapter 1 Getting Started With TIBCO Designer 4. you are prompted for the location of the HTML browser. — Use Help > Help For to access the product-specific documentation. Deleting User Palettes To delete a user palette. Palette Directory Documentation Documentation for TIBCO BusinessWorks is available in several ways: • • If you are using Microsoft Windows. 2. Choose Palettes > My Palettes > Reload Palettes. When you save your project. you can use the Start menu to access TIBCO Designer documentation. which discusses how to use TIBCO BusinessWorks regardless of the application you are building. Loading User Palettes To load a user palette that was previously created. the custom palette is then saved to the location specified by the User Palette Directory General Preference. Make sure the palette is loaded. follow these steps: 1. You are prompted for the palette(s) you wish to delete. Choose Palettes > My Palettes > Delete Palettes. When you invoke Designer help for the first time. TIBCO BusinessWorks Process Design Guide .

page 21 Validating Projects.| 19 Chapter 2 Managing Projects and Resources Projects are the key organizational principle for the configuration information you specify with TIBCO BusinessWorks. page 22 Saving Projects. page 29 TIBCO BusinessWorks Process Design Guide . page 28 Tips and Tricks for Working With Projects. page 23 Opening and Reopening Projects. This chapter explains how to manage projects and the resources inside them. Topics • • • • • • • • Overview of Projects. page 20 Creating Projects. page 25 Adding Resources To Your Project. page 26 Deleting Projects.

TIBCO Designer removes any existing files before placing the project files into the folder. these resources define the configuration of your integration project. In the TIBCO BusinessWorks window. a project is represented by the top-level (root) folder in the project panel. For example. TIBCO Designer opens a new window. Each TIBCO Designer window contains only one project. All components of a project are located under this common project root.20 | Chapter 2 Managing Projects and Resources Overview of Projects A project is a collection of resources. more resources may be considered part of a top-level resource. For adapters. adapter resources and process definitions. Project Structure When you save a project. — Other folders. However. The project root can be located anywhere in the file system and is determined when you first save the project. such as the Adapter Services folder inside an adapter configuration are logical folders. Directories in the file system become folders in TIBCO Designer. For TIBCO BusinessWorks. The actual data for these elements is stored in the file of the top-level resource. that may mean one file per activity. If you open a second project. When you create a multi-file project: • There is one file per top-level resource. be sure no other files reside in that folder. The project root directory identifies the project. not all folders in TIBCO Designer are directories in the file system: — Folders created from a Folder resource in the General Palette (displays a multi-folder icon) become folders in the file system. The top-level folder is initially named Untitled and is renamed to the name of the project when you save the project for the first time. TIBCO Designer creates a hierarchy of folders and files in the location you choose for the project. including for example. When you close a project. When you supply a project location. Adapter Services data is stored in the Adapter Configuration file. Together. These folders only exist in memory in the resource that holds them. • • TIBCO BusinessWorks Process Design Guide . the startup panel remains available for project maintenance or for opening a different project unless you selected the Display this window only on startup check box on that window.

dat in the project root directory when you first save the project. and description. standard version control system tools can be used. configured resources. In that case. Once the root directory is defined under the control of a version control system. Using a template. you can leverage your work when performing similar configurations. and partially configured resources. TIBCO BusinessWorks allows you to create a new. Project Templates A project template is a pre-built project. It can contain folders for organization. The following version control systems are supported and discussed separately: • • • File Sharing on page 216 Microsoft Visual SourceSafe on page 218 Perforce Fast Software Configuration Management System on page 221 Support for other version control systems will be provided in future releases. TIBCO BusinessWorks Process Design Guide . TIBCO Rendezvous encoding. This file can be used for identification in place of the project root directory and can be used as the repository locator string (repoUrl). Creating Projects You create a new project using the startup panel when starting TIBCO BusinessWorks. Using a Version Control System Multi-file projects support the use of different version control systems because they consist of separate files for each versionable component. This file is used to store properties such as display name. blank project or to create a project based on an existing template. You can also choose Project > New Project from the TIBCO Designer menu bar with TIBCO Designer already open. You can use a project template as the foundation for other projects similar in nature.Creating Projects 21 | • TIBCO Designer creates a file named vcrepo. TIBCO Designer opens a new window for the new project.

do one of the following: • • Choose Project > Validate Project for deployment.22 | Chapter 2 Managing Projects and Resources • New Empty Project — A new project contains a single AESchemas folder that will be used for adapter schema resources. do one of the following: • • Select the resource to be validated. you add resources to it and supply configuration information for your resources. • When you create a new project. Validating Projects After you have created a project. See Project Templates on page 21. then choose Resources > Validate Resource from the menu bar. hand it to another user. you can later load that template and customize it to create a new project. Before you save a project. TIBCO BusinessWorks Process Design Guide . See Validating Projects on page 22 for some additional information on the behavior of resources included with TIBCO Designer by default. See Saving Projects on page 23 for a discussion of the information you must supply. See Project Structure on page 20 for more information. This is essential if you intend to run the project. choose the Validate icon. each resource always checks for broken references. With the resource selected. Click the Validate Project icon. it is critical that you validate it. During validation. Project from Template — When you save a project as a template (Project > Save As Template). Many resources have other resource-specific validation behavior. etc. To validate resource. TIBCO Designer includes reference-checking and other validation facilities that allow you to make sure a project is internally consistent. To validate all resources in a project. you are by default prompted immediately to save it.

possible to have "broken" references. do one of the following: — Choose Project>Save. Warning: Designer will remove any files in this directory when you save the project. make sure the Multi-File selected and provide the following information: Project Directory Project tab is Directory that will contain the project files. 2. TIBCO BusinessWorks Process Design Guide . and so forth). Click Browse to select the directory. In the dialog that is displayed. — Choose Project>Save As and specify the storage directory. follow these steps: 1. You can change the default behavior using the Edit>Preferences >References tab. for example. when you move a resource to a different location. In the main window. TIBCO Designer prompts whether you wish to perform reference checking each time you perform an activity that might result in a broken reference (move. rename. TIBCO Designer will help keep these references up to date. You can use the validation commands to find broken references. however. By default. if you delete a resource and ignore the warnings displayed by TIBCO Designer. It is. for example.Saving Projects 23 | Note that TIBCO Designer handles references as strings. Saving Projects To save a project. — Click the Save icon.

See Working with a Revision Control System on page 213 for more information. or if the project is running as a legacy local file-based project. Choose Project>Save As Template. The communication transport could be either TIBCO Rendezvous or TIBCO Enterprise for JMS. • Note: After deployment. except for English and western European languages. Click OK. Perforce. follow these steps: 1. Multi-User System Allows you to use a multi-user system such as file sharing. If this encoding is used for languages that do not belong to the Latin-1 character set (such as Japanese. This includes most languages. UTF-8—The preferred encoding for projects dealing with languages that do not belong to the Latin-1 character set.24 | Chapter 2 Managing Projects and Resources Message Encoding Character Encoding used for the communication between TIBCO product components in this project at design time (debug mode). You have two choices: • ISO8859-1 (Latin-1)—Should be used for projects that deal only with English and other Western European languages that belong to the ISO Latin-1 character set. which is the same as discussed in Saving Projects on page 23. you can select the Project Settings tab to: TIBCO BusinessWorks Process Design Guide . and so on). data loss may result. this encoding will be superseded by the encoding setting of the TIBCO Administration Server. Provide the appropriate information. Project Settings Once you have saved a project to a repository. or Visual SourceSafe. 2. 3. Saving a Project as a Template To save a project as a template. Arabic.

choose DAT to Files.Opening and Reopening Projects 25 | • • View information about the project. If you need to open a . You can reopen a project you opened recently in two ways: TIBCO BusinessWorks Process Design Guide . it may result in data loss in the data communication among TIBCO components. 2. In the Startup panel. Supply the name of the project directory when prompted. Working with a Revision Control System. You can then open the multi-file project from TIBCO Designer. View and change the project’s messaging encoding for the data communication among the components in this project. In that case. you need to provide the appropriate information. This is only used in design mode. The information displayed depends on how the project was saved. These include almost all the languages except for English and western European languages. you must convert it first: 1. After deployment. — UTF-8. See Appendix A. This should be used for projects that deal only with English and other western European languages that belong to ISO Latin-1 character set. If this encoding is used for languages not belonging to the Latin-1 character set (such as Japanese. this encoding setting is superseded by the encoding settings of TIBCO Administration Server. Opening and Reopening Projects You can open a project in two ways: • • From the startup panel when you launch TIBCO BusinessWorks. The preferred encoding for projects dealing with languages not belonging to the Latin-1 character set. or when the project is running as a legacy local file-based project. If you are opening a project under a version control system.dat project. Arabic. and so on). TIBCO Designer will create a new window for your project. Choose Project>Open from the TIBCO BusinessWorks main window if Designer is already open. You have two choices: — ISO8859-1 (Latin-1).

Select a resource in the palette and drag and release it in the design panel. The configuration panel allows you to specify configuration information for the resource. Select the palette in which the resource can be found. For example. you first select it in the palette panel. Choose Project>Reopen from the TIBCO BusinessWorks main window if Designer is already open. To add a resource to your project. follow these steps: 1. TIBCO BusinessWorks Process Design Guide . you can add resources to your project.26 | Chapter 2 Managing Projects and Resources • • From the startup panel when you launch TIBCO BusinessWorks. you find an adapter configuration resource in the palette named after the adapter. TIBCO Designer will create a new window for your project Adding Resources To Your Project Once you have created or opened a project. The resource instance is displayed in the design panel and also added to your project tree. Figure 11 illustrates adding a resource to a project. 2. If the palettes are not visible in your palette panel. then drag and drop it into the design panel. To add a resource. click the Switch Palette Modes icon. In that case.

an error results. If you try to add a resource that cannot be added to the current resource. TIBCO BusinessWorks Process Design Guide . In the design panel. If Adding a Resource Results in an Error Whether adding a resource is possible depends on what is currently displayed in the design panel.Adding Resources To Your Project 27 | Figure 11 Adding a resource to a project Drag into design panel You can also add resources in other ways: • • In the palette panel. select the resource and choose Add This To The Project from the right-button menu. choose Add Resource from the right-button menu and choose the appropriate submenu.

Usually. start it. Deleting Projects You do not delete projects from the TIBCO Designer main window but from the startup panel. any user with access to a project can delete the project. if the root folder is displayed in the design panel.28 | Chapter 2 Managing Projects and Resources For example. you cannot add the adapter instance. some custom palettes do not conform to this rule. To delete a project. — For other version control systems you must make sure that both the (local) project directory and the directory you specify for the version control system are correct. choose the Administration tab. TIBCO BusinessWorks Process Design Guide . If any other resource is displayed. You cannot delete projects based on XML Canon from TIBCO Designer. In the panel that appears: a. To delete such a project. Specify the project directory b. The startup panel is displayed unless Show this panel only on startup has been checked. follow these steps: 1. To access the startup panel: • • If TIBCO Designer isn’t running. 3. you must use a WebDAV client. 2. close all windows. However. you can add an adapter instance. In the startup panel. Click Delete Project. — For File Sharing. If TIBCO Designer is running. Specify a version control system if the project was used in conjunction with a version control system. all resources that cannot be dragged into the design panel should be greyed out (palette mode) or not visible (non-palette mode). You must also be sure to specify a user that has appropriate privileges for deleting the project.

place schema files under /AESchemas when possible. • Use ASCII project names. scalar. • • TIBCO BusinessWorks Process Design Guide . See Global Variables on page 94 for more information. you do so at your own risk. class. Place schema in the AESchemas folder. however. and a project name must use ASCII. ALso. Note.Tips and Tricks for Working With Projects 29 | Tips and Tricks for Working With Projects This section contains additional information on using multi-file projects. Do not place a multi-file project and a single-file project into the same directory. Use Global Variable groups to allow multiple developers to work on global variables simultaneously. and so forth). The project root folder name corresponds to the project name. For simplicity. If you edit your project file in an XML editor and define schema outside the /AESchemas folder. • Consider using global variable groups. Use an ASCII name for the project when saving the project from TIBCO Designer. union. Avoid naming collision. you must place schema files into /AESchemas if you wish to edit your project using TIBCO Designer. the schema are placed in a directory called __NON__DEFAULT__SCHEMA__FOLDER__ in /tibco/public/<type> where type is the kind of object (that is. Note that while editing schema files is not prohibited. that an excessive amount of global variables (over 500) can lead to problems. Each group has its own file in the multi-file project.

30 | Chapter 2 Managing Projects and Resources TIBCO BusinessWorks Process Design Guide .

This chapter describes how to create business processes in TIBCO BusinessWorks. page 38 Subprocesses. page 39 Developing Process Definitions. page 38 Shared Configuration Resources. page 37 Groups. page 36 Transitions.| 31 Chapter 3 Processes TIBCO BusinessWorks allows you to graphically model your business processes and execute them automatically. page 35 Activities. page 32 Overview of Processes. Topics • • • • • • • • • Business Process Modeling. page 34 Process Definitions. page 40 TIBCO BusinessWorks Process Design Guide .

the flow of information and processing between each application is what drives the day-to-day operations of the business. Also. the order-entry application receives and processes orders based on availability information taken from the inventory system. The tracking system relies on order information and shipping information. Figure 12 illustrates an example enterprise computing environment with various systems running in different environments. Figure 12 An example enterprise computing environment Inventory Order Entry Shipping Manual Data Transfer Reporting Tracking TIBCO BusinessWorks Process Design Guide . accurate and up-to-date reporting information is required from all systems. For example.32 | Chapter 3 Processes Business Process Modeling Most businesses choose the best application or environment for processing each component of their core business. In a typical enterprise.

THEN IF credit check approved. inventory. shipping. TIBCO BusinessWorks Process Design Guide . tracking. Also. sometimes known as a workflow. THEN PROCESS ORDER ELSE HOLD ORDER ELSE DENY ORDER ELSE RESTOCK INVENTORY REPORT ORDER STATUS Inventory WHEN qty < 5 of prod_id 798 RESTOCK INVENTORY PROCESS INVENTORY CHECK REPORT INVENTORY STATUS Shipping WHEN orderIDStatus == complete SHIP ORDER REPORT SHIPPED ORDER STATUS Tracking CHECK ORDER STATUS CHECK INVENTORY ITEM STATUS Reporting GET SHIPPED ORDER REPORT GET INVENTORY REPORT GET REVENUE REPORT GET UNUSED INVENTORY REPORT The business process flow describes an integrated enterprise that contains order-entry. Tying together different systems from different vendors that run in different environments is a labor-intensive and error-prone process that usually takes months of planning and implementation. THEN IF priority order. because the task of creating the custom business logic is so complex.Business Process Modeling 33 | Many companies implement the business rules that tie the systems together using custom-written code or by manual processes. Figure 13 illustrates a business process flow. Figure 13 A business process flow of an example enterprise Order Entry IF available. that describes the business rules between the various systems in an enterprise. These business rules in themselves can involve complex processing and automating these processes is crucial to lowering the total cost of operating the complete enterprise environment. TIBCO BusinessWorks Solves Enterprise Integration Problems An ideal solution for handling business process automation would be a tool that can handle the different environments and applications and allow you to create programmatic business rules easily. These rules are characterized by business processes. such as the REPORT SHIPPED ORDER STATUS process in the shipping system. paper-based processes instead of automating the process for greater efficiency. Each of these systems have rules for processing incoming data and more rules for passing data between the systems. and reporting systems. That tool should also allow you to automate your business processes for the greatest efficiency. businesses often rely on manual.

34 | Chapter 3 Processes TIBCO BusinessWorks allows you to model business processes with a graphical tool. Once the business rules have been specified. BusinessWorks can help you specify the business logic and automate the processing of the interaction between the systems in your enterprise. A process engine creates instances of process definitions. allowing you to easily automate the critical functions of your business. You develop and test process definitions using TIBCO Designer. BusinessWorks can execute the business processes. This allows you to reduce the time to implement an integrated. Overview of Processes A process definition is the graphical representation of your business process. You can use the BusinessWorks process definition palette to diagram complex business logic easily. and process instances. These process instances automate your business processes by executing the business process described by the process definition. Figure 14 illustrates the relationship between process definitions. The process definition is executed by a TIBCO BusinessWorks process engine. a process engine. TIBCO BusinessWorks Process Design Guide . enterprise-wide computing environment and ultimately lower the cost of deploying and maintaining the system.

You create process definitions by dragging and dropping a Process Definition resource from the Process palette to the design panel. see the TIBCO Administrator User’s Guide. The palette panel contains a set of activity palettes for use in the process definition. TIBCO BusinessWorks Process Design Guide . Selecting the process definition in the project panel changes the palette panel and the design panel to allow you to create your business process model. For more information about deploying a project. Process Definitions A process definition is a graphical representation of your business process model.Process Definitions 35 | Figure 14 A process engine creating process instances Machine A TIBCO Designer Project Process Definition A TIBCO BusinessWorks Process Engine Process Instance A-1 Process Instance A-2 Process Definition B Process Instance B-1 Process Instance B-2 Process Instance B-3 Process engines are started using TIBCO Administrator after you deploy your project. The design panel displays the business process model. The remainder of this manual describes how to create the process definitions that eventually become running process instances. Newly created process definitions contain a Start activity and an End activity. Figure 15 illustrates a newly created process definition.

Activities are generally operations that interface to external systems. Each palette has a set of activities that can be performed for that palette. See Developing Process Definitions on page 40 for a description of how to develop your process definitions.36 | Chapter 3 Processes Figure 15 A newly created process definition The process definition describes the business process. Activities are available on the various palettes in TIBCO Designer. For example. When the process definition is executed. Activities Activities are the individual units of work in a process definition. but activities can also perform internal processing. Process definitions consist of these components: • • • • • Activities Transitions Groups Shared Configuration Resources Subprocesses The following sections describe these components. the Adapter palette has activities that can publish messages to a specified adapter or invoke an operation by way of an adapter. TIBCO BusinessWorks Process Design Guide . it is known as a process instance. There is also an FTP palette that can invoke the PUT and GET commands on an FTP server.

also known as process starters. See TIBCO Administrator User’s Guide for more information about configuring the TIBCO BusinessWorks process engine. but some palettes contain activities that can start a process. You can have transitions from one activity to many other activities. The condition determines if the transition is taken when an activity completes processing. A transition can optionally specify a condition. not the concurrency of execution of activities. the Mail palette has a Receive Mail activity. Transitions and Conditions. Each activity in a process definition must have a transition to it. A process definition can begin with a Start activity. and you cannot draw a transition to a previously executed activity. If this is placed in a process definition. all transitions whose conditions are met are taken. Transitions Transitions describe the flow of processing in a process definition. After an activity completes. These activities.Transitions 37 | Activities are available to communicate with a variety of systems. Activities. or the activity is not executed when the process executes. it replaces the Start activity and a process instance is started when a mail message is received. Having multiple branches in a process definition does not imply that each branch is processed concurrently. on page 43 describes activities and their use in process diagrams. on page 65 describes transitions and conditions. Therefore. There is also a general-purpose Java code activity that allows you to write and execute standard Java code to perform custom processing in your process definition. For example. The arrows are unidirectional. you can have several branches of activity processing in your diagram. Chapter 4. TIBCO BusinessWorks Process Design Guide . Transitions describe control flow of the process definition. Chapter 5. Process execution is controlled by the process engine. begin a process when the specified event occurs. Control flow in a process definition must proceed sequentially beginning with the Start activity (or a process starter) and ending with the End activity. A transition is represented by an arrow between two activities.

Grouping Activities. this is similar to a try. but they are used when specifying the Configuration tab of some activities. To create sets of activities that participate in a transaction. • • Chapter 6. WSDL files. To create sets of activities that are to be repeated. The main uses of groups are the following: • To create a set of activities that have a common error transition. This allows you to have a set of activities with only one error-handling transition. Basically. or if an error occurs.catch block in Java. Shared configuration resources are created outside of process definitions. and connections to other servers. schema definitions. Activities in the group that can take part in a transaction are processed together. TIBCO BusinessWorks Process Design Guide . until a condition is true. These are resources. Shared Configuration Resources Shared configuration resources are specifications that are shared among activities. depending upon whether the transaction commits or rolls back.. TIBCO BusinessWorks Palette Reference describes shared configuration resources. or rolled back.. instead of trying to individually catch errors on each activity. You can repeat the activities once for each item in a list.38 | Chapter 3 Processes Groups Groups are used to specify related sets of activities. such as database connections. on page 71 describes groups and how to use them in a process definition.

the called process is known as a subprocess. Specify the input. and optionally allows you to spawn the subprocess into another process instance. the subprocess is spawned into a new process instance. When a subprocess spawns a new process instance. 4. Create a process definition that will call the subprocess. See TIBCO BusinessWorks Palette Reference for more information about dynamically calling subprocesses. and any error schemas of the subprocess on the Start and End activities in the subprocess. You can then call each process definition from another process definition. or you can dynamically determine which process to call when the process instance executes. Using subprocesses helps to make more readable process diagrams and you can reuse subprocesses across many process definitions. output. Place a Call Process activity (located on the General Activities palette) in the process definition. Normally. output. TIBCO BusinessWorks Process Design Guide . and the output of the subprocess is available to all subsequent activities in the process. follow this procedure: 1. Create a process definition for the subprocess.Subprocesses 39 | Subprocesses Business processes are often very complex and it is difficult to diagram the complete process in one process definition. Figure 16 illustrates a main process calling a subprocess. when necessary. 3. 2. See Start Activity on page 60 and End Activity on page 62 for more information about specifying the input. You can call specific processes. That is. they must begin with the Start activity. Subprocesses cannot have process starters. The Call Process activity allows you to map input values into the called process. See Developing Process Definitions on page 40 for more information about creating process definitions. To create and call a subprocess. not any activity that receives an event from an outside source. the parent process cannot access the called process’ output. You can create several smaller process definitions instead of one monolithic process definition. a subprocess executes in the same process instance as the calling process. When you call a process definition. If you select the checkbox in the Spawn field of the configuration tab of the Call Process activity. and error schemas of a process.

The End activity defines the outcome of the credit check as the output for the process. Developing Process Definitions Figure 17 describes the general procedure for developing process definitions. TIBCO BusinessWorks Process Design Guide . Subprocess Customer ID is defined as input on Start activity.40 | Chapter 3 Processes Figure 16 A main process calling a subprocess Main Process Pass customer ID to CreditCheck subprocess. The subprocess returns whether the customer has sufficient credit.

Activities. Select the activities that start the business process. JDBC URL and other information about the connection. This describes the username. 3. Configure the process starter activities. You can then use this connection in many process tasks that require a connection to a database. Drag these event sources from their palettes into the design panel. password. See Chapter 4. Name each process definition and give the process a description. if you are going to connect to a database. TIBCO BusinessWorks Process Design Guide .Developing Process Definitions 41 | Figure 17 Developing process definitions Create Shared Configuration Resources Create Process Definition Add Process Starter Add Activities Create Transitions Between Activities Specify Each Activity's Input Test/Debug/ Redesign The following is a more detailed description of how to develop process definitions: 1. select the HTTP activity palette. you should drag and drop a JDBC Connection into the design panel. Select one of the process definitions you created in Step 1 in the project panel. if you wish to start a process when an HTTP request is received. and drag and drop it into the design panel. 5. This causes a blank business process to appear in the design panel. See TIBCO BusinessWorks Palette Reference for more details about each of the shared resources. For example. Create one or more process definitions by dragging Process Definition resources from the process palette to the design panel. Create any Shared Configuration resources you will require for your process definition. For example. locate the HTTP Receiver process starter activity. on page 43 for more information about activities. 2. The business process has a Start and an End activity by default. These activities are known as event sources or process starters. 4. See the documentation for the activity you are configuring for more information about the fields on each of the tabs for the activity. These items are located in the Shared Configuration palette.

Click the transition button on the tool bar to draw transitions between activities. on page 65 for more information about specifying transitions. Test and debug your process definition until it operates as expected. 9. See Chapter 14. a TIBCO BusinessWorks engine is started to perform the processing described in the process definition. In testing mode. Mapping and Transforming Data. See Chapter 8. Drag and drop more activities to define the business process. Perform mapping and transformation of data for each activity’s input. on page 199 for more information about testing process definitions. on page 105 for more information about mapping and transforming data. 7. TIBCO BusinessWorks Process Design Guide . 8.42 | Chapter 3 Processes 6. use the test mode tool to enter testing mode. See Chapter 5. Once the process definition is complete. Testing Process Definitions. Transitions and Conditions.

page 62 TIBCO BusinessWorks Process Design Guide . This chapter describes activities and how to use them in a process definition. page 44 Activity Icons. page 45 Configuration. page 56 Output. page 47 Advanced. page 58 Process Starters. Topics • • • • • • • • • • • Activity Overview. page 60 End Activity. page 48 Event. page 50 Input. page 49 Editor.| 43 Chapter 4 Activities Activities perform the work in a process definition. page 58 Start Activity.

but activities can also perform internal processing. For example. the following activities are included in the ActiveEnterprise Adapter palette: Table 3 Example activities Activity Name Publish to Adapter Adapter Subscriber Respond to Adapter Request Function Sends a message to the specified adapter. Activities are generally operations that interface to external systems. The following are examples of palettes and some of the activities the palettes contain: • File — Create File — Remove File — Write File — Read File • FTP — FTP Put — FTP Get • JDBC — JDBC Query — JDBC Call Procedure — JDBC Update • Mail — Send Mail TIBCO BusinessWorks Process Design Guide . Receives a message from the specified adapter and starts a process.44 | Chapter 4 Activities Activity Overview Activities are the individual units of work in a process definition. Replies to a message sent by an adapter. Each palette has a set of activities that can be performed for that palette. Activities are available on the various palettes in TIBCO Designer.

such as HTTP requests or incoming TIBCO Rendezvous messages. this tab specifies the timeout for the incoming event and a condition to determine whether the incoming event is the correct one for the specific process instance. For example. this tab specifies the adapter service to use for an Adapter activity. Each activity usually has two or more of the following tabs for specifying the characteristics of the activity: • • • Configuration — Used for general configuration of the activity. There are some common elements of activity icons that represent the type of activity and the direction of data between the activity and the process. See the activity palette chapter for more information about the specific activity you wish to use. Input — The output data from all activities that precede this activity in the process definition is available for mapping to this activity’s input schema. There is a chapter for each available activity palette. TIBCO BusinessWorks Process Design Guide . the schema becomes available on the Input. Editor — A data schema for the activity. • • • The sections that follow describe each tab used to specify an activity. Once specified. Event — For activities that wait for incoming events. Output or both tabs of the activity. Table 4 describes the various elements in activity icons. See Start Activity on page 60 and End Activity on page 62 for more information about these activities. This is used when the input or output data is not known by the activity. These icons represent the function of the activity. Output — The activity’s data is output to activities that follow in the process definition. Advanced — Any advanced configuration parameters are specified here.Activity Icons 45 | When you are in a process definition in TIBCO Designer. and the user must specify their own schema. the activity palettes are available to drag and drop activities into the process definition. Activity Icons Each activity is represented by an icon in the palette and design panels. There are two activities that are included in a process definition by default: the Start activity and the End activity.

A green circle with an arrow inside (similar to a "Play" button on a media player) indicates the activity is a process starter. See Process Starters on page 58 for more information about process starters. also known as "Event activities" cause the process to suspend until the incoming event is received. Multiple arrows indicate either sending or receiving data. TIBCO BusinessWorks Process Design Guide . as opposed to performing an operation (see the description of single arrows below). In the example. the information is flowing from the process to the adapter (the adapter is represented by the purple and blue sphere). A yellow square with two parallel lines inside (similar to a "Pause" button on a media player) indicates the activity waits for an incoming event from the external system. These activities start new processes based on the receipt of an event from the external system.46 | Chapter 4 Activities Table 4 Activity icon elements Element Example Description Arrows indicate the direction of information between the process and the external system. These activities. See Event on page 49 for more information about Event activities.

the activity is sending a request to an adapter and expects to get a response from the adapter. In the Respond to Adapter Request activity example. the activity is sending a response to a previously received adapter request. In the Adapter Request-Response Server activity example. an FTP activity would contain specifications for the FTP session. sending a response. TIBCO BusinessWorks Process Design Guide . This is different from simply receiving a message or data (indicated by multiple arrows) because the activity is performing or responding to a remote operation call. The direction of the arrow indicates whether the activity is receiving a request.Configuration 47 | Table 4 Activity icon elements Element Example Description A single arrow going into or out of the external system indicates that the activity is performing a request. such as whether the type of data being sent is text or binary or whether the FTP server resides outside of a firewall. sending a response. or performing a request and receiving a response. In the Invoke an Adapter Request-Response activity example. the activity starts a process based on the receipt of a request from an adapter. For example. Configuration The configuration tab contains the general specifications for the activity. or sending a request and receiving a response. Required fields on the configuration tab are displayed in bold so that it is easy to see the minimum required information for configuration of an activity.

all activities allow you to specify a name for the activity and provide a short description on the Configuration tab. TIBCO BusinessWorks Process Design Guide . See the chapter for the palette you are interested in TIBCO BusinessWorks Palette Reference for more information about the Advanced tab of the activities in that palette. In general. Advanced The Advanced tab is available on some activities for specifying additional configuration options. See the chapter for the palette you are interested in TIBCO BusinessWorks Palette Reference for more information about the Configuration tab of the activities in that palette. Any other items on the configuration tab are the required configuration elements you must specify to make the activity work.48 | Chapter 4 Activities The following illustrates the configuration tab.

See Chapter 9.Event 49 | Event The Event tab is available on activities that expect an incoming event. on page 147 for more information about XPath expressions. the message waits indefinitely. and only data from the incoming event is available for use in this XPath expression. These are activities that wait for an incoming event in a process. If the event timeout expires. The amount of time a message will wait (in milliseconds) if it is received before this task is reached in the process. If no value is specified in this field. Event Timeout (msec) TIBCO BusinessWorks Process Design Guide . the event is discarded immediately. These activities cause the process instance to suspend until the incoming event is received. This expression is specified in XPath. unless this has already been reached. If zero is specified. an error is logged and the event is discarded. The following illustrates the Event tab. XPath. An Event tab has the following fields: Field Candidate Event Key Description Expression used to evaluate whether the incoming message is appropriate for this process.

TIBCO BusinessWorks Process Design Guide . For example. The specified file to change.. An adapter message or request. See the chapter for the palette you are interested in for more information about tasks that have Event tabs. An HTTP request.50 | Chapter 4 Activities Table 5 describes the available activities with Event tabs. A TIBCO Rendezvous message.. The associated Notifiy activity to execute. such as for defining the output headers of an incoming HTTP request. This tab is useful when the data does not have a well-known structure. the Input Editor tab of the Publish Rendezvous Message activity allows you to define the schema for the message you wish to publish. Editor The Editor tab is used to specify a data schema for input or output of an activity. The data schema may also be for a more specialized use. The name of the Editor tab differs depending upon what the schema is used for. Either a JMS queue or topic message. Table 5 Activities with Event tabs Palette ActiveEnterprise Adapter Event Activities Wait for Adapter Message Wait for Adapter Request File General Activities HTTP JMS Wait for File Change Wait Wait for HTTP Request Wait for JMS Queue Message Wait for JMS Topic Message Manual Work Rendezvous Wait For Completion Wait for Rendezvous Message A manual task to complete. Waits For .

delete. To define a schema on this tab. The data in the schema then becomes available to other activities in the process definition. Field Content Description Defines the content of the element. The following illustrates the Schema tab. In this example. the schema appears on the appropriate tabs of the activity. or you can define a group of data elements on this tab.Editor 51 | You can use a simple datatype. Once defined. Then use the fields of the dialog to specify the datatype of each item. The other fields that apear depend upon which content type is selected. Name TIBCO BusinessWorks Process Design Guide . See Table 6 for more information about the content type. or move data items. the Schema tab is labeled Input Editor indicating this defines the schema for the activity’s input. The name of the element. You can also reference XML schema or ActiveEnterprise classes stored in the project. use the buttons above the schema tree to add.

Optional (?) — the data item is optional. Type in a stored XML schema you wish to reference. Other Fields for This Content Type Name Cardinality TIBCO BusinessWorks Process Design Guide . Table 6 Content types for schema elements Content Type Complex Element Description An element that contains other elements. Type The type of data. Data items can be specified as one of the following: • • • • Required — the data item is required and must be supplied when the process is called. Any of the datatypes described in Table 7. Repeating.52 | Chapter 4 Activities Field Cardinality Description The qualification for the data item. Schema Name Type Name Stored XML schema that contains the element or type you wish to reference. and it can contain other complex elements. Zero or More (*) — The data item is a list that has zero or more elements. One or More (+) — The data item is a list that has one or more items. This is like a structure in a programming language. The complext element can contain zero or more elements of other types. Repeating. Table 6 describes the potential content types for data elements. Can be any of the following: • • XML Type Reference — must locate the stored XML schema definition.

integer. you can reference an XML type. you can reference an XML type. or specify the TIBCO ActiveEnterprise Any dataype. An attribute with a specified datatype. Other Fields for This Content Type Name Cardinality Type Other fields depending upon the datatype selected Cardinality Schema Element Name Cardinality Type Other fields depending upon the datatype selected Cardinality XML Element Reference A reference to an element in a stored XML schema. The datatype of this element can be one of the sub-elements defined. Each item in the sequence is a structure of the sub-elements of this element.Editor 53 | Table 6 Content types for schema elements Content Type Element of Type Description An element with a specified datatype. A choice of elements. Choice Cardinality All Cardinality XML Group Reference Cardinality Schema Model Group TIBCO BusinessWorks Process Design Guide . Attribute of Type Sequence A sequence of elements. You can specify a scalar datatype (string. and so on). You can specify a scalar datatype (string. or specify the TIBCO ActiveEnterprise Any dataype. See TIBCO Designer documentation for more information about XML schema. integer. A reference to an XML group in a stored XML schema. and so on). The datatype of this element can be all of the datatypes of the sub-elements defined. See TIBCO Designer documentation for more information about XML schema.

Other Fields for This Content Type Cardinality Validation Table 7 describes the datatypes available for data. You can specify the type of string as one of the following: • • • • • • • • • • • • • • String Normailzed String Token Language Name NC-Name Q-Name Name Token Name Tokens ID ID ref ID refs Entity Entites TIBCO BusinessWorks Process Design Guide . You can use the Coercions button to supply a reference to the XML Element for this item when it appears in the input or process data.54 | Chapter 4 Activities Table 6 Content types for schema elements Content Type Any Element Description A reference to any XML Element. Table 7 Icons for schema datatypes Icon Description String or character value.

Boolean value. You can specify the size of the integer as one of the following: • • • • • • • • • • • • Byte Short Int Long Unsigned Byte Unsigned Int Unsigned Long Integer Positive Integer Negative Integer Non-positive Integer Non-negative Integer Floating point number. This can be any of the following datatypes: • • • • • • • • • Time Date Date & Time Duration Day Month Year Year & Month Month & Day TIBCO BusinessWorks Process Design Guide . You can specify the size of the schema item as float. double. or decimal.Editor 55 | Table 7 Icons for schema datatypes Icon Description Integer value. Date or Time.

The following illustrates the input tab. Sequence.56 | Chapter 4 Activities Table 7 Icons for schema datatypes Icon Description Base 64 or hexidecimal value. Represents a schema element that can be a reference to any XML Element. The Activity Input area lists the current activity’s required and optional input data. Container for other datatypes. Represents a schema element with the TIBCO ActiveEnterprise datatype any. Choice. Input The Input tab allows you to map and transform output data from the previous activities in the process (including the event that starts the process) to input data for the activity. Specifies that the schema element can be one of a specified set of datatypes. Any Element. TIBCO BusinessWorks Process Design Guide . You can use the Coercions button to supply a reference to the XML Element for this element. You can use the Coercions button to supply a datatype for this element. This element can be specified as any other datatype or a reference to an XML Type or AE Class. Any Type. The Process Data area contains the output from all of the activities that appear prior to the activity in the process definition. Signifies that the contained sub-elements are repeated in an ordered sequence. XML element or group reference. An HTTP Uniform Resource Identifier. Complex element.

In general. There are also several icons above the Activity Input area. on page 105 for more information about using the Input tab to create mappings between process data and the activity’s input. you click on the desired item in the available schema in the Process Data panel and drag the item to the desired item in the Activity Input panel. Mapping and Transforming Data. TIBCO BusinessWorks Process Design Guide . You can also specify constants (strings enclosed in quotes or numbers) for any input values. to create a mapping. you can click on the schema item in the Activity Input panel and type the constant or expression into the field.Input 57 | Mapping and Transforming Activity Input Data You can create mappings between the available output from previous activities and the current activity’s input. or you can specify conditions on the mappings. See Chapter 8. If you wish to type in a constant or expression. Table 10 on page 109 describes the icons and their function.

The activity output data is displayed for informational purposes only and cannot be modified or altered. For example. TIBCO BusinessWorks Process Design Guide . Process Starters Some activities are used to start a process when an event occurs. in the File palette. This name appears in subsequent activities input tabs.58 | Chapter 4 Output Activities The output tab displays the activity output schema. The following illustrates the output tab. This kind of activity is known as a process starter. When a process starter is placed into a process definition. it replaces the default Start activity. Table 8 describes the available process starters. and becomes the first activity in the process. You can only have one process starter in a process definition. This activity detects changes in a specified file and starts a process when the change occurs. there is an activity named File Poller. You will receive a warning if you attempt to add more than one process starter to a process definition.

See TIBCO Administrator User’s Guide for more information about deployment and specifying where process starters run. An HTTP request is received. Either a JMS queue or topic message is received.Process Starters 59 | When you deploy your project. you may wish to place all processes with a Receive Mail process starter on the same machine as the mail server so that the processes can poll the mail server more efficiently. File General Activities The specified file is created. The specified time interval occurs. A message or a request from an adapter is received.. For example. or deleted. Receive Notification HTTP JMS HTTP Receiver JMS Queue Receiver JMS Topic Subscriber Mail Rendezvous SOAP Receive Mail Rendezvous Subscriber SOAP Event Source TIBCO BusinessWorks Process Design Guide . A TIBCO Rendezvous message is received. You can start processes for one-time events or schedule processes to start on recurring time intervals. changed. A SOAP web services request is received. Mail for the specified user is received by the mail server.. Table 8 Process starters Palette ActiveEnterprise Adapter Process Starter Adapter Subscriber Adapter Request-Response Server File Poller Timer Starts a process when. you can place processes with different process starters on different machines. A corresponding Notify activity has executed.

See Chapter 9. and it is also available in the $_processContext process variable. Start Activity The Start activity is the first activity in a process definition (process starters replace the Start activity when they are used in a process definition). See Chapter 7. on page 147 for more information about XPath expressions. A process can be called from another process. XPath. on page 147 for more information about XPath expressions. See Chapter 9. Working With Variables. XPath. on page 183 for more information about controlling the execution order of process instances. The Start activity has the following tabs: • • Configuration Output Editor TIBCO BusinessWorks Process Design Guide . See Chapter 12. Process Instance Execution. Custom Id This field can contain an XPath expression that specifies a custom ID for the process instance. The Misc tab contains the following fields: Field Sequencing Key Description This field can contain an XPath expression that specifies which processes should run in order. and the Start activity is used to define the input expected by the process. on page 93 for more information about process variables. This ID is displayed in the View Service dialog of TIBCO Administrator.60 | Chapter 4 Activities Misc Tab All process starters have a Misc tab that allows you to configure features common to all process starters. Process instances whose sequencing key evaluates to the same value will be executed sequentially in the order in which the process instance was created.

See Editor on page 50 for a description of how to define a schema. and you can reference XML schema or ActiveEnterprise classes stored in the project.Start Activity 61 | • Output See Subprocesses on page 39 for more information about calling a process from another process. Configuration The configuration tab has the following fields. Once defined. Output The output for the activity is defined by the specified data elements on the Output Editor tab. Field Name Description Description The name to appear as the label for the activity in the process definition. You can define your own datatype on this tab. TIBCO BusinessWorks Process Design Guide . Any process that calls this process definition must supply the data specified on the Output Editor tab. Output Editor The Output Editor tab defines the data that the process is expecting as input. Short description of the activity. This data then becomes available to other activities in the process definition. the data specified on the Output Editor tab becomes the output schema of the Start activity.

Field Name Description Description The name to appear as the label for the activity in the process definition. Input Editor The Input Editor tab defines the data that the process will output. The End activity has the following tabs: • • • • Configuration Input Editor Input Error Schemas See Subprocesses on page 39 for more information about calling a process from another process. you may wish to have the called process process definition output data to the calling process.62 | Chapter 4 Activities End Activity The End activity is the last activity in a process definition. You can define your own datatype on this tab. You can then map data from other activities in the process to the End activity’s input. Once defined. TIBCO BusinessWorks Process Design Guide . Any process that calls this process definition will receive this data when the process call completes. When a process definition is called from another process. the data specified on the Input Editor tab becomes the input schema of the End activity. You can map data from the activities in the process to an output schema specified on the End process. Configuration The configuration tab has the following fields. This becomes the output of the process. Short description of the activity. and you can reference XML schema or ActiveEnterprise classes stored in the project. and this becomes the output of the process when the process completes. See Editor on page 50 for a description of how to define a schema.

See Editor on page 50 for a description of how to define a schema. See Chapter 10. each for use in specific error cases.End Activity 63 | Input The input for the activity is defined by the specified data elements on the Input Editor tab. Error Schemas The Error Schemas tab defines schemas to contain data for errors thrown by the process definition. Error Handling. and you can reference XML schema or ActiveEnterprise classes stored in the project. on page 159 for more information on error handling. You can define multiple schemas. You can define your own datatype on this tab. TIBCO BusinessWorks Process Design Guide .

64 | Chapter 4 Activities TIBCO BusinessWorks Process Design Guide .

page 68 TIBCO BusinessWorks Process Design Guide . page 66 Conditions. Topics • • Transitions.| 65 Chapter 5 Transitions and Conditions Transitions and conditions control the flow of activities in a process diagram. This chapter explains how to create transitions and specify conditions on those transitions.

Control flow in a process definition must proceed sequentially beginning with the starting activity and ending with the End activity. After an activity or group completes processing. See TIBCO Administrator User’s Guide for more information about configuring the TIBCO BusinessWorks process engine. you can have several branches of activity processing in your diagram. Process execution is controlled by the process engine. all transitions whose conditions are met are taken. and you cannot draw a transition to a previously executed activity. Therefore. not the concurrency of execution of activities. Figure 18 illustrates examples of valid transitions in a process. If you wish to perform looping. on page 71 for more information on groups). You can have transitions from one activity to many other activities. or the activity is not executed when the process executes. use groups to specify multiple executions of grouped activities (see Chapter 6. Figure 19 illustrates an invalid transition. A transition is represented by an arrow between two activities or groups of activities in a process definition. TIBCO BusinessWorks Process Design Guide .66 | Chapter 5 Transitions and Conditions Transitions Transitions describe the flow of processing. Transitions describe control flow of the process definition. Grouping Activities. The arrows are unidirectional. Having multiple branches in a process definition does not imply that each branch is processed concurrently. Each activity in a process definition must have a transition to it.

only if no other transitions are taken.Transitions 67 | Figure 18 Valid transitions One path from Start to End Two transitions from the Start activity form multiple paths If you have multiple branches in a complex process definition. only when an error is encountered. you may find the Null activity in the General Activities palette useful for joining the multiple branches into a single execution path. you may specify whether the transition is taken always. Creating a Transition To create a transition. See Conditions on page 68 for more information. or when a custom-specified condition based on process data values is true. follow this procedure: TIBCO BusinessWorks Process Design Guide . See TIBCO BusinessWorks Palette Reference for more information about the Null activity. Figure 19 An invalid transition You cannot transition to a previously executed activity A transition is taken depending upon the condition specified on the transition. When a transition is created.

2. 6. 5. Release the mouse button. 3. See Conditions on page 68 for more information about specifying conditions. TIBCO BusinessWorks Process Design Guide . Figure 20 illustrates the transition dialog. You can choose any of the following line types for your transition: — Default (straight line) — Straight — Multiple Bends — One Bend — Curved — S-Shaped Conditions Conditions are specified on transitions to determine whether to take the transition to the next activity or not. Drag the mouse until the cursor is positioned over the activity that you would like to transition to. 7. When a transition is created. First create or open a process definition that contains at least two activities. choose the line type and color for the transition. you are presented with the transition dialog. Click and hold the mouse button. Once the transition is created. Optionally.68 | Chapter 5 Transitions and Conditions 1. the condition dialog is presented. Position the cursor over the first activity. The condition dialog allows you to specify when this transition is taken. Click on the Create Transition icon on the TIBCO Designer toolbar. 4.

Conditions 69 | Figure 20 The transition dialog The transition dialog allows you to specify a label. XPath. but only if no other transitions are taken. If the activity completes successfully. on page 147 for more information about specifying XPath conditions and using the XPath formula builder. if the activity completes successfully. Condition Type Success Description Take this transition unconditionally. the transition is taken to the activity it points to. always transition to the activity the transition points to. and you can use the XPath formula builder to drag and drop XPath expressions and data into the condition. description. The following table describes each condition type. and the condition you create evaluates to true. That is. This is the default condition for transitions. See Chapter 9. and background color for the transition. You can also specify a condition type for the transition. This is useful when multiple transitions with conditions are drawn to other activities. line type. Success with condition Specify a custom condition using XPath. You can type in an XPath condition. This condition type can be used to handle any cases not handled by the conditions on the other transitions. Success if no matching condition Take this transition when the activity completes successfully. TIBCO BusinessWorks Process Design Guide .

There can be only one Error and one Success if no matching condition transition out of each activity. on page 159 for more information on error handling in process definitions.70 | Chapter 5 Transitions and Conditions Condition Type Error Description Take this transition if there is an error during processing of the activity. it is displayed on the transition line in the process definition if a label is not specified in the Label field. When a transition is created. See Chapter 10. the default condition type is Success. TIBCO BusinessWorks Process Design Guide . Error Handling. If a condition other than Success is specified.

page 88 TIBCO BusinessWorks Process Design Guide . page 72 No Action Groups. Topics • • • • • • • • Overview of Groups. page 84 Repeat On Error Until True Loop. error-handling. page 82 Repeat Until True Loop. page 86 Critical Section Groups. page 88 Critical Section Groups.| 71 Chapter 6 Grouping Activities This chapter describes groups and how to use them for transactions. page 79 Overview of Loops. and looping. page 80 Iterate Loop.

• • • • Activities can be grouped or ungrouped. 4.. See No Action Groups on page 79 for more information. See Chapter 11. 2. or click the Create a group icon. 3. Maximized groups can also be resized. Also. See Pick First Groups on page 90 for more information about this type of group. This allows you to wait for one or more incoming events and continue processing based on what incoming event was received first. draw a box around the desired activities. or rolled back. To specify that the first activity that completes should determine which transition(s) to take to continue processing. To create a critical section that synchronizes process definitions.. This allows you to collapse and expand groups in a process definition to better display the relevant portions of the process you wish to view. instead of trying to individually catch errors on each activity. Choose View>Create a Group from the menu. TIBCO BusinessWorks Process Design Guide . Activities in the group that can take part in a transaction are processed together. groups can be maximized to display all activities in the group or minimized to show only a small icon for the whole group. You can repeat the activities once for each item in a list. To create sets of activities that are to be repeated.72 | Chapter 6 Grouping Activities Overview of Groups Groups are used to specify related sets of activities. To create sets of activities that participate in a transaction. or if an error occurs. The group configuration appears in the configuration panel. Transactions. In the design panel. Choose the Select tool (the arrow pointer in the tool bar). perform the following procedure: 1. on page 167 for more information about transactions. until a condition is true. To group a set of activities. See Critical Section Groups on page 88 for more information about critical sections.catch block in Java. This allows you to have a set of activities with only one error-handling transition. depending upon whether the transaction commits or rolls back. The main uses of groups are the following: • To create a set of activities that have a common error transition — similar to a try. See Overview of Loops on page 80 for more information about loops.

Figure 21 illustrates minimizing and maximizing a group. click the down arrow in the upper right-hand corner of the group or double click anywhere in the group to minimize the group. double click the group icon to maximize the group. Draw a transition from the start of the group to the first activity to execute in the group. Draw a transition from the last activity to execute in the group to the end of the group.Overview of Groups 73 | 5. To ungroup a set of grouped activities. 3. The end of the group is the red end square on the right side of the group box. 7. For groups that are currently maximized. To minimize or maximize the display of a group. See Table 9 for more information about the fields of the group configuration tab. TIBCO BusinessWorks Process Design Guide . perform the following procedure: 1. Specify the type of group to create and any other configuration parameters required for the group. Choose the Select tool (the arrow pointer in the tool bar). The start of the group is the green start arrow on the left side of the group box. Choose View>Remove a Group from the menu. or click the Undo the group button. For groups that are currently minimized. Select the group in the design panel. 6. perform the following procedure: 1. 2. 2.

When a group has completed executing. TIBCO BusinessWorks Process Design Guide . 2. perform the following procedure: 1. In the case of loop groups. 3. any loop indexes for loops contained in loops are reset when the parent loop begins a new iteration. activity output in the group is reset so that activities in subsequent iterations of the group will not have access to output data from previous iterations. output from the activities in the group is available to subsequent activities in the process definition. Also. Choose the Select tool (the arrow pointer in the toolbar) and select the group in the process definition. only output from the last execution of the activity is available. if it is not already maximized. and so on). Activity Output and Groups Each activity in the group can access the output of previously executed activities inside or outside the group. Maximize the group. Click and drag the desired anchor point on any side or on the corners until the group is the desired size.74 | Chapter 6 Grouping Activities Figure 21 Minimizing and maximizing groups Click the down arrow or double click anywhere in a group to minimize a group that is currently maximized Double click a group to maximize a group that is currently minimized To resize a maximized group. If the group is used for a loop (iterate. repeat until true.

you can create a process variable and use the Assign activity in the loop to store or alter data for each iteration. Critical Section — See Critical Section Groups on page 88 for more information. • • TIBCO BusinessWorks Process Design Guide . For Iterate and Repeat Until True loops. Short description of the group. Repeat Until True Loop — See Repeat Until True Loop on page 84 for more information Repeat On Error Until True Loop — See Repeat On Error Until True Loop on page 86 for more information. Group Configuration Tab Table 9 describes the fields in the Configuration tab for groups. Table 9 Group Configuration tab Field Name Description Group Action Description The name to appear as the label for the group in the process definition. on page 167 for more information. Iterate Loop — See Iterate Loop on page 82 for more information. Transactions. • • • • • None — See No Action Groups on page 79 for more information. Groups can be of the following types. Transaction Groups — See Chapter 11. This list becomes the group’s output and the list is available to subsequent activities in the process definition. you can optionally accumulate the output of each execution of one activity in the group into a list. Pick First — See Pick First Groups on page 90 for more information.Group Configuration Tab 75 | If you wish to store data from each successive iteration of a loop. The type of group.

x. Iteration Element A name to use for the process variable containing the current iteration element of the data supplied in the Variable List field. See Iteration Element on page 83 for more information on this field. Accumulate Output TIBCO BusinessWorks Process Design Guide . Variable List A process variable containing the list you wish to use as the source of the iterations. Group Action: Iterate Index Name The index variable for the loop. See Accumulate Output on page 81 for more information. See Index Variable on page 81 for more information. Use the button to choose from a list of available process variables for this field. This variable will be used to store the current iteration number of the loop. The index starts at one and increments by one with each execution of the loop. Checking this field indicates that you would like activity output in a group to be handled using the TIBCO BusinessWorks 2.x semantics. activity output was not reset at the start of every iteration of a loop. Specifies that you wish to accumulate the output of each execution of one of the activities in the group into a process variable. Once a process variable is chosen.76 | Chapter 6 Grouping Activities Table 9 Group Configuration tab Field 2. activities in a loop could potentially see activity output from previous iterations of the loop. If you uncheck this field.x Compatibility Mode Description This field is only available for loop groups in process definitions that were migrated from TIBCO BusinessWorks 2. The group iterates once for each item in the list. In 2.x. activity output in loop groups behaves as described in Activity Output and Groups on page 74. Therefore. the correct XPath expression for that process variable is automatically entered into this field.

The condition is specified as an XPath condition and the XPath formula builder is available to help to create the condition. See Chapter 9. XPath. Conditions The condition that specifies when the loop should stop. The activity in a group for which you wish to accumulate output for each execution of the loop. If the condition evaluates to false. The loop continues to repeat until the condition evaluates to true. The index starts at one and increments by one with each execution of the loop. Output Activity Output Name TIBCO BusinessWorks Process Design Guide . The process variable to store the successive output of the selected activity in the Output Activity field. The name of the process variable to store the successive output of the selected activity in the Output Activity field. the loop stops. on page 147 for more information. You may select only one activity in the group. then the condition is checked. if the condition evaluates to true. the loop repeats.Group Configuration Tab 77 | Table 9 Group Configuration tab Field Output Activity Description The activity in a group for which you wish to accumulate output for each execution of the loop. You may select only one activity in the group. This variable will be used to store the current iteration number of the loop. Accumulate Output Specifies that you wish to accumulate the output of each execution of one of the activities in the group into a process variable. Output Name Group Action: Repeat-Until-True Index Name The index variable for the loop. The activities in the group are executed once. See Index Variable on page 81 for more information. See Accumulate Output on page 81 for more information.

on page 147 for more information. the loop repeats. Suspend (If Still Error) Suspends the process if the error still occurs when the specified condition is true. If the condition evaluates to false. the loop stops. the condition is checked. TIBCO BusinessWorks Process Design Guide . The index starts at one and increments by one with each execution of the loop.78 | Chapter 6 Grouping Activities Table 9 Group Configuration tab Field Description Group Action: Repeat-On-Error-Until-True Index Name The index variable for the loop. XPath. The condition is specified as an XPath condition and the XPath formula builder is available to help to create the condition. See Chapter 9. See Suspend If Still Error Option on page 87 for more information about this field. if the condition evaluates to true. This variable will be used to store the current iteration number of the loop. until the specified condition evaluates to true. See Index Variable on page 81 for more information. The loop continues to repeat if unhandled errors are encountered. The activities in the group are executed once. If an error occurs during the processing of the activities. and that error does not have an associated error transition. Conditions The condition that specifies when the loop should stop.

. you only need one error transition instead of an error transition for each activity..No Action Groups 79 | Table 9 Group Configuration tab Field Description Group Action: Critical Section Scope Defines the scope of the critical section group. • Lock Object The Lock shared configuration resource that synchronizes critical section groups across process definitions and potentially across process engines.catch block in Java. If you do not wish for the activities in the group to repeat. Multiple Group — specifies that all process instances for the current process definition and any other process definition with a critical section group specifying the same lock resource will be synchronized. specify the group action to be None. No action groups are primarily useful for specifying a single error transition out of the group so that if an unhandled error occurs in the group. you should select the Multiple Group option. This option requires the Lock resource to be specified in the Lock Object field. If you are synchronizing across multiple process engines. This behavior is similar to a try. TIBCO BusinessWorks Process Design Guide . No Action Groups You can group a set of related activities. • Single Group — specifies that all process instances in the same process engine for the current process definition will be synchronized on the current group. with a common set of transitions into and out of the group.

80 | Chapter 6 Grouping Activities The following process definition illustrates a no action group that has one error transition out of the group to process any unhandled errors that occur when the grouped activities execute. 2. or you can iterate if an error is encountered while processing. The contents of the file are used to create an HTTP request to a web server. If all activities in the group succeed. you can iterate until a given condition is true. The following are the types of loops that are available: • • • Iterate Loop Repeat Until True Loop Repeat On Error Until True Loop Iterate and repeat until true loops allow you to accumulate the output of a single activity in the loop for each execution of the loop. You can iterate based on the items in an array stored in the process data. The process performs the following operations: 1. This allows you to retrieve output from each execution of the activity in the loop. a TIBCO Rendezvous message is published so that an administrative application can be notified of the error. In the event of an error. A Write File activity writes the retrieved file so that its contents are available at a later time. an email message is sent. 4. TIBCO BusinessWorks Process Design Guide . 3. See Accumulate Output on page 81 for more information about accumulating the output of each iteration of a loop. An FTP Get activity retrieves a file from an FTP server. Overview of Loops Loops allow you to execute a series of activities more than once.

You can then choose the Java Code activity as the Output Activity to accumulate for each iteration of the loop. Because you can only select one activity in the Accumulate Output field. and each time the loop is executed. You can access this variable like any other process data by referencing it with a dollar sign ($) in front of it. For example. you can accumulate the output of one of the activities in a group by checking the Accumulate Output field. you may wish to use a Mapper activity in the loop to accumulate the output. the activity is executed and the output is added to the list before the condition is checked.Overview of Loops 81 | Index Variable The index variable holds the current number of times a loop has executed. you can use a Java Code activity to concatenate the data into the output parameters for the Java Code activity. Accumulate Output For iteration and repeat until true loops. if the index variable is i. this variable can be accessed in the same way other process data can be accessed by other activities. to accumulate ouptut from several activities. you can select one of the activities in the group. Therefore. you must use a different approach. you may want to accumulate a list of customer names from repeated executions of a JDBC Database Query task. if you choose to accumulate the output of the same activity used in the condition of a Repeat Until True loop. and you want to specify a condition that the loop should execute three times (for a repeat until true loop). Alternatively. The output for the selected activity is accumulated each time the activity is executed. the condition would be $i=3. In this case. the selected activity’s output is placed into a list. The Mapper TIBCO BusinessWorks Process Design Guide . After the loop exits. The list of accumulated output for that activity is stored in a variable whose name is specified in the Output Name field. Because you can accumulate output from only one activity in a group. The iteration count starts at one the first time the loop is executed. you should design your group so that only one activity in the group holds the data to accumulate for each iteration. For nested loops. If you check this field. or you may wish to accumulate the sum of the amounts for line items in an order. the index of the contained loop resets at the beginning of each iteration of the parent loop. One approach is to create a process variable to hold the data and use the Assign activity to assign values from each iteration of the loop to the process variable. For example. and the count increases by one for each iteration of the loop.

appending to the file as each record is written. The customer records are then passed to a group containing one activity. TIBCO BusinessWorks Process Design Guide . you can place a Mapper activity outside of the loop to strip out the unwanted value from the output list after the loop exits. WriteCustomerList. 2. Alternatively. The WriteCustomerList activity writes the name and address of each customer to a file. The group iterates once for every customer record returned by the QueryCustomer activity. A JDBC Query activity is used to query a database and populate a list of customer records. The list can be items of any datatype. 4.82 | Chapter 6 Grouping Activities activity is placed after the activity used for the condition of the loop so that the loop exits before the value is accumulated. The following is an example of an iterate loop. The process performs the following operations: 1. 3. Iterate Loop An Iterate loop repeats the series of grouped activities once for every item in an existing sequence or list. The process then reads the file that was written so that its data is available to the process. then transitions to a Send Mail activity to send the contents of the customer list by way of email. and transitions to the ReadCustomerList activity once the last record is processed.

For example. or your expression can be more complex and only process certain items in the list. You can use a simple expression containing a complete list as in the example above. Iteration Element The Iteration Element field on the Configuration tab allows you to supply a name for a process variable containing the current iteration element. the expression in the Variable List field would be the following: $QueryCustomer/Customer/Record[position() > 10] See Chapter 9. This allows you to easily map the value of the current iteration element instead of using predicates on the process variable used for iteration. When you specify a value for this field. if you wish to skip over the first 10 records returned. This causes the following to appear in the process data tree: TIBCO BusinessWorks Process Design Guide . a process variable with the specified name appears in the Process Data tree in the Input tab. on page 147 for more information on creating XPath expressions. in the Iterate group above. XPath. we specified curent-record as the name for the current element. The Variable List field is an XPath expression.Iterate Loop 83 | The following is the configuration for this example: In this example. For example. the repeating element $QueryCustomer/Customer/Record is used to determine the number of iterations to perform. One iteration is performed for every element contained in the repeating element.

The following is an example of a Repeat Until True loop. The activities are always executed once before checking if the condition is true. Repeat Until True Loop The Repeat Until True loop repeats the series of grouped activities until the given condition evaluates as true. The larger number of elements contained in the $QueryCustomer/Customer/Record repeating element. the current element being processed. and the loop exits when the condition evaluates as true. the condition is checked. $current-record/Record is a copy of the $QueryCustomer/Customer/Record[i] element. you save processes time in proportion to how many times the iteration loop repeats. By using the $current-record/Record element instead.84 | Chapter 6 Grouping Activities Notice that both $QueryCustomer/Customer and $current-record contain the element Record. After executing the series of activities. the greater the performance improvement you will notice by using $current-record/Record instead of $QueryCustomer/Customer/Record[i]. If you use $QueryCustomer/Customer/Record[i] in an input mapping. TIBCO BusinessWorks traverses the $QueryCustomer/Customer/Record element to retrieve the current element each time the loop iterates. The process performs the following operations: TIBCO BusinessWorks Process Design Guide .

the output of the QueryCustomer activity is placed into a variable named customerList. c. A Java Code activity that outputs all the valid customer IDs. the loop can exit. For each iteration of the loop. A Send Mail activity that uses the customer information retrieved from the database to send an email to the customer notifying the customer of new product offerings. The following is the configuration for this example Repeat Until True loop: TIBCO BusinessWorks Process Design Guide . The group consists of: a. 2. so the condition examines the value and when it is -1. When all valid IDs have been output. The Customer ID activity outputs -1 when there are no more customers. When the condition of the loop evaluates to true.Repeat Until True Loop 85 | 1. A JDBC Query activity that takes each ID and queries a database for the record matching the ID. A group of activities executes until the customer records have all been queried. b. the activity will output -1 to indicate no more records can be queried. the loop stops executing and transitions to the WriteCustomerList activity so that the customer list will be stored in a file. The condition evaluates the value of CustomerID/ID_num.

The contents of the file are sent by email. the condition of the loop is evaluated — if the condition is true. the loop terminates. specify a repeat on error until true loop with a condition that terminates the execution after five tries. The following illustrates a repeat on error until true loop. you may wish to execute a series of activities and retry the execution in the event of an unhandled error. if the condition is false. the loop repeats until there is no error occurs or the condition is true.86 | Chapter 6 Grouping Activities Repeat On Error Until True Loop The Repeat On Error Until True loop allows you to repeat a series of activities when an unhandled error occurs. 2. If there are no unhandled errors. However. 3. The process performs the following operations: 1. you wish to retry the execution only five times. TIBCO BusinessWorks Process Design Guide . to avoid an infinite loop if the error occurs repeatedly. The activities in the group are executed once. An FTP Get activity retrieves a file from an FTP server. For example. The contents of the file are written so the data is available at a later time. the loop terminates. In this case. If an error occurs for which there is no error transition.

the fifth iteration of the loop). or an adapter service may not have been started on the machine. The resulting behavior in this example is that the group of activities executes and loops until either a successful completion of all activities. The loop is entered again. the loop exits. or until the group is executed five times. the loop condition is checked as it normally would be. TIBCO BusinessWorks Process Design Guide .Repeat On Error Until True Loop 87 | The following is the configuration for this example loop: The condition is specified as $i = 5. and if an error occurs. Suspend If Still Error Option Repeat On Error Until True loops have the Suspend If Still Error option. the loop terminates if the condition evaluates to true. and all process variables are reset to their values before the loop was executed the first time. which means that when the index variable is equal to five (that is. the process instance resumes execution as if the Repeat On Error Until True loop had never executed. The suspended process is displayed by TIBCO Administrator. If an error is encountered. This option allows the administrator to correct the problem causing the error. the execution resumes before the Repeat On Error Until True loop. The process instance executes the loop. the process instance suspends if the error still exists when the condition of the loop is true. For example. After the problem is corrected. Therefore. When this option is checked. The condition is only evaluated upon encountering an unhandled error in the group. the administrator can resume the process execution. a machine may be down. and the deployment configuration allows you to specify an action to perform if the process is suspended. When a process instance resumes execution.

as well as information about how to view suspended processes and resume or kill them. Critical Section Groups Critical section groups are used to synchronize process instances so that only one process instance executes the grouped activities at any given time. perform the following: 1. Only one process instance at any given time will execute the activities contained in the Critical Section group. Specify Critical Section for the Group Action field. the process instance continues to be suspended. 3. For more information about deployment configuration and specifying actions to perform if processes are suspended. Any concurrently running process instances that contain a corresponding critical section group wait until the process instance that is currently executing the critical section group completes. see TIBCO Administrator User’s Guide. Critical Section groups are particularly useful for controlling concurrent access to shared variables (see Synchronizing Access to Shared Variables on page 103 for more information). TIBCO BusinessWorks Process Design Guide . or you can synchronize process instances for multiple process definitions. other situations may occur where you wish to ensure that only one process instance is executing a set of activities at a time. However. 2. Create a group around the activities you wish to synchronize. Synchronization Options Critical section groups can be used to synchronize all process instances for a particular process definition in a single process engine. Single Group If you wish to synchronize process instances for a single process definition in a single process engine. or you can synchronize process instances across multiple process engines.88 | Chapter 6 Grouping Activities If the error persists. Specify Single Group for the Scope field. The administrator can decide whether to resume or kill the process if the error cannot be fixed.

Create a group around the activities you wish to synchronize. 3. such as Request/Reply activities. Avoid nesting Critical Section groups. check the Multi-Engine field of the Lock resource. Perform steps 3 to 6 for any process definitions you wish to synchronize. there may be performance implications when using these groups. Usage Guidelines Because Critical Section groups cause many process instances to wait for one process instance to execute the activities in the group. 7. Make sure you specify the same Lock shared configuration object for all Critical Section groups. Create a Lock shared configuration resource and specify a name for the resource. 5. If you must use nesting. 4. When the process instances are executed across multiple engines. Specify Multiple Groups for the Scope field. 2. ensure that Lock shared configuration resources are used in the same order in all process definitions. and a database transaction is performed to ensure that only one process instance is executing the critical section group at any given time. put only a very few activities in a Critical Section group. • • TIBCO BusinessWorks Process Design Guide . locking is performed in memory. Use the Browse button in the Lock Object field to locate the Lock shared configuration resource you created in Step 1. When the process instances are executed by the same process engine. and only use activities that execute very quickly. you should use the following guidelines when creating critical section groups: • Keep the duration of a Critical Section group as short as possible. the process engines must be configured to use a database for storage. Do not include any activities that wait for incoming events or have long durations.Critical Section Groups 89 | Multiple Groups If you wish to synchronize process instances for multiple process definitions. 6. Deadlocks can occur if you do not specify the Lock resources in the same order in nested Critical Section groups for all process definitions. Wait For activities. To perform the synchronization across multiple process engines. perform the following: 1. Sleep activities. In general. or activities that require a long time to execute. That is. or if you wish to synchronize process instances across multiple process engines. Specify Critical Section for the Group Action Field.

or the Timeout activity. The first event that completes determines which transition to take to continue processing. the transition to the CancelOrder activity is taken. If the Timeout activity completes first. the order times out and cancels. For example. If either PollInventory or PollReturnedStock complete first. The first activity to complete determines the next transition taken. The group then waits for either the return message from PollInventory. a check is made to see if the order can be filled from stocked inventory or from returned merchandise. both the Lock and the Shared Variable shared configuration resources should have the Multi-Engine field checked. TIBCO BusinessWorks Process Design Guide . If neither system returns the information about available inventory. the return message from PollReturnedStock. Pick First Groups Pick first groups allow process execution to wait for one or more events. as part of an order-entry system. the transition to the ProcessOrder activity is taken. The following illustrates an example sub-process that uses the Pick First group to implement the business logic described above.90 | Chapter 6 Grouping Activities • When using Critical Section groups to retrieve or assign a value to a shared variable across multiple process engines. when an order is placed. The process is called and then a transition is taken to the Pick First group. You can use a global variable to ensure that the Multi-Engine field is set to the same value for both resources. Whichever system returns the information first is used to fill the order.

activities.. and activities that have the pause symbol can have valid transitions from the start of the Pick First group. Wait for . the activity is highlighted in green. If the transition is valid. Only request/reply. the activity is highlighted in red.Pick First Groups 91 | To specify the events that you would like to wait for. TIBCO BusinessWorks Process Design Guide .. draw transition lines from the start of the group to the desired activities. if the transition from the start of the group is drawn to an invalid activity.

92 | Chapter 6 Grouping Activities TIBCO BusinessWorks Process Design Guide .

page 101 TIBCO BusinessWorks Process Design Guide . page 94 Process Variables.| 93 Chapter 7 Working With Variables This chapter describes the various types of variables available in TIBCO BusinessWorks and how to use these variables in your process definitions. page 98 Shared Variables. page 94 Global Variables. Topics • • • • Overview of Variables.

unless the GUI does not allow you to make them settable later. then override the value for individual applications at deployment time using TIBCO Administrator. unless the GUI does not allow you to make them settable later. then override the value for individual services (for example. • TIBCO BusinessWorks Process Design Guide . Shared Variables — these variables allow you to specify data for use across multiple process instances.94 | Chapter 7 Working With Variables Overview of Variables There are several types of variables in TIBCO BusinessWorks. The values you specify are then used at runtime. each with their own purpose and usage. You can also create user-defined process variables for containing process-specific data. Because multiple process instances can access the same variable. Predefine a variable using TIBCO Designer. There are several ways in which they can be used: • Define a variable using TIBCO Designer. • • The following sections describe the types of variables available in your project in greater detail. TIBCO BusinessWorks provides the following types of variables: • Global Variables — these variables allow you to specify constants that can be used throughout the project. Process Variables — these variables allow you to access various data in your project. publication service or TIBCO BusinessWorks process) at deployment time using TIBCO Administrator. Global Variables Global variables provide an easy way to set defaults for use throughout your project. project name. You can also specify different values for each deployment of your project. there are predefined process variables containing the process ID. and other information. The constants can be specified and changed while designing and testing your project. You can also override values for predefined variables. You can also override values for predefined variables. you can also synchronize access across processes when setting or retrieving the shared variable. For example.

Specify the name of the group. Press Enter when you’re done. The project panel is updated to display all currently defined global variables. you could assign the value 7474 to the predefined global variable RvDaemon. The variable expands so you can change either the variable name or the variable value. They are especially useful if multiple developers share a project using a version control system. With the group icon selected. in-place editor for global variables or an advanced global variables editor (see Advanced Variables Editor on page 96). click the left-most icon. allow you to drag and drop global variables into the field. Global Variable groups are used for grouping variables. If you wish to change the TIBCO Rendezvous daemon for the adapter. then press Enter. you can globally set it to a different value. In the project panel.Global Variables 95 | For example. select the Global Variables tab. select that region and triple-click the variable. TIBCO Designer provides a simple. To use the simple global variables editor. Some fields in the configuration panel. you can click the abc icon to add variables to the group. follow these steps: 1. You can then use the variable in different sessions in an adapter. Advanced Editor Delete Add Global Variable Add Global Variable Group — To add a new global variable group. TIBCO BusinessWorks Process Design Guide . You now have these choices: — To assign or change a variable value. such as user name and password fields.

When the project is deployed and the configured components run. Service level variables are only included in the service archive if the service uses the variable. Advanced Variables Editor The Advanced Variables Editor is useful in the following cases: • • • When you need to make multiple modifications to substitution variables When you wish to mark variables as settable from TIBCO Administrator at runtime on a per-deployment basis (or not) When you wish to mark variables as settable on a per-service basis (or not). TIBCO BusinessWorks Process Design Guide . A new global variable item is added to the bottom of the list. the variable RvServiceTest is used as the service. optionally. you must also have marked the variable as settable at the service level. click the abc icon. enter the variable name surrounded by %% on both sides. RvServiceTest would be replaced with 7800. When you want to use the global variable in the fields of a resource. Press Enter when you’re done. For example. 2. In the illustration below. TIBCO BusinessWorks replaces all occurrences of the global variable name with the global variable value.96 | Chapter 7 Working With Variables — To add a global variable. TIBCO BusinessWorks includes all service-level variables regardless of usage. You may add definitions of any variables you need to the predefined variables. the value. In that case. Supply the variable name and. You can also drag from the Global Variable tree in the display into a text field in the configuration panel. See TIBCO Designer User’s Guide for information. TIBCO Designer provides anumber of default global variables. The Adapter Archive resource allows you to specifically force inclusion of selected service-level variables if there are problems with inclusion. — Right-button a global variable for a menu that allows you to edit or delete it.

— Change the datatype of the variable (by clicking on the type column). you can click the Deployment or Service check box to make that variable settable from TIBCO Administrator for each deployment or for each service. You can also specify values for global variables when starting a process engine on the command line. To do this. icon to add a variable. Click OK to exit the editor and save the new or modified variables. specify the following as a command line argument when starting the process engine: -tibco. you can: — Triple-click an item to edit it. follow these steps: 1. See the TIBCO Administrator User’s Guide for additional information. See the section on modifying runtime variables in the TIBCO Administrator User’s Guide for more information on using TIBCO Administrator. In the project panel. value is the value you wish to set the variable to. add the following argument to the command line when starting the process engine: -tibco. In the Advanced Editor. To use the Advanced Variables Editor.clientVar. 2. if you have a global variable named item1 contained in a folder named myGroup and you wish to set its value to 500. including the path to the variable if it is contained in a folder. select the Global Variables tab.<variablePathAndName> <value> where variablePathAndName is the name of the variable you wish to set. or add a constraint or description (by clicking on the associated column) — For each variable.myGroup/item1 500 TIBCO BusinessWorks Process Design Guide . For example. Changing Global Variable Values at Runtime You can change the value of a global variable when you deploy your project in TIBCO Administrator.Global Variables 97 | A variable that is settable on a per-service basis can be set for each adapter service or TIBCO BusinessWorks top-level process. then click the Open Advanced Editor (pen) icon. — Click the Add — Click the Add Variables Group a Variable icon to add a group of variables. 3.clientVar.

Predefined Process Variables There are two process variables that are available to all activities that accept input: $_globalVariables and $_processContext.98 | Chapter 7 Working With Variables Process Variables Process variables are data structures available to the activities in the process. $_processContext contains general information about the process. Activities can use output from previously executed activities by mapping data from the process variable to the activity’s input. See Global Variables on page 94 for more information about global variables. the project name. $_globalVariables contains the list of global variables defined on the Global Variables tab of the project. This allows you to use process data to supply input values for an activity. Also. such as the process ID. Activities have access to any data that is output from previously executed activities in the process definition. TIBCO BusinessWorks Process Design Guide . only global variables with well-formed XML names (for example. There are four types of process variables: • • • • Activity Output Predefined Process Variables Error Process Variables User-Defined Process Variables Activity Output Some activities produce output. and so on. See Input on page 56 for more information about the Input tab and mapping process data to an activity’s input. Only global variables that have the Deployment option checked (on the advanced editor dialog) are visible in the $_globalVariables process variable. Process variables are displayed in the Process Data panel of each activity’s Input tab. An activity’s output is placed into a process variable with the same name as the activity (with a dollar sign placed in front of the name to indicate it is a process variable). names containing a % are not well-formed) appear in the $_globalVariables process variable. Each process variable name starts with a dollar sign ($).

then you create its schema in the middle panel. See Chapter 10. on page 159 for more information about handling errors and error process variables. You add a process variable and give it a name in the left-most panel. You create a process variable in the same way you create data schemas for activities. Assign allows you to specify which process variable you wish to modify. the activity’s error variable is populated with the appropriate error schema. Error Handling. use the Assign activity. The $_error process variable contains general error information. Figure 23 illustrates assigning a value to a user-defined process variable. Figure 22 Creating a process variable To assign a value to a user-defined process variable. You can then specify a new value for the process variable in the Input tab of the Assign activity.Process Variables 99 | Error Process Variables When an error occurs in a process. Figure 22 illustrates creating a process variable. Activities can also have error process variables named $_error_<activityName>. In the event of an error. Process variables are defined on the Process Variables tab of the Process Definition resource. the data pertaining to the error is placed into process variables. Only user-defined process variables can be modified. TIBCO BusinessWorks Process Design Guide . User-Defined Process Variables You can define your own process variables and assign values to them in your process definition. See Editor on page 50 for more information about creating data schemas.

If no activities refer to the variable. on page 237 for more information about setting properties. Memory saving mode can reduce the memory used by actively running process instances. Custom Engine Properties.100 | Chapter 7 Working With Variables Figure 23 Assigning a value to a user-defined process variable When you use the Assign activity.<processname> property to true. See Appendix B. You can enable memory saving mode for all process instances by setting the EnableMemorySavingMode. TIBCO BusinessWorks Process Design Guide . Memory saving mode allows memory used by a process variable to be released when the value of the variable is no longer needed. That is. By default. and make sure to supply the correct values for all elements in the process variable. the list of process variables is evaluated to determine if subsequent activities in the process refer to the variable.* property to true. the entire contents of the process variable is replaced by the specified new contents. that element no longer contains a value at run time. See TIBCO BusinessWorks Palette Reference for more information about the Assign activity. memory saving mode is disabled. as each activity is executed. the memory used by the variable is released. but you can enable memory saving mode for specific process instances by setting the EnableMemorySavingMode. When using memory saving mode. Therefore. as well as potentially improve the performance of checkpoints. if you do not supply a value for an element in a process variable. use the Assign activity to reset the value of a process variable. Memory Usage of Process Variables All process variables in a running process instance are stored in memory and therefore consume system resources.

You can create a shared variable to hold the approval codes and create one process definition for setting the codes. You can use the Get Shared Variable and Set Shared Variable activities to access the data instead of mapping data to a called processes input or output schemas. A copy of the variable is created for each new process instance. Configuring Shared Variables You configure a shared variable by providing the following: • • • a name for the variable the schema of the data contained in the variable optionally. All process instances can read and update the data stored in a shared variable. an initial value for the variable TIBCO BusinessWorks Process Design Guide . you may have a set of approval codes for incoming orders that change daily for security purposes.Shared Variables 101 | Shared Variables A shared variable is a shared configuration resource in the General Activities palette. but its scope is limited to the current job. This type of shared variable is useful if you wish to pass data across process instances or if you wish to make a common set of information available to all process instances. if a called process has the Spawn configuration field checked. so data cannot be shared across process instances. For example. New process instances receive a copy of the Job Shared Variable. Job Shared Variable A Job Shared Variable resource is similar to a Shared Variable. This type of shared variable is useful for passing data to and from sub-processes without creating an input or output schema for the called process. There are two types of shared variables: • • Shared Variable Job Shared Variable Shared Variable A Shared Variable resource allows you to share data across process instances. Therefore. You can then retrieve the shared variable in all processes that require the current approval codes. a new process instance is created and the process instance receives a new copy of the Job Shared Variable.

you can check the Persistent field on the Configuration tab. its current state is written to the process engine storage location (either the file system or a database depending upon how the process engine was deployed). When you choose None. When you choose Build Value. if a process engine crashes. Sharing the Variable Across Multiple Process Engines If you wish to make the value of a Shared Variable resource available to process instances across multiple process engines. Select Value. See Editor on page 50 for more information about specifying data schema. You can choose either None (no initial value). you can specify an initial value for the variable on the Initial Value tab. When you choose Select Value. The Persistent field is not available on Job Shared Variable resources. no initial value is set and the variable value must be set in a process definition before it can be retrieved. but the state of these variables is saved by a checkpoint. Therefore. However. you can check the Multi-Engine field on the Configuration tab. an Edit button appears that allows you to bring up a dialog to construct the initial value of the variable. you can choose a stored XML Instance resource containing data that matches the specified schema. Making the Variable Persistent The current value of the shared variable is stored in memory for efficient access by process instances. When a shared variable is persistent. This field is not available on Job Shared Variable resources. it is not necessary to store these variables in a separate location in the process engine storage. whether the variable is persistent and whether the variable should be available across process engines Setting the Schema of the Shared Variable The Schema tab allows you to specify a complex schema for shared variable data. Setting the Initial Value of the Variable While configuring the shared variable. the current state of the shared variable may be lost. or Build Value. TIBCO BusinessWorks Process Design Guide . To preserve the current state of a Shared Variable resource. The current state of the shared variable is only updated in the process engine persistent storage when the value of the variable changes.102 | Chapter 7 Working With Variables • for Shared Variable resources.

the Lock shared configuration object and critical section group allow you to synchronize access to Shared Variable resources. a database must be used to store process engine data.This ensures that only one process instance attempts to assign a value to the variable and ensures that no process assigns a value to the variable when the current process attempts to read the value. you must either set an initial value in the variable’s configuration or use the Set Shared Variable activity to set the variable value. the current value of the variable is not stored in memory. Synchronizing Access to Shared Variables Because multiple process instances can potentially access and assign values to Shared Variable resources. You can assign a value to the shared variable by using the Set Shared Variable activity. This would result in an unpredictable value for the variable. Because multiple process engines access the shared variable. You can also configure the Set Shared Variable activity to include the current value of the variable as output for the activity. Assigning and Retrieving the Variable’s Value You can retrieve the current value of a shared variable by using the Get Shared Variable activity. Both of these activities can be found in the General Activities palette. Also. Without a mechanism for locking. a process instance could update the value of a variable while another process instance is attempting to read the value. You should use critical section groups to contain the Set Shared Variable and Get Shared Variable activities. See TIBCO Administrator User’s Guide for more information on specifying load balancing groups and specifying a database for process engine storage during deployment.Shared Variables 103 | If you choose this option. Both retrieving the current value of the variable and assigning a new value to the variable requires I/O to the process engine database storage. only engines that are in the same deployment and part of the same load-balancing group can share variables. See Critical Section Groups on page 88 for more information about using the critical section group. Before you retrieve the value of a shared variable. TIBCO BusinessWorks Process Design Guide . This provides access to the variable’s current value in subsequent activities in the process definition.

104 | Chapter 7 Working With Variables TIBCO BusinessWorks Process Design Guide .

page 106 Buttons. page 141 TIBCO BusinessWorks Process Design Guide . Topics • • • • • • • • Overview of Mapping and Transformation. page 124 XSLT Statements. and Icons. Menus. page 115 Repairing Incorrect Mappings. page 108 Specifying Constants. page 119 Examples of Mappings. page 114 Data Validation. page 117 Shortcuts.| 105 Chapter 8 Mapping and Transforming Data This chapter describes mapping data from a process to a specific activity’s input and how to transform the data using the activity’s Input tab.

The process data and activity input are represented as schema trees. All activities also have access to global variables. Figure 24 An activity’s input tab Process Data Panel The process data is the list of available data in the process definition at the point where the activity is located. TIBCO BusinessWorks Process Design Guide . On the Input tab.106 | Chapter 8 Mapping and Transforming Data Overview of Mapping and Transformation The Input tab of an activity allows you to supply the data that an activity expects as input. An activity has access to all output data from any activity that has been previously executed in the process definition. You cannot modify the process data on an activity’s input tab. you can see the available process data and the activity’s expected input. Figure 24 illustrates an activity’s Input tab. and information about the current process context. process variables. but you can use the data to supply input to the activity.

You can paste XSLT into your activity input or use the XSLT File shared configuration resource and the Transform XML activity. you can right-click on any item in the input schema and choose Copy from the popup menu. However. Most options in the Mapping Wizard dialog are straightforward. For more advanced use of XPath.Overview of Mapping and Transformation 107 | Activity Input Panel The activity’s input is an Extensible Stylesheet Language Transformation (XSLT) template that specifies how process data should be transformed to provide the expected input. Required elements must have a mapping or formula specified. You can specify XPath formulas to transform an element if you need to perform more complex processing. there are some complex scenarios that require multiple steps. See Statements. you do not need detailed knowledge of XSLT to specify an activity’s input. on page 147. You may also wish to refer to XSLT Statements on page 141 for a reference of XSLT statements when deciding which XSLT statement can be used to achieve the result you desire. When you perform mapping. The XSLT is displayed in your text document. then drag and drop that item into the desired schema element you wish to map in the Activity Input panel. a hint becomes an XSLT statement. XPath. You map data by selecting an item in the Process Data panel. There are also a variety of third-party books and resources about XSLT and XPath. see Chapter 9. Then open a blank text document and choose Paste. Hints. Once a mapping or formula is specified. However. the activity’s input elements are displayed as hints. For more complex mappings. Many of these situations are described in the section Examples of Mappings on page 124. Normally. These hints show you the data the activity expects as input. simple mappings appear in the formula area next to the input element after you release the mouse button. Each element can be required or optional. and Errors on page 108 for more information about hints and statements. Mapping and Transforming Process Data to Activity Input When an activity is first dragged from a palette to the design panel. The XPath Formula Builder allows you to easily create XPath formulas. You can also use your own XSLT templates to perform transformations instead of using the techniques described in this chapter. TIBCO BusinessWorks Process Design Guide . the Mapping Wizard dialog allows you to select which kind of mapping you wish to perform. if you are familiar with XSLT and you wish to see the actual code. See TIBCO BusinessWorks Palette Reference for more information and examples of using XSLT to perform mapping.

108 | Chapter 8 Mapping and Transforming Data Statements. You can also drag the hint to the left past the dividing line between the panels and the hint becomes a blank statement. All required input elements must have statements specified. you must fix the error before executing this process definition. There is also a popup menu when you right-click on elements in each panel. Menus. and any input elements that do not have a statement are displayed as hints. This section describes the various graphical elements of the Input tab. These statements are saved as part of the activity in the repository. Any statement or hint that has an error is displayed in red. Once you specify a statement in the Activity Input panel and apply the change to the activity. Once you specify a mapping or a formula for a hint. Hints. your statements may no longer be valid. The Mapper Check and Repair button can help you automatically fix some errors. and icons. and Icons The Input tab contains several toolbar buttons. and Errors When you display the Input tab for an activity. Hints are reminders that you can specify a statement for the input element. Table 10 describes the buttons and right-click menu items available in the panels of the Input tab. but they are not stored as part of the XSLT template for the activity’s input. if the input schema for the activity changes. the existing statements are examined. Toolbar and Right-Click Menu on the Input Tab The Process Data panel and the Activity Input panel have several buttons for performing various functions. the input element becomes a statement. Therefore. If a statement is red. See Repairing Incorrect Mappings on page 117 for more information about using the Mapper Check and Repair button to fix statements in the activity’s input. Statements are only deleted if you manually delete them using the delete button. or if you use the Mapper Check and Repair button to automatically fix errors. See Repairing Incorrect Mappings on page 117 for more information about fixing errors. popup menus. it becomes part of the XSLT template used to create the activity’s input data. Hints are displayed in italics with a light blue background. TIBCO BusinessWorks Process Design Guide . A hint is only displayed in red if it is a required input element. Buttons.

Expand>All expands all sub-elements of the currently selected element. Expands the elements in the Activity Input area to display elements that are mapped to the currently selected element or its sub-elements. a choice element can be coerced into one of the possible datatypes for the element. Allows you to specify a type for Process Data elements that are not a specific datatype. Moves the selected element down in the activity input tree. For example. Promotes the selected element to the next highest level in the activity input tree. Move Down. Show Connected Delete Copy Activity Input Area Shows/hides the mapping formulas for the input elements. or an element of datatype any can be coerced into a specific datatype. and Icons 109 | Table 10 Input tab toolbar buttons Button Right-Click Menu Description Process Data Area Coercions. Move Up. Menus. Move Out Move Out. Copies the selected element. TIBCO BusinessWorks Process Design Guide . Moves the selected element up in the activity input tree.Buttons. Expand>Content expands the current element so that all elements that are currently used in a mapping are visible. Deletes the selected element. The element can be later pasted. Expand This menu item has two sub-menus: Content and All. Type Documentation. Allows you to specify or view documentation for schema elements.

Invokes the XPath formula builder. Mapper Check and Repair. XPath. See Repairing Incorrect Mappings on page 117 for more information.110 | Chapter 8 Mapping and Transforming Data Table 10 Input tab toolbar buttons Button Right-Click Menu Move In Description Moves the currently selected element into a new statement. See XSLT Statements on page 141 for more information about XSLT statements. Edit Statement. See Chapter 9. Allows you to modify an XSLT statement for the element. Deletes the selected element and all of its child elements. Adds a statement for a child element to the currently selected element. on page 147 for more information about XPath and the XPath formula builder. See XSLT Statements on page 141 for more information about XPath statements. such as Choice or If. Delete Delete All Insert. A list of errors and warnings appear and you can choose which items you wish to fix. You can use this editor to create an XPath statement for this input element. Add Child. TIBCO BusinessWorks attempts to fix simple problems such as adding missing activity input items that are expected. TIBCO BusinessWorks Process Design Guide . Edit XPath Formula Builder. See the description of the Statement menu item below for more information. The right-click menu item Statement provides a shortcut for multi-line statements. See XSLT Statements on page 141 for more information about XSLT statements. Verifies the XSLT template you have created in the Activity Input panel against the activity’s expected input. You can add one element or XSLT statement at a time with this button. This displays the Move Into New Statement dialog that allows you to choose the statement you wish to move the element into. Inserts a new element or XSLT statement in the activity input schema on the same level of the hierarchy as the currently selected element.

You can use the Type Documentation button to obtain any available documentation on any node in the Process Data or Activity Input schema trees. TIBCO BusinessWorks Process Design Guide . Table 11 Icons for schema items Icon Description Complex element that is a container for other datatypes. Expand>Content expands the current element so that all sub-elements that have a mapping or expression are visible. Menus.Buttons. Rolls back the last operation performed. Errors. This is also called a branch in the schema tree. Table 11 describes the icons used for schema items. and Icons 111 | Table 10 Input tab toolbar buttons Button Right-Click Menu Expand Description This menu item has three sub-menus: Content. The element can be later pasted to a new location. Pastes the last element that was copied or cut. and All. Expand>Errors expands the currently element so that all sub-elements that have an error in their expression are visible. Expand>All expands all sub-elements of the currently selected element. Expands the elements in the Process Data area to display elements that are mapped to the currently selected element or its sub-elements. Deletes the selected element. Copies the selected element. This menu item contains shortcuts that allow you to easily add the desired XSLT statement(s) with one menu item instead of adding the statement(s) with the Insert button. Show Connected Statement Undo Redo Cut Copy Paste Icons for Schema Element Datatypes Schema elements also have a set of associated icons to indicate their type. See Right-Click Menu on page 119 for a description of the sub-items of this menu. Performs the last operation that was undone with the Undo menu item.

This can be any of the following datatypes: • • • • • • • • • Time Date Date & Time Duration Day Month Year Month & Year Day & Month Simple binary (base 64) or hex binary value. but not displayed in the Activity Input area. Simple boolean value. For example. a question mark icon signifies an element is optional in the Process Data schema or in a hint in the Activity Input.112 | Chapter 8 Mapping and Transforming Data Table 11 Icons for schema items Icon Description Simple string or character value. Qualifier Icons Schema elements can have additional icons that specify qualifications. Choice. Simple Date or Time. Represents a schema item that can be any datatype. The qualifier icons have different meanings depending upon where they appear. in an XSLT statement. Simple decimal (floating point) number. Data in this schema element can be any datatype. Simple integer value. the question mark signifies the statement is "collapsed" and an implicit "if" statement is set. Specifies that the actual schema element can be one of a specified set of datatypes. TIBCO BusinessWorks Process Design Guide . However.

then checking the Set Explicit Nil field on the Content tab of the Edit Statement dialog. Menus. Statement N/A An implicit "if" statement is set for this statement. You can set an element explicitly to null by clicking the Edit Statement button for the element. N/A N/A A null sign indicates the item is explicitly set to null. TIBCO BusinessWorks Process Design Guide . Table 12 Additional icons for hints Qualifier Process Data or Hint No qualifier indicates the element is required. A plus sign indicates the item repeats one or more times. An asterisk indicates the item repeats zero or more times. and Icons 113 | Table 12 describes the additional qualifiers that appear next to the name of schema items. A null sign indicates the item may be set to null.Buttons. This occurs when you map an optional element from the process data to an optional element in the Activity Input schema or if you specify Surround element with if test on the Content tab of the Edit Statement dialog. A question mark indicates an optional Item.

Date and Datetime Strings in Constants In constant expressions used in activity input bindings. enclose the string in quotes. UTC time is always used. Constants can be strings or numeric values. The following illustrates specifying the string "USA" for the Country item and 94304 for the PostalCode item of an input schema. you can specify a constant.114 | Chapter 8 Mapping and Transforming Data Specifying Constants For each element in the activity input schema tree. To specify a number. datetime values are read in according to the ISO 8601 standard. To learn more about complex XPath expressions that use functions and search predicates. XPath. 31 seconds and 112 milliseconds after 2pm on February 10th. To specify a string. The output for the example above is: 2002-02-10T14:55:31. see Chapter 9.112Z which is the equivalent time in the UTC timezone. as described in the XML Schema specification. When TIBCO BusinessWorks generates datetime strings (for example in the process debugger display for process data). This can lead to complications if you are processing data from different timezones.112-08:00" is 55 minutes. Constants can also be used in functions and search predicates. so you are encouraged to always use timezones. type the number into the schema element’s mapping field. For example. 2002 in a timezone that is 8 hours. the value: "2002-02-10T14:55:31. TIBCO BusinessWorks Process Design Guide . on page 147. the value is interpreted in the timezone of the machine that is performing the parsing. 0 minutes behind UTC. If no timezone field is present.

w3.org/TR/2003/WD-xpath-functions-20031112/ for more information on the proper representation of these datatypes.w3.org/TR/2004/PER-xmlschema-2-20040318/ for more information on the proper representation of these datatypes.0 Functions and Operators specification at http://www. Datatype validation listed with the prefix xsd: is defined in the namespace http://www. the content of the document is checked to ensure that elements in the document are actually of the specified datatypes. For example. Table 13 describes the validation behavior. Datatype validation listed with the prefix xdt: is defined in the namespace http://www.0 and Xpath 2.w3. See XML Schema Part2: Datatypes specification at http://www.org/2001/XMLSchema.org/2003/11/xpath-datatypes. Table 13 Datatype validation Data Type Built-In Primitive Types boolean decimal float double string duration yearMonthDuration dayTimeDuration dateTime time date xsd:boolean xsd:decimal xsd:float xsd:double xsd:string xsd:duration xdt:yearMonthDuration xdt:dayTimeDuration xsd:dateTime xsd:time xsd:date Validation TIBCO BusinessWorks Process Design Guide .Data Validation 115 | Data Validation Data passed as input to an activity or from an event received by a process starter is validated to ensure that it conforms to its specified datatype. if you pass an XML document to a Parse XML activity.w3. See Xquery 1.

116 | Chapter 8 Mapping and Transforming Data Table 13 Datatype validation Data Type gYearMonth gYear gMonthDay gDay gMonth hexBinary base64Binary anyURI QName NOTATION untypedAtomic Validation xsd:gYearMonth xsd:gYear xsd:gMonthDay xsd:gDay xsd:gMonth xsd:hexBinary xsd:base64Binary xsd:anyURI xsd:QName xsd:NOTATION xdt:untypedAtomic Built-In Derived (Atomic) Types integer nonPositiveInteger negativeInteger long int short byte nonNegativeInteger unsignedLong unsignedInt unsignedShort unsignedByte positiveInteger xsd:integer xsd:nonPositiveInteger xsd:negativeInteger xsd:long xsd:int xsd:short xsd:byte xsd:nonNegativeInteger xsd:unsignedLong xsd:unsignedInt xsd:unsignedShort xsd:unsignedByte xsd:positiveInteger TIBCO BusinessWorks Process Design Guide .

To help find potential problems in your mappings.Repairing Incorrect Mappings 117 | Table 13 Datatype validation Data Type normalizedString token language Name NCName ID IDREF ENTITY NMTOKEN Validation xsd:normalizedString xsd:token xsd:language xsd:Name xsd:NCName xsd:ID xsd:IDREF xsd:ENTITY xsd:NMTOKEN Repairing Incorrect Mappings Any incorrect statements are displayed in red in the Activity Input panel. TIBCO BusinessWorks Process Design Guide . and therefore must be specified the activity’s input schema has changed and existing statements may no longer be valid the XPath formula for an element may contain an error You should correct any errors before attempting to test or deploy your process definition. For example. and TIBCO BusinessWorks will attempt to fix the problem. This button displays a dialog with all potential problems in the specified mappings. click the Mapper Check and Repair button. You can select the Fix checkbox for potential errors. • • • a required element has no statement. Errors can occur for a number of reasons.

Figure 25 illustrates an activity input schema for the External Command activity. any items that are marked for fixing are repaired. TIBCO BusinessWorks Process Design Guide . 3. You can select or clear the Fix checkbox for each item. If you want to return to the original expected activity input and remove all of the currently specified mappings. Alternatively. and therefore TIBCO BusinessWorks cannot automatically fix the problem. 2. Click OK. you can simply select the root input element and press the delete key on your keyboard as a shortcut for the procedure above.118 | Chapter 8 Mapping and Transforming Data For example. and therefore there is no checkbox in the Fix column for these items. Delete the root element of the activity’s input by selecting it and clicking the Delete button. 4. Figure 25 Mapper check and repair dialog Some potential problems in the Mapper Check or Repair dialog cannot be fixed easily. depending upon whether you wish to fix the problem or leave the problem until a later time. The Mapper Check and Repair dialog displays these problems with the Fix checkbox checked. A new element named foo has been added to the schema and the expected element token has been removed. perform the following: 1. For example. You must repair these items manually. if an element expects a string and you supply a complex type. Click the Mapper Check and Repair button. Select the Fix checkbox for all items. When you click OK. the corrective action to fix the problem is not clear.

Add Child. This section describes shortcuts for manipulating XSLT statements. however. Figure 26 illustrates dragging an element to the left. Right-Click Menu When you select an element in the Activity Input schema and right-click.Shortcuts 119 | After deleting all mappings and schema items and then repairing the input schema. and Edit Statement buttons on the Input tab toolbar are ways to manually manipulate XSLT statements in the Activity Input area. • Surround with Choice — a shortcut for adding a choice statement and its associated conditions or otherwise statements around the currently selected element. The Statement menu item contains several sub-items that are useful shortcuts for creating XSLT statements. Duplicate — a shortcut for creating a duplicate of the currently selected element (including any mappings or XPath formulas for the element). These buttons. TIBCO BusinessWorks Process Design Guide . Surround with For-Each-Group — a shortcut for moving the current element into a For-Each-Group statement and adding a Group-By grouping statement. Shortcuts The Move In. • • • • Dragging to the Left Dragging an element in the Activity Input schema to the left past the divider between the two areas of the Input tab changes a hint into an XSLT statement. only add or modify one statement at a time. Surround with If — a shortcut for adding an if statement and placing the currently select element as the sub-element of the if. Surround with For-Each — a shortcut for moving the current element into a For-Each statement. there are some situations where you wish to convert a hint into a statement without performing any mapping. Insert. Also. a popup menu appears. the activity’s input reverts to the state when the activity is first dragged into the design panel. The duplicate is added below the currently selected element.

Dragging the ID element past the divider turns the hint into a statement.120 | Chapter 8 Mapping and Transforming Data Figure 26 Dragging to the left to change a hint to a statement Before dragging. Once the XSLT is copied. dragging to the left brings up the Mapping Wizard and allows you to choose a type for the element. You can choose any element in the Activity Input area and select Copy from the right-click menu or press the Control-C keys to copy the XSLT statement for the element. dragging to the left brings up a dialog that allows you to specify the type for the element. you can paste it into a text editing tool to view or modify the code. You can also paste arbitrary XSLT code into the Activity Input area using the right-click menu or the Control-V keys. When you have an element of type Any. TIBCO BusinessWorks Process Design Guide . Pasting XSLT code from the copy buffer places the code above the currently selected element in the Activity Input area. Cutting and Pasting The Activity Input area is an XSLT template for specifying the activity’s input schema. When you have a choice element. the ID element is a hint. This shortcut is useful in the following situations: • • • When you have a complex element with no sub elements and no content.

the value of the activity input element is set to the value of the process data element. more complex tests are necessary. If the element exists. when elements are optional or nillable. If the process data element is not present. and if so. Required to Required Specifies that the statement should always include the required activity input element and its value should be obtained from the required process data element that the element is mapped to. Optional to Nillable Specifies that the statement should test if the optional process data element exists. If the process data element does not exist. In the simplest case of mapping a required element in the process data schema to a required activity input element. Therefore. then an example is given that illustrates these mappings and shows the XSLT code that is generated automatically when these mappings are performed. TIBCO BusinessWorks Process Design Guide . Optional to Optional Specifies that the statement should test if the process data element is present. When you drag the process data element to the activity input element. The value of the activity input element is set explicitly to nil if that is the value of the process data element. However. The types of mappings are described. the necessary tests are automatically placed into the activity input XSLT template. the value of the process data element is assigned to the required activity input element. This section describes the result of mapping different types of elements. the optional element is omitted from the activity’s input.Shortcuts 121 | Automatic Testing When you map process data elements to activity input elements. include the optional element in the activity’s input. the activity input element should be created and set to the value of the process data element. the behavior of the mapping depends upon the types of elements you are mapping. the element is omitted from the activity input schema. Nillable to Nillable Specifies that both the process data and activity input elements can be nil.

The CustomerAddr and ShipTo elements illustrate mapping an optional and nillable element to an optional and nillable element. or nillable. You can see from the XSLT code that certain mappings are automatically surrounded by tests to create the appropriate input schema.org/2001/XMLSchema-instance" TIBCO BusinessWorks Process Design Guide . then include the optional activity input element in the input schema. if the process data element is nil. and nillable elements In the example above.w3. The OnSale element illustrates mapping a nillable element to an optional element.122 | Chapter 8 Mapping and Transforming Data Nillable to Optional Specifies that the statement should test if the process data element has a value specified. and Nillable Elements Figure 27 illustrates the different types of mappings when elements are required. Optional. If the process data element is not nil. the optional element is omitted from the activity input. Otherwise. the optional element in the activity input should be set to the value of the process data element. If the process data element is nil. Item and Amount illustrate mapping required elements to other required elements. The Pickup element illustrates mapping an optional element to a nillable element. set the value of the activity input element explicitly to nil. Example of Mapping Required. If the process data element is not present. Optional & Nillable to Optional & Nillable Specifies that if the optional process data element exists. then omit the optional element from the activity input schema. set the value of the activity input element to the value of the process data element. and if so. optional. optional. The Discount element illustrates mapping an optional element to an optional element. <?xml version="1.0" encoding="UTF-8"?> <xsl:template xmlns:xsi="http://www. Figure 27 Examples of mapping required. Below is the XSLT template illustrated by the mappings in Figure 27.

true&quot.tibco.w3.com/bw/process/2003" xmlns:xsl="http://www.1&quot.)"> <OnSale> <xsl:value-of select="$RetrieveOrder/IncomingOrder/Order/OnSale"/> </OnSale> </xsl:if> <xsl:if test="$RetrieveOrder/IncomingOrder/Order/Discount"> <Discount> <xsl:value-of select="$RetrieveOrder/IncomingOrder/Order/Discount"/> </Discount> </xsl:if> <pfx:ShipTo> <Pickup> <xsl:choose> <xsl:when test= "exists($RetrieveOrder/IncomingOrder/Order/Pickup)"> <xsl:value-of select= "$RetrieveOrder/IncomingOrder/Order/Pickup"/> </xsl:when> <xsl:otherwise> <xsl:attribute name="xsi:nil">true</xsl:attribute> </xsl:otherwise> </xsl:choose> </Pickup> <xsl:if test="$RetrieveOrder/IncomingOrder/Order/StoreLocation"> <StoreLocation> <xsl:value-of select= "$RetrieveOrder/IncomingOrder/Order/StoreLocation"/> </StoreLocation> </xsl:if> <xsl:if test="$RetrieveOrder/IncomingOrder/Order/CustomerAddr"> <ShipTo> <xsl:copy-of select= "$RetrieveOrder/IncomingOrder/Order/CustomerAddr/@xsi:nil"/> <xsl:value-of select= "$RetrieveOrder/IncomingOrder/Order/CustomerAddr"/> </ShipTo> </xsl:if> </pfx:ShipTo> </Order> </xsl:template> TIBCO BusinessWorks Process Design Guide ..tibco.org/2001/XMLSchema" xmlns:pfx="http://www.org/1999/XSL/Transform" xmlns:xsd="http://www.com/xmlns/ae2xsd/2002/05/ae/Order"> <Order> <Item> <xsl:value-of select="$RetrieveOrder/IncomingOrder/Order/Item"/> </Item> <Amount> <xsl:value-of select="$RetrieveOrder/IncomingOrder/Order/Amount"/> </Amount> <xsl:if test="$RetrieveOrder/IncomingOrder/Order/OnSale/@xsi:nil!= (&quot.&quot.w3.Shortcuts 123 | xmlns:pd="http://xmlns.

2. Select the input element you wish to set to nil. it appears as [<< Filter >>] to indicate that you must supply the filter expression. 3. you do not have to follow the same procedures outlined in this section to achieve the correct set of statements. dates. To set an input element explicitly to nil. on page 147 for more information on how to use XPath. This section describes some complicated mapping scenarios and how to achieve the desired mappings using the tools available. There are many methods to insert or modify XSLT statements in the Activity Input schema. perform the following: 1. and booleans. you may wish to set an element explicitly to nil. Click the Content tab of the Edit Statement dialog. One situation is when you wish to insert a row into a database table and you wish to supply a NULL for one of the columns. In the Activity Input area. To do this. However. the XPath expression might be: $RetrieveOrders/Order[itemID=34129].124 | Chapter 8 Mapping and Transforming Data Examples of Mappings Some mappings require several steps to achieve the desired results. Setting an Element Explicitly to Nil In some situations. You can also use XPath to perform basic manipulation and comparison of strings. Click the Edit Statement button on the Input tab toolbar. See Chapter 9. XPath expressions have search predicates for performing filtering. numbers. For example. Using XPath TIBCO BusinessWorks uses XPath (XML Path Language) to specify and process elements of the Activity Input schema. TIBCO BusinessWorks Process Design Guide . One of the most common uses of XPath is to filter a list for specific elements. The examples in this section illustrate the simplest procedures to obtain the desired results. when a search predicate is required. you may wish to select a specific order from a list of orders where the item ordered is itemID #34129. XPath. You can use any valid XPath expression in the XSLT statements in the Activity Input area.

TIBCO BusinessWorks Process Design Guide . The element’s formula becomes blank and uneditable (because nil is the value of the element) and the explicit nil qualifier icon appears next to the statement .Examples of Mappings 125 | 4. Check the checkbox in the Set Explicit Nil field.

The following procedure describes how to map multiple elements into a single repeating element. In this example. Multiple types of customers are retrieved. the schemas are the following: You wish to combine customers into a single repeating structure to create a mailing list. each having a different format for the address.126 | Chapter 8 Mapping and Transforming Data Merging Input from Multiple Sources You may have multiple elements in the Process Data that you wish to map to one repeating element in the Activity Input. merged mailing list containing all customers in one format. For example. TIBCO BusinessWorks Process Design Guide . you may have multiple formats for customer records and you wish to create a single.

TIBCO BusinessWorks Process Design Guide . right-click. one for each format. Map one of the elements from the Process Data to the first copy of the repeating element in the activity input. 2. but the two copies in the Activity Input area make it simpler to perform two different mappings. you need two copies of the repeating element. Select the repeating element in the Activity Input area. map $Retrieve-Customer-Type1/Customer to MergeMailingList/CustomerList/Customer. For example. and select Statement > Duplicate from the popup menu.Examples of Mappings 127 | 1. The resulting output contains only one repeating customer element. Because you are creating two different formulas for mapping.

TIBCO BusinessWorks Process Design Guide . Map the other element from the Process Data to the second copy of the repeating element in the activity input. Choose the For Each option and click Next. For example. The mapping wizard asks if you wish to automatically map items with the same names. 3. choose the For Each option and click Next. In the Mapping Wizard dialog. Click Finish to accept the default mappings. map $Retrieve-Customer-Type2/Record to MergeMailingList/CustomerList/Customer.128 | Chapter 8 Mapping and Transforming Data The Mapping Wizard dialog appears and presents choices for what you would like to accomplish.

Click Finish to accept the default mappings.Examples of Mappings 129 | The mapping wizard presents you with an option to automatically map elements with the same name. This function is used to concatenate the three elements in the Record element in the process data area to one Address element in the activity’s input. drag a concat() function into the XPath Formula field. In the XPath Formula Builder. Select the Address element and click the XPath Formula Builder icon in the Input tab toolbar. 4. TIBCO BusinessWorks Process Design Guide .

130 | Chapter 8 Mapping and Transforming Data Click the Data tab. add a comma to the end of the function to include a third string to concatenate. Drag the $current()/Address/state element into the << string2 >> placeholder in the concat() function. 5. then drag the $current()/Address/street element into the << string1 >> placeholder in the concat() function. Click Apply. Then. Drag the $current()/Address/zip element into the position of the third string in the concat() function. TIBCO BusinessWorks Process Design Guide . then click Close to dismiss the XPath Formula Builder dialog.

The same customer can have mutliple orders in this list. that element is Orders. each item in the list is a customer ID. The following procedure describes how to map the flat list of orders into a list grouped by customer ID. the schemas are the following: Flat list of orders placed by all customers. This scenario typically occurs when you retrieve records from a relational database and the records must be structured differently. 1. Each customer ID will. Right-click on this element and choose Statement > Surround with For-Each-Group. This results in the following mapping: Converting a List Into a Grouped List You may need to convert a flat list of items into a more structured list. The resulting schema is a repeating list of Orders. This is a shortcut to create a For-Each-Group statement with TIBCO BusinessWorks Process Design Guide .. in turn. In this example. from the pop-up menu. you may have list of all orders that have been completed. For example. You may want to organize that list so that you can group the orders placed by each customer. Each item in the repeating element Requests lists an order. contain a list of orders. Choose the repeating element in the Activity Input schema that holds the grouped data. In this example.Examples of Mappings 131 | 6..

Drag the element you wish to group by from the Process Data area to the Grouping statement in the Activity Input area. 3. and the current-group() function allows you to access the items in the Requests repeating element that correspond to the group that is currently being processed. TIBCO BusinessWorks Process Design Guide . The Grouping statement creates the list grouped by the desired element. customerID is the grouping element. In this example.132 | Chapter 8 Mapping and Transforming Data the Orders element as a child element and a Grouping statement to contain the element you wish to group-by. Drag the repeating element from the Process Data area to the For-Each-Group statement. Adding the Grouping statement creates the $=current-group() element in the Process Data area. 2.

5. Map the remaining element from the current-group() element into the desired element in the For-Each group. This creates an item in the Order list for each item in the current customer ID group that is being processed. Map the current-group() element in the Process Data area to the repeating element Order under the Customer element in the Activity Input area. In this case. The default choice in the mapping wizard for this mapping is to create a For-Each. TIBCO BusinessWorks Process Design Guide . Choose this option in the mapping wizard.Examples of Mappings 133 | 4. quantity would map to Quantity automatically. and Item must be mapped to ItemName. The mapping wizard asks if you wish to map items with the same name in the current group and the orders group.

you may have a list of student IDs and a list of grades. The following procedure describes how to merge the two repeating elements containing corresponding data into one repeating element. For example.134 | Chapter 8 Mapping and Transforming Data 6. the schemas are the following: The resulting merged list will contain a both student ID and grade in a single repeating element. TIBCO BusinessWorks Process Design Guide . Two repeating lists contain corresponding student IDs and grades. Merging Two Corresponding Lists You may need to merge two lists that have corresponding items. Map the customerID element in the Requests element into the Customer element in the Activity Input area. each grade corresponds to the student ID in the same position in the student ID list. In this example.

the $RetrieveStudentIDs/Students/Record is the first repeating element. Click Finish in the Mapping Wizard dialog to create the For-Each statement.Examples of Mappings 135 | 1. 2. Map the first repeating element from the Process Data area into the Grades repeating element in the Activity Input area. This brings up the mapping wizard with the default choice of creating a For-Each statement. In this example. TIBCO BusinessWorks Process Design Guide . Drag the second repeating element into the For-Each statement.

4. Merging two parallel repeating structures requires two variables. Click Finish to proceed. One variable is to hold the position number of the current item being processed. Create the variables with the default names supplied by the mapping wizard. Choose the Merge parallel repeating structure option and click Next. The $=[item=] element contains a statement to retrieve the item in the second repeating element that corresponds to the position of the item in the first list that is currently being processed. TIBCO BusinessWorks Process Design Guide . The $=[index=] element contains the XPath formula position() to set the element with the current position number of the list item being processed. The two variables appear in the Process Data area once you have completed this step. The two variables also appear in the Activity Input area with the correct XPath statement to produce the desired result. or choose your own names for these variables. The Mapping Wizard dialog appears asking you to chose an option. and the other variable is to hold the item in the second list that corresponds to the position of the item in the first list.136 | Chapter 8 Mapping and Transforming Data 3. The mapping wizard prompts you to name these two variables.

In these situations. TIBCO BusinessWorks Process Design Guide . you may know the datatype of the element. the datatype of a Process Data element may be undefined. The Coercions button in the Input tab toolbar allows you to create and manage your coercions. Map the ID element to the StudentID element in the Activity input. 6. The schema is for a generic incoming message that can have any type of body. and you can coerce the element into a specific type. the any element is coerced into an Order type so that it can be mapped to a choice element. Map the $=item/Grade element to the Grade element in the Activity Input area.Examples of Mappings 137 | 5. however. The following example illustrates a schema with an element defined as the "any element" datatype. In the example. Coercions In some situations.

1. The Coercions dialog allows you to manage all of your coercions for an activity in one dialog. or delete coercions for any element in the Process Data schema using this dialog. The activity input is expecting either an Order or a CreditLimitIncrease for the incoming message. Click the Coercions button in the Input tab toolbar. click the Insert button (+) to add a coercion for the currently selected element. There are many ways of accomplishing the same result as this example. Select the element of type any element in the Process Data schema. Click the Element radio button to specify that you are specifying a schema element. the schemas are the following: The incoming message can have a body of type any element. not just the currently selected element.138 | Chapter 8 Mapping and Transforming Data In this example. The following procedure describes how to coerce the Body element of the incoming message into a specific datatype and map it to a choice element. In the Coercions dialog. If you are creating a coercion for an element that is not currently selected. use the XPath field to specify the location of the element. This example attempts to illustrate the simplest method to achieve the desired result. modify. You can create. TIBCO BusinessWorks Process Design Guide .

In the Select a Resource. select the schema that you would like to specify Click OK to coerce the element into the datatype of the selected schema element. Map the Name element to the Name element in the Activity Input area. The following would be the resulting schema where the element of the datatype any element has been replaced with the Order schema... Click the Browse Resources button next to the Schema field to browse a list of schemas that can be used.Examples of Mappings 139 | 2. TIBCO BusinessWorks Process Design Guide . 3. map the coerced Order element to the choice element in the Activity Input area. dialog. Then.

Click Next to continue.140 | Chapter 8 Mapping and Transforming Data The Mapping Wizard dialog appears and asks if you wish to create an Order or a CreditLimitIncrease element. TheMmapping Wizard then asks if you wish to automatically map elements with the same name. The Mapping Wizard then asks you to create a For Each. TIBCO BusinessWorks Process Design Guide . Select Order and click Next. Even though there is only one element in the Process Data schema (the Message element is not repeating). a For Each is used because this construct allows you to map the individual items of the Order element. Click Finish to accept the default mappings.

The following is the completed mapping. you can optionally specify the kind of value the attribute will have and whether the attribute should be surrounded by an if statement. you can specify the value of the last name attribute to be a constant. You can add or edit these statements by clicking the Edit Statement button or these statements can be added automatically by selecting them from the dialogs that appear when you drag and drop elements from the Process Data tree to the Activity Input tree. like so: <ns:attribute namespace="mns" name="lastName"/> "Smith" </ns:attribute> TIBCO BusinessWorks Process Design Guide . Attribute Allows you to specify an attribute. <ns:attribute namespace="mns" name="lastName"/> When attributes are created. XSLT Equivalent The following is an attribute named "lastname".XSLT Statements 141 | 4. and optionally the namespace for the attribute. XSLT Statements The following sections describe the XSLT statements you can add to your Activity Input. You can also specify the type of value for the attribute. For example.

org/1999/XSL/Transform" select="$Query/resultSet"/> Copy-Contents-Of Copies the selected node’s contents. If the node set is empty (no files were transferred).org/1999/XSL/Transform"> <ns0:when test="$FTP-Put/FTPPutOutputFile/FileTransferred" > < something here .and -->.w3.142 | Chapter 8 Choose Mapping and Transforming Data Provides a way to select transformation to perform based on an expression. no children of the node are copied. <ns0:choose xmlns:ns0="http://www. and if so.. Specify the condition in the when element as an XPath expression. You can optionally specify an otherwise condition for processing all elements that do not meet any of the specified when conditions. performs an action. XSLT Equivalent The following determines if the node set for FilesTransferred contains any files. TIBCO BusinessWorks Process Design Guide . > </ns:0when> <ns0:otherwise> < something here .. This is useful if you wish to copy an element to a new element with a different name.comment here --> Copy Copies the selected node to the current node in the input tree. Only the node is copied. Comments are delimited by <!-.. XSLT Equivalent <ns0:copy xmlns:ns0="http://www. XSLT Equivalent <!-. a different action is performed..w3.> </ns0:otherwise> </ns0:choose> Comment Places a comment in the XSLT template.

<ns:for-each select="$FTP-Put/FTPPutOutputFile/FileTransferred"> <fileName> <ns:value-of select="$FTP-Put/FTPPutOutputFile/FileTransferred/Name"/> </fileName> </ns:for-each> TIBCO BusinessWorks Process Design Guide .org/1999/XSL/Transform" select=""/> Element Creates an element with the specified name.XSLT Statements 143 | XSLT Equivalent <ns:element namespace="foo" name="bar"> <ns:copy-of select="null/@*"/> <ns:copy-of select="null/node()"/> </ns:element> Copy-Of Creates a copy of the selected node. This is useful if you wish to process each item of a repeating element once. XSLT Equivalent <elementName>value</elementName> For-Each Performs the specified statements once for each item in the selected node. XLST Equivalent <ns0:copy-of xmlns:ns0="http://www.w3. including the node’s children. Both the copied node and the destination node must have the same name and structure. XSLT Equivalent The following iterates over the list of files transferred from an FTP Put activity and outputs an element with the name of each file for each file transferred.

XSLT Equivalent <ns0:processing-instruction xmlns:ns0="http://www.org/1999/XSL/Transform" test="not(position()=last())"> <ns:attribute name="OrderItem"> <ns:value-of select= "$GetOrderInformation/OrderInformation/OrderDetails/OrderItem"/> TIBCO BusinessWorks Process Design Guide .org/1999/XSL/Transform" select=""/> Generate Comment Places a comment element into the XSLT template. This statement requires a Grouping statement to specify which element to group-by. <ns:if xmlns:ns="http://www. The last order item is not output. This comment will be generated into the activity’s output. XSLT Equivalent <ns0:for-each-group xmlns:ns0="http://www. All items except the last order item are retrieved from the output of the GetOrderInformation activity. See Converting a List Into a Grouped List on page 131 for an example of using the For-Each-Group statement. the statements in the if are output.w3.w3. XSLT Equivalent The following if statement surrounds an attribute for processing order items.org/1999/XSL/Transform"/> Generate PI Places a processing instruction into the XSLT template. otherwise they are not output. Comment elements have the following syntax: <ns0:comment xmlns:ns0="http://www. If the test attribute evaluates to true.144 | Chapter 8 Mapping and Transforming Data For-Each-Group Groups the items in a list by a specified element.w3.w3.org/1999/XSL/Transform" name=""/> If An if statement is used to surround other statements in an XSLT template to perform conditional processing.

This is normally done implicitly by specifying the formula for an activity input item. With a variable. in this case 40 times.org/1999/XSL/Transform" name="var" select="$RetrieveResults/resultSet"/> TIBCO BusinessWorks Process Design Guide . the retrieval of the current process variable occurs 40 times per iteration of the loop. TIBCO BusinessWorks must retrieve the current process variable for each XPath expression. You can specify the name of the variable and whether you wish the variable to have a select attribute. it appears in the Activity Input and Process Data areas. If this mapping appears in a loop. Variables can also improve performance of mappings for large data structures. if you have a process variable with 40 sub-elements. then map the combined list to an activity input item. the variable (in the Process Data area) can be mapped to any activity input item. but you may insert this statement explicitly. You can map the results of the computation to several activity input items instead of recreating the computation for each item. Therefore. XSLT Equivalent <ns0:variable xmlns:ns0="http://www.w3. create a local variable to hold process variables with a large number of elements and use the local variable in XPath expressions instead of the process variable. You can supply any XPath expression to the new variable in the Activity Input area (either through mapping or through the XPath Formula Builder). Adding a variable is useful when you wish to join two repeating elements into a single list. Once the variable’s contents have been supplied. to improve performance.XSLT Statements 145 | </ns:attribute> </ns:if> Value-Of Specifies a value-of statement. the data is retrieved only once and used for all mappings containing the variable. When you add a local variable.org/1999/XSL/Transform" select=""/> Variable Adds a local variable for use in the current mapping. and you map each of the sub-elements to a corresponding input item. Adding a variable is also useful if you perform the same computation repeatedly.w3. XSLT Equivalent <ns:value-of xmlns:ns="http://www. For example.

146 | Chapter 8 Mapping and Transforming Data TIBCO BusinessWorks Process Design Guide .

numbers. TIBCO BusinessWorks uses XPath as the language for defining conditions and transformations. For a complete description of XPath.org). Topics • • • • XPath Basics. page 153 Date and Time Functions. page 148 The XPath Formula Builder. refer to the XPath specification (which can be obtained from www. page 151 String Representations of Datatypes. XPath also has basic manipulation functions for strings. page 155 TIBCO BusinessWorks Process Design Guide . and booleans. This section covers the basics of XPath and its use in TIBCO BusinessWorks.w3.| 147 Chapter 9 XPath XPath (XML Path Language) is an expression language developed by the World Wide Web Consortium (W3C) for addressing parts of XML documents.

or it can be a complex element. numbers. booleans. Regardless of where the data comes from or its format. and booleans. For a complete description of XPath. Both simple and complex elements can also repeat. the following schema may be available for an activity’s input: TIBCO BusinessWorks Process Design Guide . refer to the XPath specification (which can be obtained from www. For example. numbers.w3. To use XPath in TIBCO BusinessWorks. You can also use XPath to perform basic manipulation and comparison of strings. you need only be familiar with the basic XPath concepts. either simple elements or other complex elements. and so on). TIBCO BusinessWorks represents the data as a schema tree. Complex elements are structures that contain other schema elements. XPath is used to specify which schema element you would like to refer to. These data schema are either process variables or input schema for an activity.org). Addressing Schema Elements All process data and activity input are represented as an XML schema. The data can be simple (strings.148 | Chapter 9 XPath XPath Basics TIBCO BusinessWorks uses XPath (XML Path Language) to specify and process elements of data schema. but you may wish to learn more about XPath when building complex expressions. That is. they can be lists that store more than one element of the given type.

For example. Evaluation Context XPath also has a method for referencing relative paths from a particular node. each a root node in the process data area: GetCustomerInformation. Namespaces Some schema elements must be prefixed with their namespace. if your evaluation context is $GetOrderInformation/ShipName. then you can reference the sub-items of ShipName without specifying the entire path. If you wish to reference $GetOrderInformation/RequiredDate. To reference a particular data item in any of these schema. The namespace is automatically added to elements that require this when creating mappings on the Input tab of an activity or when dragging and dropping data in the XPath formula builder. For example. GetOrderInformation. the relative path would be . until the desired location is named. then continues with node names using slashes. you can specify the relative path to other elements in the tree./RequiredDate. like a file or directory structure. GetCustomerInformation has a set of simple values and GetOrderInformation has simple data and other complex data. Each of these schema has its own associated structure. If you have an evaluation context. TIBCO BusinessWorks Process Design Guide .XPath Basics 149 | The process data area of the example input tab illustrates the output schema of the activities in the process. you would use the following syntax: $GetOrderInformation/ShipName/Street The path starts with a dollar sign to indicate it begins with a root node. for example. you start with the root node and then use slashes (/) to indicate a path to the desired data element.. and GetOrderId. There are three output schema. The path is relative to the evaluation context — RequiredDate is one level higher in the schema tree than the elements of ShipName. if you wish to specify the Street attribute in the ShipName complex element that is in the GetOrderInformation node. or a particular starting node in a schema tree.

You can also build custom Java functions and make them available in XPath by using the Java Custom Function shared resource. you would specify the following: $GetOrderInformation/OrderDetails/OrderItem[position()>1] See the online documentation available in the XPath formula builder for a list of the available operators and functions in XPath. You can test an element to determine if it is set to nil or not. Testing For Nil Some elements can be explicitly set to nil. you would specify the following: $GetOrderInformation/OrderDetails/OrderItem[ProductId="3A54"] You can also use functions and expressions in the search predicate. you would specify the following: $GetOrderInformation/OrderDetails/OrderItem[1] The [1] specifies the first element of a repeating item. the following XPath expression returns true if the $Order/Item/OnSale element is set to nil: $Order/Item/OnSale/@xsi:nil="true" Comments You can add comments to XPath expressions using the XPath 2. For example. to select the element whose ProductId is equal to "3A54". The search predicate is used to locate a specific element of a repeating schema item.returns the street --} TIBCO BusinessWorks Process Design Guide .0 syntax for comments. The syntax is: {-. For example. See the description of the Java Custom Function shared configuration resource in TIBCO BusinessWorks Palette Reference for more information about creating custom functions and making them available in XPath. if you wish to find all elements after the first. the $GetOrderInformation/OrderDetails/OrderItem item is a repeating element.<comment here> --} For example.150 | Chapter 9 XPath Search Predicates An XPath expression can have a search predicate. Sub-items can also be examined and used in a search predicate. If you wish to select only the first item in the repeating element. For example. For example. the following XPath expression contains a comment: $GetOrderInformation/ShipName/Street {-.

Figure 28 The XPath formula builder Table 14 describes the different areas of the XPath formula builder. If a function is dragged into the XPath formula window. Figure 28 illustrates using the XPath formula builder to drag and drop schema elements into function placeholders. such as when creating transformations on the Input tab of an activity. automatically become valid XPath location paths for the desired item. when dragged into the XPath Formula field. The schema elements. You can drag and drop schema elements over the parameter placeholders to replace each placeholder. All elements in this tree are available to drag and drop into the XPath Formula field.The XPath Formula Builder 151 | The XPath Formula Builder The XPath formula builder can be used where XPath expressions are allowed. TIBCO BusinessWorks Process Design Guide . The XPath formula builder allows you to drag and drop schema elements and XPath functions to create XPath expressions. there are placeholders for each parameter of the function. Table 14 XPath formula builder elements Element Data tab Description Displays the process data schema tree.

The result of evaluating the function is displayed in the "Expression Evaluates To" panel.152 | Chapter 9 XPath Table 14 XPath formula builder elements Element Functions tab Description Displays the available XPath functions. they are listed there as well. See Evaluation Context on page 149 for more information about the evaluation context. Displays the XPath formula you wish to create. into XPath formulas. symbols. placeholders are displayed for the function’s parameters. such as tabs. see the description of the function that is displayed when it is selected in the XPath formula builder. For more information about XPath functions. When the function is placed into the XPath formula. the documentation panel gives a brief description of the function and one or more examples. Documentation panel Describes each selected function. and so on. such as date formats. These are categorized into groups and each function can be dragged from the function list into the XPath Formula field. Constants are also defined for commonly used items. You can drag and drop schema elements from the Data tab into the function’s placeholders. These are categorized into groups and each constant can be dragged from the constants list into the XPath Formula field. If there are any errors in the expression. Constants tab Displays the constants available for use in XPath expressions. As you click on a function in the Function tab. Displays the evaluation context of the expression field that the editor was invoked from. You can drag and drop items from the Data tab or the Functions tab to create the formula. Constants are useful for inserting special characters. Evaluation Context field XPath Formula field TIBCO BusinessWorks Process Design Guide .

For example. The function concatenates the data elements $GetCustomerInformation/Street and $GetCustomerInformation/City and places a space between the two elements. the data is represented as a string. writing the output of an activity to a file requires that numeric data be serialized into string form. Also. supplying a floating point number to an XPath function in the Input tab of an activity often involves typing the number as a string into the input element. TIBCO BusinessWorks Process Design Guide . TIBCO BusinessWorks follows the XML Schema canonical format for all other datatypes.0 standard for representing all numeric datatypes. Figure 29 Creating an XPath formula String Representations of Datatypes When data must be represented in the input or output of an activity. they are displayed here. TIBCO BusinessWorks follows the XPath 1. If there are errors in the formula.String Representations of Datatypes 153 | Table 14 XPath formula builder elements Element Expression Evaluates To Panel Description Displays the result of evaluating the formula shown in the XPath Formula field. Figure 29 illustrates using the XPath formula builder to create a valid function.

Conversion between these representations may result in a loss of information either because of the difference in time zone representation or the precision of the seconds. 1970.154 | Chapter 9 XPath The following sections describe the string representations of datatypes. Date Datatypes Activities in TIBCO BusinessWorks implement dates in one of two ways. The XPath function false() is also represented as false. Positive and negative infinity are represented as Infinity and -Infinity. Dates output by the Java Code activity contain the time zone. if there are only zeros following the decimal point (for example. All decimal. and so on) do not use the time zone. TIBCO BusinessWorks Process Design Guide . Scientific notation is never used to represent a floating point number as a string (for example. Either a date is stored as the number of milliseconds since January 1. Data is truncated if the number of digits exceeds the maximum precision for the datatype (for example. float. and xs:double. and so on) use the second implementation. xs:dateTime. Activities that are associated with Java (for example. Other Java activities (Java Method.2345679). xs:boolean(’false’) and xs:boolean(’0’) are represented by false. Mapper. Both zero and negative zero are represented as 0.0 standards as a set of normalized components (xs:date. The second implementation supports arbitrary precision of the seconds component. xs:boolean(’true’) and xs:boolean(’1’) are represented by true. "xs:float(’1. Activities that are associated with XML (for example.000" is represented as 1). Java Method. Boolean The boolean datatype is used to indicate a true or false state. Parse XML. xs:float. The XPath function true() is also represented as true. "1. Numeric Datatypes Numeric datatypes include all types derived from xs:integer. Java Code. and so on) use the first implementaton. xs:decimal. Java to XML. Not a number is represented as NaN.234E05’)" is represented as 123400). "xs:double(’1. and double numbers are compressed to an integer when represented.0 or XQuery 1. xs:time.23456789’)" is represented as 1. Therefore mapping a date output by a Java Code activity to the input of any other Java activity will result in the loss of the time zone information. and so on) with an optional time zone offset. or the date is implemented according to the XPath 2.

To include a single quote. Table 15 describes the alphabetic characters and their associated presentation in a date or time string. 2003. <<string>>) The format parameter of these functions is based on the format patterns available for the java. Table 15 Formatting characters in date or time strings Letter G Description Era Four or more Gs return the full name of the era. <<string>>) parse-date(<<format>>.Date and Time Functions 155 | Date and Time Functions There are some functions in the XPath formula builder that allow you to parse or format strings that represent dates and times. <<string>>) parse-time(<<format>>. You can include non-pattern alphabetic characters in the string by quoting the text with single quotes. 08 w W D d Week in year Week in month Day in year Day in month 48 3 254 28 TIBCO BusinessWorks Process Design Guide . <<time>>) parse-dateTime(<<format>>. In the format parameter. use ’’. These functions are: • • • • • • format-dateTime(<<format>>. Example AD y year Two ys return two-digit year. <<date>>) format-time(<<format>>. Aug. unquoted alphabetic characters from A to Z and a to z represent the components of the date or time string.text. August.SimpleDateFormat Java class. 03 M Month in year Three or more Ms return text name. <<dateTime>>) format-date(<<format>>.

the output is padded with zeros. if the date or time has fewer digits than the number of pattern letters. For formatting functions. unless they are needed to determine the boundaries of adjacent fields. w. h. Example 3 Friday.156 | Chapter 9 XPath Table 15 Formatting characters in date or time strings Letter F E Description Day of week in month Day in week Four or more Es return the full name of the weekday. and m). RFC 822 four-digit time zone format Reserved 23 1 11 1 59 48 456 GMT-8:00 -8:00 — Z all other letters For any format pattern letter that returns a numeric value (for example. when the date or time has fewer digits than the number of characters in the format pattern. For parsing functions. the extra characters are ignored. the number of letters in the format pattern represents the minimum number of digits. TIBCO BusinessWorks Process Design Guide . Fri a AM/PM marker Four or more as return the full name. AM H k K h m s S z Hour in day (0-23) Hour in day (1-24) Hour in AM/PM (0-11) Hour in AM/PM (1-12) Minute in hour Second in minute Millisecond Time zone represented as a GMT offset.

MM.dd G ’at’ HH:mm:ss" "EEE. zzzz" "K:mm a" "yyMMddHHmmssZ" Result 2003. Table 16 Example date and time format patterns Date/Time Pattern "yyy.11 AD at 09:43:56 Tue.Date and Time Functions 157 | Table 16 illustrates some example date and time format patterns and the resulting string.3. GMT-8:00 0:08 PM 010704120856-700 TIBCO BusinessWorks Process Design Guide . ’03 9 o’clock AM. MMM d. ’’yy" "hh ’o’’clock’ a. Mar 11.

158 | Chapter 9 XPath TIBCO BusinessWorks Process Design Guide .

This chapter describes error handling in process definitions. page 160 The Error Process Variables.| 159 Chapter 10 Error Handling When executing business processes. Topics • • • • Overview of Error Handling. You may wish to add procedures to your process definitions for handling any expected or unexpected errors. page 162 Process Error Schemas. page 160 Error Propagation. page 164 TIBCO BusinessWorks Process Design Guide . activities can encounter errors.

You then specify activities you wish to execute in the event of an error. This allows you to create error-handling procedures for dealing with potential runtime errors in your process definitions. The following sections describe the two kinds of error process variables. and all activities that have an error transition are available in the Process Data panel after an error transition is taken. For example. If the update is successful. the process ends. the database is down). TIBCO BusinessWorks Process Design Guide . The following sections describe error handling in more detail. You can specify that one transition out of an activity is to be taken in the case of an error. depending upon what error occurred. error data is available to activities that execute after the error transition. For example.160 | Chapter 10 Error Handling Overview of Error Handling Errors can occur during activity processing. Activity error variables are named $_error_<activityName>. There are two types of process variables that contain error data. You can use the data in these process variables to perform the desired processing. If an error is encountered (for example. the following illustrates a simple process that begins with an HTTP request and updates a database based on the incoming request. an error may occur during a Send Mail activity if the specified mail host does not exist. the $_error process variable and the activity error variables. Figure 30 illustrates this simple error-handling procedure. Figure 30 A simple error-handling procedure Error handling can also involve significantly more complex processing. an email is sent to a system administrator. The Error Process Variables When an error transition is taken. The error transition is used to specify the activities to execute in case of an error. and then the process ends.

You can use a coercion to change the Data element into the specific type for the activity. the following illustrates the error output schema of the Create File activity: This activity can encounter the FileAlreadyExistsException or the FileIOException. The schema of the $_error variable is the following: The contents of each schema item are dependent upon the activity that throws the error.The Error Process Variables 161 | $_error Process Variable The $_error process variable contains general information about the process in which the error occurred. Typically. TIBCO BusinessWorks Process Design Guide . When you create an error-handling procedure. $_error_<activityName> Process Variables Each activity has one or more predefined error schemas. For example. The error schemas are displayed on the activity’s Error Output tab. you may find the data in the $_error process variable useful. TIBCO BusinessWorks Palette Reference describes the error schemas on the Error Output tab of all activities and lists possible causes for each error type. there are two or three types of exceptions an activity can encounter. The Data schema item contains activity-specific error information. Refer to the description of each activity for more information about the Error Output tab. You can map data from this process variable into Input items for activities in your error-handling procedure. and these are represented as a choice element in the error output schema.

The name of the process variable is dependent upon the activity’s specified name. Also.162 | Chapter 10 Error Handling When an error is encountered. in the above error schema. but the text of the message may change. The error code should remain constant from release to release. Error Propagation Called processes and groups propagate any unhandled errors to the parent process. the $_error_<activityName> process variable is created and populated with the error data. The Generate Error activity does not permit any transitions to another activity. You can obtain the error by examining the $_error_<activityName> process variable in subsequent activities after an error transition. TIBCO BusinessWorks Error Codes lists all error codes that activities can return. You should use the error code instead of the error message text to detect and handle errors. if the FileAlreadyExistsException error occurs. Unhandled errors occur where there is no error transition that specifies the activities to execute in the case of an error. The following expression can be used to determine if the FileAlreadyExistsException occurred: boolean($_error_MyCreateFile/ActivityErrors/ ns2:FileAlreadyExistsException) You can use the msgCode element to determine the kind of error that occurred. so any error created by the Generate Error activity is propagated to the parent process. For example. TIBCO BusinessWorks Process Design Guide . The following illustrates the Process Data panel that is available after the activity named MyCreateFile encounters an error: You can use XPath expressions to determine which error occurred and handle the error accordingly. then that node is not empty. you can use the Generate Error activity to create an unhandled error.

The Generate Error activity can use any error schemas defined on the process to propagate a specific schema to the parent process. then inserts the records into a database table. Figure 31 Propagating errors from a group The process definition uses two group activities. A second group surrounds the iterate group to enclose all updates in a transaction. then the error transition out of the group is taken to the Send Mail activity.Error Propagation 163 | The following sections describe propagation of errors for groups and called processes. the process ends. The Generate Error activity is used to propagate an error outside of the transaction group to the parent process. If the iterate group experiences an error. TIBCO BusinessWorks Process Design Guide . the WriteLogEntry activity is executed. parses the files into an XML schema. If any of the updates fail. Group Error Propagation Unhandled errors halt the execution of a group and the error transition out of the group is taken. See Process Error Schemas on page 164 for more information about process error schemas. If the transaction succeeds. The transition to the Send Mail activity is taken if there is either an error when committing the transaction or if the Generate Error activity is executed (because of an error in the iterate group). The error process variables contain the error information for the activity where the error occurred. an error transition out of the group is taken to the WriteLogEntry activity. The first group is an iterate group that performs one update for each record. Figure 31 illustrates a process definition that waits for new text files. the error transition is taken out of the transaction group to the SendMail activity. If the transaction fails.

You can define specific error schemas to hold error data when errors are propagated from a group or a called process. See Process Error Schemas on page 164 for more information about process error schemas. If the GetCreditLimit or ProcessOrder processes encounter an error. TIBCO BusinessWorks Process Design Guide . Figure 32 Propagating errors from a called process The GetCreditLimit process is called to check the credit limit of the customer that places the order. Any unhandled errors encountered when executing the called process cause the called process to halt execution and return the error to the parent process. Each process can define a number of error schemas by creating these schemas on the Error Schema tab of the process definition’s End Activity. Also. If the credit limit check succeeds. The error process variables contain the error information for the activity where the error occurred. a response is sent back to the customer stating there was an error in the order and the process definition terminates. the called process can encounter errors.164 | Chapter 10 Error Handling Called Process Error Propagation When a process definition calls another process definition. Process Error Schemas The error process variables contain the default data returned in the event of an error. the ProcessOrder process is called. a process can define an error schema and use the Generate Error activity to propagate specific data to the parent process. Figure 32 illustrates a process definition that waits for an incoming HTTP request that contains an order. a response is sent back to the customer stating the order is complete and the process definition terminates. If the order processing is successful.

Figure 34 illustrates the Configuration tab of the Generate Error activity.Process Error Schemas 165 | Error schemas are created like any other schema (see Editor on page 50). Figure 33 illustrates the Error Schemas tab with two error schemas. The Select Error Schema field contains a drop-down list of error schemas defined for the process. only the $_error process variable contains the propagated error data. the specified error schema is propagated to the parent process. The left panel of the tab allows you to create or delete schemas. When the Generate Error activity is executed. TIBCO BusinessWorks Process Design Guide . However.Default .is chosen for the error schema. The middle portion allows you to modify the selected schema. Figure 34 The Generate Error Configuration tab If . the Error Schema tab of the End activity allows you to create more than one error schema. The right panel of the tab allows you to modify each schema item. Figure 33 The Error Schemas tab Error schemas are used by the Generate Error activity.

TIBCO BusinessWorks Process Design Guide . InvalidCustomer and NotEnoughCredit. In the example described in Called Process Error Propagation on page 164. the Generate Error propagates the specified error schema to the parent process in the $_error_<activity-name> process variable. the schema appears in the Input tab for the Generate Error activity and you can map data to the specified error schema. This process specifies two error schemas. See TIBCO BusinessWorks Palette Reference for more information about the Generate Error activity. The process variable is derived from the activity where the Generate Error occurred. This item will contain either the InvalidCustomer or the NotEnoughCredit error schema. and then map the data in the schema accordingly. If the Generate Error occurred in a group. the <activity-name> portion of the process variable is the name of the Call Process activity. Figure 35 Example of process data for error schemas The available error schemas for the GetCreditLimit process are presented as a schema item of type Choice. At run time. the SendErrorInOrder activity has access to the error schema supplied by any GenerateError activity in the GetCreditLimitProcess. the <activity-name> portion is the name of the Generate Error activity in the group. If the Generate Error occurs in a called process. You can use XPath to determine which schema is actually contained in the element.166 | Chapter 10 Error Handling If a process error schema is chosen. Figure 35 illustrates the process data available to the SendErrorInOrder activity.

page 172 Summary of Transactions. page 180 TIBCO BusinessWorks Process Design Guide . page 170 XATransaction. Transactions ensure that all participants in the transaction either complete or are rolled back together. Topics • • • • • Overview of Transactions. page 168 JDBC. This chapter describes how to incorporate transactions into your process definitions. page 169 Java Transaction API (JTA) UserTransaction.| 167 Chapter 11 Transactions TIBCO BusinessWorks allows you to group some activities into a transaction group.

The activities that can participate in the transaction are determined by the transaction type. To create a transaction. however. When you create a transaction group. only JDBC activities whose JDBC Connection type is "JDBC" can participate in a JDBC transaction. you must specify the type of transaction. For example. Types of Transactions TIBCO BusinessWorks offers a variety of types of transactions that can be used in different situations. For more information about creating groups. For example. any activity can be contained in a transaction group. you may have three JDBC Update activities and one Write File activity in a transaction group. The following sections describe each of these types of transactions and the situations in which they are used in more detail. and the type of the activity.168 | Chapter 11 Transactions Overview of Transactions In TIBCO BusinessWorks a transaction is a logical unit of work. Only the following types of activities have transactional capabilities: • • • JDBC activities JMS activities EJB activities Although only the activities above can be part of a transaction. The Write File activity. Not all TIBCO BusinessWorks activities can participate in a transaction. the configuration of the activity. Transactions allow you to group multiple activities into an atomic execution unit. see Grouping Activities on page 71. All the JDBC Update activities either complete or roll back at the end of the transaction. You can use the type of transaction that suits the needs of your integration project. you use a group to surround the activities in the transaction. All activities that can participate in a transaction must either complete successfully or be undone or rolled back together. TIBCO BusinessWorks Process Design Guide . TIBCO BusinessWorks supports the following types of transactions: • • • JDBC Java Transaction API (JTA) UserTransaction XA Transaction A transaction group can have only one transaction type. does not participate in the transaction and executes whether the transaction commits or fails.

each set of activities that uses a JDBC Connection is considered a separate transaction. Individual JDBC activities can override the default transaction behavior and commit separately. If any errors occur while processing the activities in the group. even errors in non-JDBC activities. Only JDBC activities that use the same JDBC Connection participate in this transaction type. all JDBC activities using the same JDBC connection in the transaction group commit. Configuring JDBC Transactions To configure a JDBC transaction. the transaction is rolled back and an error is returned (you should have an error transition out of the group to handle this situation). In this case. If you have more than one JDBC Connection in the transaction group. For example. However. but other activities can be part of the transaction group. A. B. If the transaction rolls back. use the XA transaction type. only activities that use the same JDBC Connection are guaranteed to commit or rollback together when the transaction completes. you have three JDBC Updates in a transaction group. the updates for activities A and B are part of one transaction and the update for activity C is part of a different transaction. To create a distributed transaction across multiple databases. It is possible to use more than one JDBC Connection in the same transaction group. in the JDBC Connection resource(s) used by JDBC and Checkpoint activities in the group. See the description of the JDBC palette in TIBCO BusinessWorks Palette Reference for more information about using JDBC activities. The transaction group commits automatically if all activities in the group complete and a non-error transition is taken out of the transaction group. select JDBC in the Connection Type field. A and B use JDBC Connection X. If the transaction commits.JDBC 169 | JDBC The JDBC transaction allows multiple JDBC activities that access the same database connection to participate in a transaction. Also. Multiple JDBC Connections In Transaction Groups All activities that use the same JDBC Connection shared configuration resource are part of the same transaction. and C. all JDBC activities using the same JDBC connection in the transaction group roll back. TIBCO BusinessWorks Process Design Guide . select JDBC Transaction as the transaction type of the group. but C uses JDBC Connection Y.

no exception is raised and the operations that are not supported by the application server are performed independent of the transaction. See http://java. Refer to your application server documentation for more information about supported operations. request/reply operations cannot participate in a JTA transaction. TIBCO BusinessWorks Process Design Guide . the transaction is rolled back and an error is returned. JMS. all eligible activities in the transaction group roll back. If any errors occur while processing the activities in the group. Using this type of transaction requires an installed and configured application server that implements the JTA interface javax. even errors in activities that do not participate in the transaction. If the transaction rolls back. all eligible activities in the transaction group commit. Configuring JTA UserTransaction Transactions To configure a JTA UserTransaction. However. the application server. and the application. JTA specifies standard Java interfaces between a transaction manager and the parties involved in a distributed transaction system: the resource manager. TIBCO BusinessWorks still allows you to configure the operations in the transaction. If the transaction commits. select JTA UserTransaction as the transaction type of the group.UserTransaction.transaction. If the application server does not permit an operation. and EJB activities to participate in transactions.com/products/jta/ for more information about the API. For activities that use the JMS transport. the following transaction servers implement the JTA transaction interface: • • • BEA WebLogic Application Server IBM Websphere Application Server JBoss Application Server Not all application servers permit JMS and JDBC operations to participate in the JTA transaction. You should create an error transition out of the group to handle this situation. The transaction group commits automatically if all activities in the group complete and a non-error transition is taken out of the transaction group. For example. Sun Microsystems developed and maintains the API.170 | Chapter 11 Transactions Java Transaction API (JTA) UserTransaction The Java Transaction API (JTA) UserTransaction type allows JDBC.sun.

The JNDI configuration for JMS. The JTA UserTransaction transaction group has the following fields on the transaction group’s Configuration tab: Field Transaction Manager Description A JTA UserTransaction shared configuration resource. you can specify a duplicate key in this field to perform duplicate checking. This is useful if the checkpoint included in the transaction is the first checkpoint in the process definition. Include Checkpoint Checkpoint Duplicate Key TIBCO BusinessWorks Process Design Guide . Activities that use the JMS transport must be configured to use the XA connection factory in the application server. The deployment configuration must specify a database for storing process engine information and the JDBC Connection used must specify JNDI as the connection type for this checkpoint to participate in the transaction. or JDBC activities must specify the appropriate connection and JNDI Context information for the application server.Java Transaction API (JTA) UserTransaction 171 | JDBC Connections used by JDBC activities in the transaction group must be configured to use JNDI as the connection type and specify the data source in the application server. an implicit checkpoint is performed after the last activity in the group completes successfully and before the transaction is committed. See TIBCO BusinessWorks Palette Reference for more information about this resource. When this field is checked. If the process engine crashes after the checkpoint. EJB. When the Include Checkpoints field is checked. restarted process instances can use the duplicate key to determine if the transaction has already committed. See Detecting Duplicate Process Instances on page 184 for more information about specifying duplicate keys.

JMS activities must be configured to use the XA connection factory. checkpoints can participate in an XA Transaction. The following XA-compliant transaction managers have been tested with TIBCO BusinessWorks: • • Arjuna Transaction Service 3. the path to the files needed to run the transaction manager must be placed in the TIBCO BusinessWorks classpath in the bwengine. If any errors occur while processing the activities in the group.tra files. select XA Transaction as the transaction type of the group.transaction.transaction. TIBCO BusinessWorks Process Design Guide . The third-party transaction manager is executed in the same Java VM as TIBCO BusinessWorks. and JMS activities to participate in transactions. For JMS activities.5. if your process engine is configured to use a database for storage of process engine data. JDBC Connections used by JDBC activities in the transaction group must be configured to use XA as the connection type.TransactionManager and javax. Also. Because of this. Configuring XA Transactions To configure an XA Transaction.3 Java Open Transaction Manager (JOTM) 1.Transaction. If the transaction commits. all eligible activities in the transaction group roll back.3 (this transaction manager does not support transaction recovery) The XA Transaction type allows JDBC activities. request/reply operations cannot participate in an XA transaction. You should have an error transition out of the group to handle this situation. The transaction group commits automatically if all activities in the group complete and a non-error transition is taken out of the transaction group. Also. Transactions across multiple databases are also supported.172 | Chapter 11 Transactions XATransaction The XA Transaction type allows you to specify an XA-compliant transaction manager provided by a third party that supports the interfaces javax. the transaction is rolled back and an error is returned. EJB activities cannot participate in an XA Transaction group. all eligible activities in the transaction group commit. even errors in activities that do not participate in the transaction.tra and designer. If the transaction rolls back.

or JMS Topic Subscriber expect acknowledge messages to be sent to the server. such as JMS Queue Receiver. Include Checkpoint When this field is checked. Include In Transaction TIBCO BusinessWorks Process Design Guide . this is done by using a Confirm activity. The deployment configuration must specify a database for storing process engine information and the JDBC Connection used must specify XA as the connection type for this checkpoint to participate in the transaction. an implicit checkpoint is performed after the last activity in the group completes successfully and before the transaction is committed. if the transaction completes successfully. This message is part of the transaction. Normally. Wait for JMS Queue Message.XATransaction 173 | The XA Transaction group has the following fields on the transaction group’s Configuration tab: Field Transaction Manager Description An XA Transaction shared configuration resource. This field allows you to specify the resource for which you would like to send an acknowledgement message. Certain resources. Note: Transactional acknowledge mode is not supported for Wait for JMS Topic Message activities. See TIBCO BusinessWorks Palette Reference for more information about this resource. There is no need for a Confirm activity for the resources specified in this field. These resources can also specify an acknowledge mode of "Transactional" that specifies their acknowledgement should be part of a transaction.

no changes are required to the JOTM environment to interact with TIBCO BusinessWorks. TIBCO BusinessWorks must be configured as follows to interact with JOTM.3\lib 2.properties). you can specify a duplicate key in this field to perform duplicate checking.jotm. add jotm_log_file. Java Open Transaction Manager (JOTM) For Java Open Transaction Manager (JOTM). The classpath for TIBCO Designer and TIBCO BusinessWorks must be modified to include the JOTM jar files. Configuring Third-Party Transaction Managers When using a third-party transaction manager with TIBCO BusinessWorks. The logging details for JOTM is specified in the TIBCO BusinessWorks log4j property file (<BW_HOME>\5. This section details the requirements for configuring the supported transaction managers. To each of these properties.2\lib\log4j. the following JOTM directory must be included in classpath properties in the designer. log4j. restarted process instances can use the duplicate key to determine if the transaction has already occurred.5.5.174 | Chapter 11 Transactions Field Checkpoint Duplicate Key Description When the Include Checkpoints field is checked. To accomplish this.tra files: <JOTM_HOME>\jotm-1. you must configure the transaction manager and TIBCO BusinessWorks to work together properly. 1. By default. See Detecting Duplicate Process Instances on page 184 for more information about specifying duplicate keys. you must modify the TIBCO BusinessWorks log4j property file. If the process engine crashes after the checkpoint. To send JOTM log messages to a separate file. There are several JOTM logger properties with the prefix. the log4j property file is configured to send JOTM log messages to the TIBCO BusinessWorks log file (BWLogFileAppender).tra and bwengine. However.objectweb. See Logging for Third-Party Components on page 190 for more information about the TIBCO BusinessWorks log4j file.3\config <JOTM_HOME>\jotm-1. TIBCO BusinessWorks Process Design Guide .org. This is useful if the checkpoint included in the transaction is the first checkpoint in the process definition.logger.

arjuna. Open the ATS properties file (<ATS_HOME>\ats-3.ats.ats.jtaUTImplementation" value="com. 3.arjuna. ATS provides two recovery modules for XA resources. local transaction recovery is used.jta.arjunacore.internal. To change the object store's location.recovery.ats. one that is local (com.arjuna.arjuna.jta.XATransaction 175 | Arjuna Transaction Service For the Arjuna Transaction Service (ATS).2\etc\arjunajts-properties.Transact ionManagerImple"/> <property name="com. one for local transaction recovery and one for distributed transaction recovery.ats.arjuna.arjunacore.jta.ats.ats.jta.recoveryExtension5" value="com.arjunacore.recovery. ATS provides two transaction manager implementations. both the ATS environment and the TIBCO BusinessWorks environment must be modified.arjuna.internal.jts.recoveryExtension6" value="com.jtaTMImplementation" value="com.jtaTMImplementation and com.recovery. set the value for the following property in the ATS properties file to your directory’s location: TIBCO BusinessWorks Process Design Guide .ats.Transaction ManagerImple) and one that is based on the distributed JTA implementation (com.arjuna. therefore the distributed transaction recovery property must be commented out or removed from the ATS properties file.jta. this will be the working directory or the directory where the TIBCO BusinessWorks process engine is started. For TIBCO BusinessWorks to work correctly.internal.internal.transaction. TIBCO BusinessWorks uses the local transaction recovery. TIBCO BusinessWorks only supports the local implementations.XARecoveryModul e"/>).ats.xml) and make sure that the properties com.ats.UserTran sactionImple"/> 2. The following configuration changes must be performed in the ATS properties file: 1.transaction.arjuna. By default the ATS properties file may be configured to enable both the local transaction recovery (<property name="com.ats.transaction.arjunacore. In TIBCO BusinessWorks.internal.arjuna. By default.jtaUTImplementation are set to the following values: <property name="com.jts.arjuna.jta.jta. ATS must be configured to use the local implementations.arjuna.jta.arjuna.jta.arjuna.transaction.XARecove ryModule"/>) and distributed transaction recovery (<property name="com. When using TIBCO BusinessWorks. It is recommended that you change the location where the ATS ObjectStore is created.arjuna.recovery.TransactionManager Imple).ats.internal. the ATS ObjectStore is created in the current working directory of the application.ats.jta.

Comment out the line containing: log4j. Refer to the JOTM documentation for more information.arjuna.com.3\lib <ATS_HOME>\ats-3. Remove the comment from the line containing #log4j. The classpath for TIBCO Designer and TIBCO BusinessWorks must be modified to include the ATS property file and jar files. By default. Java Open Transaction Manager (JOTM) Transaction recovery is not supported by Java Open Transaction Manager (JOTM).arjuna=WARN.objectstore.tra and bwengine. This section details transaction recovery in the supported transaction managers.2\lib\log4j.3\etc <ATS_HOME>\ats-3.tra files: <ATS_HOME>\ats-3. the log4j property file is configured to send ATS log messages to the TIBCO BusinessWorks log file (BWLogFileAppender).arjuna=WARN. TIBCO BusinessWorks Process Design Guide . the following directories must be included in classpath properties in the designer. tibco_bw_log.ats.logger.arjuna. ats_log_file.176 | Chapter 11 Transactions <property name="com. See Logging for Third-Party Components on page 190 for more information about the TIBCO BusinessWorks log4j file. The logging details for ATS is specified in the TIBCO BusinessWorks log4j property file (<BW_HOME>\5. To accomplish this. Transaction Recovery XA Transactions can be recovered in the event of a failure.logger. tibco_bw_log. you must modify the TIBCO BusinessWorks log4j property file.properties).3\lib\ext 2. To send ATS log messages to a separate file.objectStoreDir" value="your directory location" /> The following configuration changes must be made to TIBCO BusinessWorks to interact with ATS: 1.com.

Therefore. both the Arjuna Transaction Manager and the Arjuna Transaction Recovery Manager are started in the same Java VM as TIBCO BusinessWorks.bat: <BW_HOME>lib\palettes\plugins. and transaction recovery only occurs when TIBCO BusinessWorks is restarted. The following libraries must be included in <ARJUNATS_HOME>\bin\setup-env.jar <TPCL_HOME>jdbc\TIdb2.jar files. and no additional configuration is necessary. the transaction recovery manager is disabled if TIBCO BusinessWorks is stopped or if the Java VM crashes.jar <TRA_HOME>lib\TIBCOxml.jar <TRA_HOME>lib\TIBCrypt. After a failure.jar <TRA_HOME>lib\TIBCOjms.jar <TRA_HOME>lib\TIBCOrt.jar <TPCL_HOME>jdbc\TIbase. In this configuration however.jar <TPCL_HOME>jdbc\TIsybase. the recovery manager requires references to the TIBCO BusinessWorks . See the ATS documentation for more information about starting the Arjuna Transaction Recovery Manager in a separate Java VM.jar <J2EE_LIB>\jms.XATransaction 177 | Arjuna Transaction Service By default.jar <BW_HOME>lib\engine. regardless of the status of TIBCO BusinessWorks. the transaction recovery manager is started when TIBCO BusinessWorks is started. the ATS ObjectStore may contain the serialized TIBCO BusinessWorks Java classes.jar <TPCL_HOME>jdbc\TIoracle. Running the Arjuna Transaction Recovery Manager in a separate Java VM allows transaction recovery to occur independently. That is. When running the recovery manager in a separate Java VM. do not start one recovery manager in the same Java VM as TIBCO BusinessWorks.jar <TPCL_HOME>jdbc\TIutil. Therefore. verify the following: • The classpath for the Arjuna Transaction Recovery Manager must contain the location of the TIBCO BusinessWorks .jar <TPCL_HOME>jdbc\TIsqlserver. when starting the recovery manager in a separate Java VM. and then start another recovery • TIBCO BusinessWorks Process Design Guide .jar files to de-serialize the classes. Do not allow more than one Arjuna Transaction Recovery Manager to refer to the same ATS ObjectStore.jar <ORACLE_LIB>\ojdbc14.jar (when using an Oracle database) • The ATS property file for the recovery manager must refer to the same ATS ObjectStore that is configured for TIBCO BusinessWorks (see Configuring Third-Party Transaction Managers on page 174 for a description of configuring the ATS object store).

Check that the database user which the recovery manager's connection is using is the same as the one the business logic is using.ats.XAException: [tibcosoftwareinc][Oracle JDBC Driver][Oracle]ORA-00942: table or view does not exist. TIBCO BusinessWorks Process Design Guide . • Recovery may not be possible if the ATS ObjectStore is modified or destroyed.jta.xarecovery1] XARecoveryModule.xaRecovery got XA exception javax.ats.[com.logging.loggerI18N .recovery.arjuna. See the ATS documentation for more information.XAER_RMERR" This may be caused either by a missing table or by a lack of permissions.transaction. check that this user has the correct permissions on relevant data dictionary tables and views for the XA system.xa. Refer to the Arjuna Transaction Service documentation for more information about transaction recovery. XAException.929 [Thread-5] WARN com. When using the Oracle database. the following exception is logged by the ATS recovery manager after invoking the method "getConnection" of the XAConnectionRecovery object: "2004-08-24 17:20:56. Also.178 | Chapter 11 Transactions manager in a different Java VM when both recovery managers are pointing to the same ATS ObjectStore.jta.internal.arjuna.

That is. JTA Nesting JDBC transactions in a JTA transaction is allowed. Nesting JTA transactions in JTA transactions is not allowed. Nesting JTA transactions in JDBC transactions is allowed. but each transaction is independent. The outcome of the parent transaction does not affect the nested transaction. Nesting XA transactions in JTA transactions is allowed. each transaction commits or rolls back separately. but each transaction is independent. JTA TIBCO BusinessWorks Process Design Guide . XA Nesting XA transactions in XA transactions is allowed. but each transaction commits or rolls back separately. Nesting JTA transactions in XA transactions is allowed. but each transaction is independent. XA Nesting JDBC transactions in an XA transaction is allowed. thus "nesting" transactions. Nesting XA transactions in JDBC transactions is allowed.Nested Transactions 179 | Nested Transactions It is possible to place a transaction group in another transaction group. but each transaction commits or rolls back separately. An exception is thrown at the start of the nested transaction. Table 17 describes the effect of creating a transaction group in another transaction group. Table 17 Effects of nesting transaction groups Transaction type JDBC JDBC Nesting JDBC transactions in other JDBC transactions is allowed. but each transaction is independent. but each transaction is independent. but each transaction commits or rolls back separately.

when a database is used to store checkpoint data. but their acknowledge message can participate in the transaction.180 | Chapter 11 Transactions Summary of Transactions The following tables summarize the support of each type of activity in each type of transaction. Table 19 XA transaction type Activity Type Checkpoint (specified by the Include Checkpoint field of the transaction group) JDBC activities JMS activitiesa EJB activities Participate in XA Transaction Type? Yes. Yes. the acknowledge message for Wait for JMS Topic Message activities cannot be part of the transaction. Table 18 summarizes the JDBC transaction type.. Process starters and Wait For. when the JDBC Connection is configured to use the XA connection type. and the JDBC Connection is configured to use the XA connection type. activities cannot be part of an XA Transaction group. TIBCO BusinessWorks Process Design Guide . when JMS is configured to use an XA connection No a. Request/Reply operations (such as JMS Topic Requestor and JMS Queue Requestor) are not permitted in transactions. Yes. Table 18 JDBC transaction type Activity Type JDBC activities JMS activities EJB activities Participate in JDBC Transaction Type? Yes No No Table 19 summarizes the XA transaction type.. However. if the resource is configured to use the Transactional acknowledge mode and the resource is listed in the Include in Transaction field of the transaction group.

Yes. activities cannot be part of a JTA UserTransaction group. TIBCO BusinessWorks Process Design Guide . Process starters and Wait For.. Table 20 JTA UserTransaction type Activity Type Checkpoint (specified by the Include Checkpoint field of the transaction group) Participate in JTA Transaction Type With the Following Application Server? BEA Yes. Yes. No.Summary of Transactions 181 | Table 20 summarizes the JTA UserTransaction type. when using BEA JMS server. when the JDBC Connection is configured to use the JNDI connection type. and the JDBC Connection is configured to use the JNDI connection type. Request/Reply operations (such as JMS Topic Requestor and JMS Queue Requestor) are not permitted in transactions). EJB activities Yes Yes Yes IBM Not supported JBoss Not supported JDBC activities Not supported Not supported JMS activitiesa Not supported Not supported a.. when using TIBCO Enterprise Messaging Service. when database used to store checkpoint data.

182 | Chapter 11 Transactions TIBCO BusinessWorks Process Design Guide .

page 187 TIBCO BusinessWorks Process Design Guide . Topics • • Detecting Duplicate Process Instances. page 184 Sequencing Process Instances.| 183 Chapter 12 Process Instance Execution This chapter details aspects of process execution that you can control with configuration fields in the process definition.

If you are running fault tolerant process engines (that is. 4. the process engine stores the value and completes the Checkpoint activity. Once a process engine stores a duplicateKey value and performs the Checkpoint for a process instance. See TIBCO Administrator User’s Guide for more information on specifying process engine storage. The process engine checks the current list of duplicateKey values for a matching value. Duplicate detection can only be done across multiple engines on different machines if a database is used to store process engine data. This value should be some unique key contained in the event data that starts the process. only one process engine is running at a particular time).184 | Chapter 12 Process Instance Execution Detecting Duplicate Process Instances Duplicate messages should be detected and discarded to avoid processing the same event more than once. the process engine terminates the process and throws a DuplicateException. Therefore. Duplicate detection is performed when a process instance executes its first Checkpoint activity. b. you should take care in choosing the value of duplicateKey and ensure that it will be unique across all process instances. The following describes the procedure for duplicate detection by the process engine: 1. the orderID value is unique for all new orders. For example. Activities in the process instance are executed until the first Checkpoint activity is reached. you can use a file system for process engine storage. If another process instance has already stored the given duplicateKey value. An incoming message is received and a process instance is created. process engines can guarantee that no newly created or recovered process instances will execute if they have the same duplicateKey value. 3. no other Checkpoint activities in the process instance can be used to store a different duplicateKey value. Using the algorithm described above. a. TIBCO BusinessWorks Process Design Guide . 2. The Checkpoint activity has a value specified for the duplicateKey input element. or if all process engines run on the same machine. If no process instance has stored the given duplicateKey value. You must specify a value for the duplicateKey element in the Checkpoint activity input schema.

or the order is processed. it is important to place the Checkpoint activity before any activities that you do not want to execute more than once. orderID is unique for each incoming order. TIBCO BusinessWorks Process Design Guide . It is a better choice to put the Checkpoint activity between the process starter and the QueryInventory activities. For example. and then either an email is sent to the inventory manager if the inventory is not sufficient. In this example. In the example in the previous section. The following illustrates the example process definition with the Checkpoint activity properly placed. you may select the JMSMessageID header property for JMS messages. you can either place the Checkpoint before the QueryInventory activity (because it is a database query and no actual change occurs) or after the activity but before either the Send Mail or ProcessOrder activities. inventory is checked.Detecting Duplicate Process Instances 185 | When to Perform Checkpoints When detecting duplicate messages. consider the following process definition. For example. Specifying the Duplicate Key Duplicate detection is only as efficient as the duplicateKey that is specified. an order is received. so that would be a good choice for the value of the duplicateKey. You should try to pick a value that is unique for every message. In this process definition.

Handling Duplicate Messages When a duplicate is detected. the Checkpoint activity fails with the DuplicateException. The duplicateKey is specified in the Checkpoint Duplicate Detection Key field of the transaction group. TIBCO BusinessWorks Process Design Guide . the process instance terminates and duplicate messages are effectively ignored. In this example. then the transition is taken to the end of the process definition. You can place an error transition from the Checkpoint activity to a series of activities to handle the duplicate message. If this is the case. The following illustrates an error transition added to the example process. the duplicate message is confirmed so that it is no longer redelivered. In this case. If no error transition is specified. when a duplicate message is detected. you can specify the duplicateKey as part of the transaction group configuration. Transactions and Duplicate Detection Transaction groups using certain transaction types can allow Checkpoint activities to be performed as part of the transaction. the checkpoint performed for the transaction may be the first checkpoint in the process definition.186 | Chapter 12 Process Instance Execution The following illustrates specifying orderID from the example above as the duplicateKey value in the Checkpoint activity.

Custom Engine Properties. • bw.Sequencing Process Instances 187 | Process Engine Properties for Duplicate Detection The following process engine properties control duplicate key detection.enabled — specifies whether duplicate detection is performed. This method is not as flexible as using the Sequencing Key field on a process starter. false indicates duplicateKeys when specified are ignored. if you purchase a pre-built project from a third party). -1 indicates the duplicateKey values are deleted when the job completes. See Appendix B. TIBCO BusinessWorks allows you to specify a sequencing key on process starters that determines which process instances to execute sequentially. Sequencing Process Instances Process instances can be executed in the order they were created.engine. but only process instances with the same value for the sequencing key are executed sequentially. TIBCO Administrator allows you to control the maximum number of process instances in memory as well as the maximum number of concurrently executing process instances. TIBCO BusinessWorks Process Design Guide .dupKey. The default is 30 minutes. Using the administrator settings is only recommended when you cannot change the process definitions in the project before deployment (for example. Any positive integer greater than 0 indicates the number of minutes to keep stored duplicateKeys.dupKey. Using these settings. on page 237 for more information about setting process engine properties.engine.minutes • • — specifies the number of minutes to wait before polling for expired duplicateKey values. bw. true (the default) indicates the process engine will check for identical duplicateKey values. Process instances can have sequencing keys that evaluate to different values. Process instances with different sequencing key values can be executed concurrently. Process instances with sequencing keys that evaluate to the same value are executed in the order they were started.minutes — specifies how long (in minutes) to keep stored duplicateKey values.dupKey. you can specify that all process instances should be executed sequentially in the order they were created.engine.pollPeriod. bw.timeout. 0 indicates to store duplicateKey values indefinitely. TIBCO BusinessWorks also allows you to control process execution administratively by setting properties in the deployment configuration of the project.

To accomplish this. the value of the XPath expression is identical for each incoming order. all new orders are executed in the order they are received. The process is a monitoring application that examines data in a database and performs the appropriate action. The orders are placed using a web client and the TIBCO BusinessWorks process definition uses an HTTP Receiver process starter to accept the incoming orders. For example. if the number of rows returned by a query is greater than 5000. Therefore. Figure 36 illustrates the example process definition. If the number of rows is less than 5000. Because you placed a constant in the field. TIBCO BusinessWorks Process Design Guide . see TIBCO Administrator User’s Guide. Example 2: Periodic Processing In this example. Figure 36 Example order-entry system In this example. the Timer process starter is used to start a process every five minutes. the process archives the data to another database and removes all rows from the table. For example.188 | Chapter 12 Process Instance Execution This chapter details examples of using the Sequencing Key field on the Misc tab of process starters to control the order of process execution. you wish to sequentially execute all orders that are accepted by this process definition . the results of the query are processed and stored in a separate table. specify a constant in the Sequencing Key field of the Misc tab of the AcceptOrder HTTP Receiver process starter. Example 1: Processing Orders As They Are Received In this example. an order-entry system must process incoming orders in the order in which they are received. For more information on using TIBCO Administrator to set deployment configuration parameters. Figure 37 illustrates the example process definition. place "OrderEntry" in the Sequencing Key field.

This ensures that all messages from a specific client are processed in the order they are received. Figure 38 Example of handling incoming messages In this example. no updates are occurring to the table. System backups occur at midnight each night. TIBCO BusinessWorks Process Design Guide . This ensures that process instances created each day are completed sequentially in the order they are created. Each JMS client authenticates to the JMS server with a different user ID. process instances are created every five minutes. you can use the expression pfx:ActivityOutput/JMSProperties/pfx:JMSXUserID in the Sequencing Key field of the Misc tab of the JMS Topic Subscriber process starter. a JMS application sends messages to TIBCO BusinessWorks for processing. You must ensure that the data returned by the query is processed before the next query executes.Sequencing Process Instances 189 | Figure 37 Example of periodic processing In this example. Example 3: Handling Client Messages In this example. but the data in the table changes much more frequently. Messages from different clients are permitted to be processed concurrently. but all messages received from the same client must be processed in the order they are received. and there are no changes to the table during this time. you must execute each process instance sequentially before executing the next process instance. Therefore. you can use the XPath expression pfx:TimerOutputSchema/Day_Of_Month in the Sequencing Key field of the Misc tab of the Timer process starter. At the end of the day. so process instances created at the end of each day can execute concurrently with the first process instance created the next day. To configure sequential processing in this scenario.

properties are required by the components used by TIBCO BusinessWorks.org/log4j/docs/.properties file. Do not remove any required properties from this file.properties file before altering it.apache.properties file to allow you to configure logging services for third-party components.properties file has comments describing property usage. you must include all of the required properties from the file supplied with TIBCO BusinessWorks in your file. TIBCO BusinessWorks Process Design Guide . The properties defined in bw/<relNum>/lib/log4j. For example.properties or you can alter the bwengine. This allows you to return to the original configuration if your changes result in errors. If you use your own log4j. if you wish to configure logging for your environment. You can alter the properties in this file.properties file. you can either add the properties to bw/<relNum>/lib/log4j. There can be only one log4j. For more information about log4j.190 | Chapter 12 Process Instance Execution Logging for Third-Party Components TIBCO BusinessWorks can use a variety of third-party components. the Apache Tomcat server is used to accept incoming HTTP or SOAP requests or the Arjuna Transaction Service can be used as a transaction manager. It is a good idea to create a backup copy of the log4j.properties file per Java VM. Many third-party components can use the standard log4j logging services. see http://logging. If you wish to use properties from a different log4j. TIBCO BusinessWorks provides the bw/<relNum>/lib/log4j.tra file to point to the location of your own log4j.properties file. The supplied log4j.

page 192 Data for Inter-Process Communication.| 191 Chapter 13 Inter-Process Communication Executing process instances can communicate and can pass data between each other. page 193 Coordinating Inter-Process Communication. page 195 Examples of Inter-Process Communication. This chapter describes inter-process communication and provides examples of its use. page 195 TIBCO BusinessWorks Process Design Guide . Topics • • • • • Overview of Inter-Process Communication. The General Activities palette contains the Wait and Notify activities and the Receive Notification process starter for implementing inter-process communication. page 194 Database Storage for Wait/Notify/Receive Notification Information.

3. Alternatively. and Notify activities. and any Wait activity that matches that key is executed when the Notify occurs. A string-based key is used to coordinate between Wait/Notify/Receive Notification activities to determine when a Notify activity corresponds to a Wait or Receive Notification. or Wait activities if they are to be used to communicate with each other. the Notify Configuration resources must be the same for the Notify. A process containing a Wait activity waits for another process to execute a corresponding Notify activity. The key is supplied to the Notify activity. Receive Notification. TIBCO BusinessWorks Process Design Guide . Determine the key that correlates processes with Notify activities with the corresponding processes with Receive Notification process starters or Wait activities. TIBCO BusinessWorks provides the Wait and Notify activities and the Receive Notification process starter to handle inter-process communication. 2. You may need process instances to communicate if you wish to synchronize process execution or if your processes must execute in a specific order. The schema supplied to the Notify Configuration resource can be empty. These activities are similar to semaphores in programming. using inter-process communication consists of these steps: 1. In general. The data sent between the activities is defined by a Notify Configuration shared configuration resource. These activities are located in the General Activities palette. The Notify activity only sends information to the Receive Notification process starter or Wait activity that specifies the same Notify Configuration resource. However. See TIBCO BusinessWorks Palette Reference for more information about the configuration requirements for each of these activities. The Notify activity cannot be used to determine when a corresponding Receive Notification or Wait has received the information. Wait.192 | Chapter 13 Inter-Process Communication Overview of Inter-Process Communication TIBCO BusinessWorks allows two executing process instances to communicate. When a Notify activity executes its information is stored until a matching Receive Notification or Wait activity accepts the information. the Receive Notification process starter creates a new process instance when another process executes the corresponding Notify activity. Define the data that must be passed between the processes by creating a Notify Configuration shared configuration resource. if you do not wish data to be sent between processes. Create process definitions that use the Receive Notification. The Notify activity executes immediately and transitions to the next activity.

the Notify Configuration schema used by the Notify/Receive Notification/Wait activities can be empty. The schema for the data is defined in the same way as any other schema is defined. a database must be used to store process instance information. Data for Inter-Process Communication The Notify Configuration shared configuration resource defines the data that the Notify activity passes to the corresponding Wait activity or Receive Notification process starter. the same Notify Configuration resource must be specified by corresponding Notify and Receive Notification or Wait activities. The same Notify Configuration resource is used to configure the Notify activity as well as the Wait activity and the Receive Notification process starter. See Editor on page 50 for more information on specifying schemas. Only activities with the same Notify Configuration resource can communicate with each other. The Notify activity then passes its data to its corresponding Wait or Receive Notification.Data for Inter-Process Communication 193 | 4. Wait/Notify information is stored in a database so that process engines on different machines can share information. See Examples of Inter-Process Communication on page 195 for more specific examples of when inter-process communication is useful. The Wait activity and Receive Notification process starter have output that matches the Notify Configuration specified on their Configuration tab. If you wish only to signal the waiting process to continue but not exchange data. This allows you to use the data passed by the process with the Notify activity in subsequent activities after the Receive Notification or Wait activities. This allows you to map process variables to the Notify activity’s input. The schema in the Notify activity’s configuration appears in the Notify activity’s input schema. However. TIBCO BusinessWorks Process Design Guide . If your process engines are on different machines. The following sections describe these steps in more details.

194

| Chapter 13

Inter-Process Communication

Coordinating Inter-Process Communication
When configuring Receive Notification, Wait, and Notify activities, you must specify a key to coordinate which activities correspond to each other. You can also specify a timeout for how long to keep the information about Wait and Notify activities before it is removed from storage. The following sections describe configuring the key and timeouts for inter-process communication.

Specifying the Key
To configure Receive Notification, Wait, and Notify activities, you must specify a key that correlates Notify activities with Receive Notification or Wait activities. The key is a string that corresponding activities specify to determine when a Receive Notification or Wait activity should accept data from a Notify activity. The key is similar to event keys used in activities that wait for incoming events (described in Event on page 49). The key is a string, but you can use any XPath expression that evaluates to a string when the process instance executes. XPath expressions can be used to specify the key for Wait and Notify activities. The Receive Notification process starter can specify a global variable or a fixed string for its key. Each Notify activity corresponds to exactly one Receive Notification or Wait activity. That is, as a Notify activity executes, the first Receive Notification or Wait activity that matches the Notify’s key can then execute. You can execute many Notify activities with the same key. You can create one-to-one correspondence between Wait and Notify activities so that exactly one process’ Notify activity corresponds to one other process’ Receive Notification or Wait activity. Or, you can create many-to-one relationships so that many Notify activities’ keys can correspond to the Receive Notification or Wait in one process. A Notify, however, always only corresponds to only one Receive Notification or Wait activity. Therefore, once a Notify executes, the corresponding Receive Notification or Wait activity continues processing. See Examples of Inter-Process Communication on page 195 for examples of specifying keys for Wait/Receive Notification/Notify activities.

Timeouts for Notify and Wait
Notify and Wait activities have associated timeouts. Timeouts specify how long information for the Notify and Wait is kept before it is removed from storage.

TIBCO BusinessWorks Process Design Guide

Database Storage for Wait/Notify/Receive Notification Information 195

|

The Notify activity executes immediately and transitions to the next activity in the process definition. However, the timeout value for the Notify activity specifies how long the notification information should be kept. If no corresponding Wait activity executes before the specified timeout, the information is removed. Once notification information is removed from storage, it cannot be accepted by the corresponding Wait activity. The Wait activity causes process execution to pause until a corresponding Notify activity with a matching key executes. The Notify activity can execute before the corresponding Wait activity and its information is then waiting in storage. If the Notify has not executed, the process instance containing the Wait suspends until the Notify occurs or the Wait activity’s specified timeout is reached. The Receive Notification process starter does not have a timeout because it creates a process instance only when a corresponding Notify activity executes.

Database Storage for Wait/Notify/Receive Notification Information
If your process engines are located on different machines, a database is required to store process instance state for inter-process communication. When process engines reside on different machines, they must share information about pending Wait/Receive Notification/Notify activities. A database allows process engines to share process instance state information across machines in a domain. Your deployment configuration must specify a database for process engine storage if you expect process instances on different machines to have corresponding Wait/Receive Notification/Notify activities. See TIBCO Administrator User’s Guide for more information on specifying a database for process engine storage when configuring your deployment.

Examples of Inter-Process Communication
The following sections describe situations where inter-process communication may be necessary.

TIBCO BusinessWorks Process Design Guide

196

| Chapter 13

Inter-Process Communication

Enforcing Order for Process Execution
If you wish process instances to execute in a certain order, you can use Wait and Notify activities to accomplish this. This requires using some portion of the incoming event to determine the order. For example, an application may assign a priority number to incoming orders. This may be important when accepting requests for a limited resource, for example, airplane seats or available space in a university class. The orders must be processed in order of priority to ensure that orders with the highest priority number have access to the resource first. Figure 39 illustrates an example process definition that orders incoming events. Figure 39 Ordering incoming events

In this process definition, new requests are submitted through a web interface. A new process is started for each request, and a priority number (an ordered sequence) is given with each request. The order with priority number 1 is submitted, and processed immediately. When the first order is completed, a Notify is sent with its key set to 1. All other orders transition to the Wait activity. These orders are suspended until a Notify activity is executed whose key is equal to their priority number minus one (that is, the order with the next highest priority number). Using this technique, orders are processed in the order of their priority, regardless of when the order is submitted. All orders create a process instance and then immediately suspend until the notification is sent from the order with the next highest priority.

Multiple Types of Incoming Events Resume a Running Process
Some processes require a "Wait for ..." event (for example, Wait for Adapter Message) to continue processing. This occurs when the process requires an external application to send an additional request. For example, a new order arrives, and because the total is over $100,000, it requires approval before processing. You may notify a group of approval managers by email, then any of the approval managers can respond by email or through a web interface for approval. Figure 40 illustrates this set of process definitions.

TIBCO BusinessWorks Process Design Guide

Examples of Inter-Process Communication 197

|

Figure 40 Multiple event sources to continue a process
Orders can be approved by mail or by web. Whichever Notify occurs first is accepted by the Wait

Incoming Order process handles orders less than $100,000 immediately. Orders greater than $100,000 require approval by a person.

The Wait/Notify activities use the OrderID as the key to determine the order that corresponds to the notification. In this case, it is possible for more Notify activities to execute than Wait activities. You must configure the Notify activities to have an appropriate timeout so that the notify information is removed if it is not used by the associated Wait activity.

Scalability With Incoming Events
You may distribute incoming events across multiple process engines. This allows for greater scalability because the load of incoming events is distributed. However, if you have a "Wait for ..." activity, such as Wait for Rendezvous Message that uses reliable delivery, in your process definition, the incoming event is received by all process instances across the multiple process engines. This can potentially affect the performance because of greater network traffic, depending upon how many process instances are running.

TIBCO BusinessWorks Process Design Guide

198

| Chapter 13

Inter-Process Communication

Ideally, you should create some mechanism so that incoming events are handled outside of the process definition and then routed to only the correct process definition. The Wait and Notify activities can accomplish this. You would replace your "Wait for ..." activity with a Wait activity. Then, create a new process definition that contains a process starter to handle the incoming event. Use the Notify activity to send the data from the incoming event to the correct process instance with the corresponding Wait activity.

Specific Protocol Requirements
Some business processes use protocols with specific requirements that make inter-process communication necessary. For example, you may have a process that starts when a TIBCO Rendezvous Certified Message (RVCM) arrives. Your process may also require a Wait for Rendezvous Message listening on the same subject as the process starter. This specific configuration is difficult to implement because incoming messages create new processes and also are sent to the waiting activities in the process. In the example above, the business requirements necessitate working around the requirements of the RVCM protocol. To accomplish this, you may be able to change your business requirements, or you can use the Wait and Notify activities to create two process definitions. The first process definition accepts all new messages and determines, based on message content, whether the message should start a new process or be passed to an activity in the process waiting for the message. The process executes a Notify activity for the new message, but the key of the Notify is different depending upon whether a new process must start or if the message is to be sent to an executing process. The second process definition starts with a Receive Notification process starter and has a Wait activity in place of the Wait for Rendezvous Message activity. This configuration allows the first process to receive all incoming messages, parse them to determine the appropriate action, and then pass each message to the appropriate process.

TIBCO BusinessWorks Process Design Guide

| 199
Chapter 14

Testing Process Definitions

This chapter describes the testing mode available for stepping through your process definitions and examining process data.

Topics
• • • • • • • Overview of Testing, page 200 Breakpoints, page 201 The Test Panel, page 202 Process Instances During Testing, page 203 Stepping Through a Process, page 205 Colors in Test Mode, page 206 Test Mode Buttons and Menus, page 207

TIBCO BusinessWorks Process Design Guide

In general. testing usually involves setting breakpoints in the process model to stop the running process instances at desired points. Step to Next Activity. Testing a process definition typically involves these steps: 1. you can supply input data to the process before executing it. and the currently executing activity is highlighted as the process instance runs. Select the process definition you wish to test in the project panel. so you may want to use a development system for testing purposes. You can select one of the running process instances to display in the design panel. Set breakpoints in the process definition at points where you wish to stop a running process and examine its state. See Process Instances During Testing on page 203 for more information about process instances in the test panel.200 | Chapter 14 Testing Process Definitions Overview of Testing TIBCO BusinessWorks provides a testing environment for stepping through your process models and determining the sources of errors. See Stepping Through a Process on page 205 for more information. From the test panel you can start process instances or load more process definitions. changes to your process definitions are not reflected in the running process instances. Also. Click the Tester tab on the left of the project panel. Return to design mode before changing process definitions. If the process begins with a Start activity and the Start activity has a schema defined. Testing a deployed project is possible. The current state of the process data is displayed on the Process Data tab of each activity. 4. but might be difficult depending upon the volume of the workload of the system. The engine starts process instances based on the process definitions stored in your project. and so on) in the test panel to either continue through the process instance or to stop the current process instance. Entering the testing environment starts a TIBCO BusinessWorks engine. Use the toolbar buttons (Pause Testing. testing should be done during the design and development phase of a project. 3. 6. This is not possible in a production environment. TIBCO BusinessWorks Process Design Guide . See Breakpoints on page 201 for more information. Once in testing mode. 5. The project panel becomes the test panel. 2. Examine the data of the process by selecting any of the activities in the process.

To set a breakpoint. Using the popup menu on the activity only sets the specified breakpoint. just like conditions for items in an activity’s input. You must use the Set Breakpoint dialog if you wish to specify a condition for the breakpoint. You can also specify that each breakpoint should only occur based on a given condition. Figure 42 illustrates a process diagram that has breakpoints set before and after two activities. Figure 41 Set BreakPoints dialog You can choose to select all of the activities by clicking the Select All button. The only exceptions to this are that you cannot set a breakpoint before the starting activity or after the End activity. TIBCO BusinessWorks Process Design Guide . click the Set Breakpoint button and the Set Breakpoint dialog appears. Breakpoints persist after you close your project — the breakpoints you set should appear in the process definition once the project is reopened. A breakpoint before the activity appears to the top left of the activity. You can clear all set breakpoints by clicking the Clear All button. Figure 41 illustrates an example of the Set Breakpoint dialog. You can set breakpoints before or after an activity executes. You can also set or clear breakpoints on individual activities by right-clicking on the activity and choosing Set/Clear BreakPoint Before/After from the popup menu. a red hexagon (a stop sign) appears next to the task’s icon to indicate the task has a breakpoint. A breakpoint after the activity appears to the top right of the activity.Breakpoints 201 | Breakpoints Breakpoints allow you to suspend a running process instance at a specified point so that you can examine the process data. When a breakpoint is set on an activity. The dialog allows you to select where to place a breakpoint relative to any of the activities in the current process definition. Conditions are specified in XPath.

Figure 44 The test panel TIBCO BusinessWorks Process Design Guide . The project panel then becomes the test panel. then clicking the Tester tab to the left of the project panel. Figure 43 Process instance stopped at a breakpoint The Test Panel You can begin testing a process definition by selecting it in the project panel. the breakpoint icon becomes a stop sign inside a yellow triangle to indicate where the process instance has stopped. Figure 44 illustrates the test panel. The test panel displays process instances created during testing. Figure 43 illustrates the example process definition when the process instance is stopped at the breakpoint before the ReadFile activity.202 | Chapter 14 Testing Process Definitions Figure 42 Setting a breakpoint When a process instance is stopped at a breakpoint.

you can supply input to the process starter by clicking on the Supply Input Data to Starter button on the TIBCO Designer toolbar. TIBCO BusinessWorks Process Design Guide . See Process Instances During Testing on page 203 for more information about process instances in the test panel. This button is not available for processes that do not require input data on the Start activity. the Select Processes to Load dialog appears. Creating Process Instances If the loaded process begins with a Start activity. Processing continues until the End activity is reached. You can select process instances in the test panel and display the process definition. This is useful if you wish to specify a property file containing custom engine properties. If the loaded process begins with a Start activity that requires input.Process Instances During Testing 203 | The Start Testing Viewed Process button allows you to start process instances for one or more process defintions. Loading Processes to Test Once the Start Testing Viewed Process button is clicked. You can select the process definitions you wish to load into the test engine in this dialog. The Advanced button on this dialog allows you to specify any arguments to use when starting the test engine. Process Instances During Testing The Start Testing Viewed Process button allows you to create a process instance for the currently viewed process definition and all of its dependent subprocesses. The test panel has several toolbar buttons for manipulating process instances. See Setting Custom Engine Properties for the Testing Environment on page 238 for more information about specifying custom properties in a test engine. The Test Engine Database field specifies the JDBC Connection resource to the database you wish to use. one process instance is created to execute the process definition. See Test Mode Buttons and Menus on page 207 for a complete description of the buttons in the test panel. You can also select other process definitions to load as well. You can also specify a database to use for storage of process engine information.

(completed job). A new process instance for that process definition is created. This menu contains the item Create a Job that performs the same function as the button on the test panel toolbar. When a job is selected in the test panel. You can create new process instances of any loaded process using the Create a Job button in the test panel. or (failed) to (viewed job). If a process instance fails to complete. Select a process definition in the test panel. or failed job. the process engine waits for an incoming event before creating a process instance. Each incoming event causes a process instance to be created. its description is changed to (completed job) in the test panel. You can view any running. its description is (running) in the test panel. You can also select and right-click on a process definition name in the test panel to bring up a popup menu. Figure 45 illustrates process instances and their labels in the test panel. Once a process instance completes its processing (that is. You can select any process instance in the test panel and view it in the design panel. Adapter Subscriber). completed. its description is changed to (failed). When a process instance is running. its process definition is displayed in the design panel and its description changes from (running). Working With Process Instances Each process instance is independent in the test panel. Figure 45 Multiple process instances in the test panel TIBCO BusinessWorks Process Design Guide .204 | Chapter 14 Testing Process Definitions If the loaded process begins with a process starter (for example. You can start/stop/step through each process instance individually. and each process instance is listed in the test panel. then click the Create a Job button. its End activity is reached).

You must exit test mode and re-enter test mode for changes to take effect. The currently highlighted activity is executed after you choose your next step. activities are executed as you pass them. the process executes all activities up to the activity with the breakpoint. step into or out of a subprocess. processing halts at that breakpoint. When you choose to step through a process.Stepping Through a Process 205 | You can stop the execution of a process instance by selecting it and clicking the Stop the Current Job button in the test panel. When stepping through a process definition. all transitions that evaluate to true are taken. You can step to the next activity. For example. you can step through the process using the toolbar icons or menu items. Stepping Through a Process When you set a breakpoint in a process definition. or you can choose another activity later in the process definition and execute from the current point to that later activity. and you must choose Step Out of Subprocess again to continue processing. if you are currently in a subprocess and you choose the Step Out of a Subprocess menu item or toolbar icon. no matter which menu item or toolbar icon you choose. but changes will not take effect during the current testing session. Once the breakpoint halts processing. execution continues until the next breakpoint occurs or processing of the subprocess completes. but only one path is chosen to be highlighted as the next activity when you choose Step to Next Activity. You can browse or change any process definition or any activity’s configuration while testing. Stepping through the process allows you to examine the executing process instance at your own pace. You can delete any completed or failed process instances from the test panel by selecting the process instances and clicking the Delete a Completed Job button . See Test Mode Buttons and Menus on page 207 for more information about the toolbar icons and menu items that allow you to step through a process. breakpoints are still honored. If there are multiple paths in a process definition. TIBCO BusinessWorks Process Design Guide . If there is a breakpoint before the subprocess completes.

Yellow activity The activity is currently executing. but it is the next activity to execute when the process instance continues. This can occur if you have multiple paths in your process definition and the focus is not on the current path. Table 21 Colors in test mode Color/Element Black transition arrow Green transition arrow Description The transition has not yet been evaluated. The process definition is paused at this activity. The activity has not yet executed. the elements of the process change colors depending upon what is occurring in the executing process instance. The transition has been evaluated. and its condition evaluates to true. but the focus is not on the activity. Table 21 describes the colors of each element in a process definition and their significance. This could be either because the activity has a breakpoint set or because the Step to Next Activity or Run To This Resource menu item was used.206 | Chapter 14 Testing Process Definitions Colors in Test Mode When you test a process definition. Therefore the transition is not taken. Therefor the transition has been taken to the next activity. Red transition arrow Red activity Bright yellow activity TIBCO BusinessWorks Process Design Guide . The transition has been evaluated. and its condition evaluates to false. The activity encountered an error while processing. Any Call Process activity that calls a process in which an error occurs is also red.

Test Mode Buttons and Menus 207 | Test Mode Buttons and Menus There are buttons and icons on the TIBCO Designer toolbar used when testing process definitions. there is no toolbar icon. This icon is enabled only for process definitions that begin with a Start activity that requires an input schema. Table 22 Toolbar icons for testing Button/ Icon View > Test Options Menu Item Set Breakpoints Description Brings up the Set Breakpoint dialog that allows you to specify which activities should have breakpoints. Displays the process definition with which you began this testing session. Allows you to specify data for the process starter’s input schema. There is also a View > Test Options menu that performs the same actions as the toolbar buttons. Information icon displayed when a process engine has been started for testing process definitions. You can use this dialog to save the input data you supply to disk. Table 22 describes these buttons and menu items. This brings up a dialog for creating an input schema. Go To Started Process This item is available only on the View>Test menu. Add Input Data TIBCO BusinessWorks Process Design Guide . Breakpoints stop the process instance and allow you to examine process data before the process continues.

208 | Chapter 14 Testing Process Definitions Table 22 Toolbar icons for testing Button/ Icon View > Test Options Menu Item Moving Ball Options Description This item is available only on the View>Test menu. TIBCO BusinessWorks Process Design Guide . Table 23 Test panel icons Button/ Icon Tools > Tester Menu Item Start Description Allows you to load the viewed process and select any other proceses you wish to to load. The process definitions are loaded into a process engine. You can also set the speed of the moving ball. Return to design mode by using the Stop Testing icon if you want to add/remove/change process definitions. There is no toolbar icon. Brings up a dialog that allows you to set whether the moving ball is displayed. The test panel also has several buttons for manipulating the process instances during testing. Resume Resumes any process instances that are paused or stopped at a breakpoint. Table 23 describes these buttons and menu items. The moving ball shows the current execution path. Once in testing mode. your process definition cannot be changed. The Tools > Tester menu has menu items that perform the equivalent actions as these buttons. All dependend subprocesses for any loaded processes are also loaded.

if the current activity is FTP Put and you are attempting to place a very large file on the remote server. Once a Call Process activity is reached. Step Out After stepping into a subprocess. Note: In some situations. Step Over Step Into TIBCO BusinessWorks Process Design Guide . this button may not stop the process immediately because TIBCO BusinessWorks might be waiting for the current operation to be completed. For example. All process instances are removed from the test panel. the process engine stops only after the FTP command has completed. this icon allows you to display the process definition of the called process and step through it. or a timeout has been reached. You must click the Start icon to start another engine if you wish to resume testing. This icon is only available when you are in a subprocess. This icon is only available when Call Process is the next activity to be processed. Resume the process instance with the Resume icon. When a process instance is paused on an activity. this toolbar icon can be used to return to the process that called the subprocess. failed. Pause Temporarily suspends the process instance. click this icon to step ahead in the process definition and execute the next activity.Test Mode Buttons and Menus 209 | Table 23 Test panel icons Button/ Icon Tools > Tester Menu Item Stop Description Kills the current engine and exits testing mode.

Stop Current Job Stops the currently executing process instance. There are also menu items on the popup menus for each activity in a process definition. You can access these menu items by right clicking on the activity. Clear Breakpoint Before. you can change focus to display or edit other resources in your project. This is useful if you wish to examine the data of the process instance. This menu has the item Create a Job that performs the same function as the button in the test panel. Deletes the selected jobs marked as (completed job) from the test panel. Focus returns to the highlighted activity in a process where the process instance is paused. Creates a new process instance for the selected process definition. but does not exit test mode. You can only delete completed jobs. These are the popup menu items for activities that are used in testing: Set Breakpoint Before. The Set/Clear Breakpoint Before/After menu items sets or clears the specified breakpoint on the selected activity. You can also select and right click a process definition name in the test panel to bring up a popup menu. Set Breakpoint After. and Run To This Resource. Clear Breakpoint After.210 | Chapter 14 Testing Process Definitions Table 23 Test panel icons Button/ Icon Tools > Tester Menu Item Show Current Job Location Description When a process instance is paused at a breakpoint or any other point. but you do not want to continue running the process. TIBCO BusinessWorks Process Design Guide . This icon and menu item allow you to return focus to the process definition for the currently running process instance.

Test Mode Buttons and Menus 211

|

The Run To This Resource menu item executes the running process instance up to the selected activity. For example, if a process instance is halted on a breakpoint, selecting an activity later in the process definition and choosing the Run To This Resource menu item resumes processing of the process instance and executes all activities between the breakpoint and the selected activity. The process instance pauses when it reaches the activity where you selected the Run To This Resource menu item.

TIBCO BusinessWorks Process Design Guide

212

| Chapter 14

Testing Process Definitions

TIBCO BusinessWorks Process Design Guide

| 213
Appendix A

Working with a Revision Control System

This appendix gives detailed instructions for working with each supported revision control system (RCS). For background information, see the documentation for the revision control system.

Topics
• • • • • • Overview, page 214 File Sharing, page 216 Microsoft Visual SourceSafe, page 218 Perforce Fast Software Configuration Management System, page 221 XML Canon, page 224 Tips and Tricks for Using Version Control Systems, page 234

TIBCO BusinessWorks Process Design Guide

214

| Appendix A

Working with a Revision Control System

Overview
TIBCO Designer allows multiple developers to work on the same project. Developers can use file sharing/locking or a revision control system to ensure that the same resource is not changed by two developers at the same time. If you wish to use file sharing/locking or a revision control system, you must use a multi-file project. Different users can then add resources to the project and lock the parts of the project they are working on. TIBCO Designer creates a file that can be shared and locked for each top-level resource, such as an adapter configuration or a process definition. It does not create a file for each resource. As a result, for example, you can lock an adapter configuration but cannot lock individual adapter services. TIBCO Designer also creates folders for folders you create in your project. You can lock each folder as needed. The following revision control options are available: • • • File Sharing — Allows you to place the project in a central location, then lock and unlock resources as needed. See File Sharing on page 216. Microsoft Visual SourceSafe — Allows multiple users to take advantage of the Visual SourceSafe features. See Microsoft Visual SourceSafe on page 218. Perforce — Allows multiple users to take advantage of the Perforce software revision control system. See Perforce Fast Software Configuration Management System on page 221. XML Canon — Allows multiple users to take advantage TIBCO XML Canon. See XML Canon on page 224.

You interact with the revision control system directly from TIBCO Designer. TIBCO Designer also allows you to check who owns the lock for each locked resource. Designer may not always have all of the information necessary to distinguish some situations correctly. For example, TIBCO Designer sometimes is unable to distinguish a deleted file from the RCS that should be deleted in your personal copy of the project from a file you added to your copy of the project and want to add to the RCS. In such cases, use the RCS client directly to fix these situations.

TIBCO BusinessWorks Process Design Guide

Overview 215

|

Icons Used by RCS Projects
To illustrate the state of the resource in a project under revision control, TIBCO Designer uses icons on top of each resource in the project panel. A lock icon indicates that the resource was checked into the revision control system. Other users may be making changes. You need to check out the resource to safely make changes. A yellow square icon indicates that the RCS does not know about this resource or its state. If the resource is new, you have to add it to the RCS. If it has been checked in before, it has to be checked in again. A red square indicates, on systems that support that functionality, that another user has locked the resource. Note that is functionality is not supported for all RC systems. If no special icon is displayed, the resource has been checked out and is in the same state as the corresponding RCS resource.

Deleting RCS Projects
You delete a project that uses a revision control system as follows: 1. In the Startup panel, click the Delete project button (just as for other projects). 2. In the Delete project.
Project

dialog that appears, supply the information about the

— For projects that use File Sharing, use either the None or File Sharing Revision Control System and any user name, supply the project location. — For Visual SourceSafe and Perforce you must make sure that the project listed in the Project Directory field corresponds to the project checked into RCS. 3. Click OK. The project is deleted. For Visual SourceSafe and Perforce, it is deleted in both the local and the check-in location.

TIBCO BusinessWorks Process Design Guide

216

| Appendix A

Working with a Revision Control System

File Sharing
This section discusses using File Sharing as a Revision Control System in the following sections: • • • • Preparing for File Sharing on Microsoft Windows on page 216 Preparing for File Sharing on UNIX on page 216 Using File Sharing on page 216 Deleting RCS Projects on page 215

Preparing for File Sharing on Microsoft Windows
The project is located on a shared drive accessible by all TIBCO developers. Make sure all TIBCO developers have read and write access to that drive.

Preparing for File Sharing on UNIX
The project must be located on a mounted drive accessible by all TIBCO developers. You then go through these steps: 1. Create a Unix group for the TIBCO developers (for instance "tibdev"). 2. Create a Unix account for each developer. Each account must have its Primary Group ID set to the group "tibdev". 3. For each account, the umask must be set to 002 to ensure the entire group has write permission on resources (folder and file) in Designer projects. Set the umask in the .login or .profile file, as follows:
$ umask 002

Using File Sharing
Allowing multiple users to use file sharing for a project involves these tasks: Task A Create the Project 1. Open TIBCO Designer and open the project (which could be a new empty project). 2. Choose Project > Save > Multi-File Project.

TIBCO BusinessWorks Process Design Guide

File Sharing 217

|

3. In the dialog that appears: d. Supply the root directory for the project (which will become the project name). This directory should be on a drive that can be accessed by all developers that work on the project. e. Choose File Sharing from the pop-up. f. Supply your username. This username will be seen by other users as the owner if you lock files in the project.

Task B User A Acquires Resource and Makes Changes The creator of the project or another user can now acquire the lock for the project and, for example, add two folders. Here are the steps: 1. User A selects the project root folder. 2. User A chooses Multi-User > Acquire Resource. That command is also available from the resource’s right-button menu or from the Project menu. 3. User A drags two Folder resources into the design panel and names each for the user who will work with it. 4. User A selects the folder for the second user (User B) and chooses Release Resource from the right-button menu. The folder now appears locked in the TIBCO Designer project panel.
Lock Acquired by User A Lock Released by User A

5. User A opens the UserA folder and adds two resources to it, then selects each resource and chooses Add Resource to RCS from the right-button menu. User A can make changes to the UserA folder (but not to the UserB folder). 6. User A saves the project. Task C User B Opens Project, Acquires Resource, and Makes Changes A second user can open the same project and make changes to all folders not currently locked by another user. For this example: 1. User B opens the project (all project elements are locked). 2. User B selects the User B folder and chooses Acquire Resource from the right-button menu. The lock for this folder was released by User A.
TIBCO BusinessWorks Process Design Guide

Install a Microsoft Visual SourceSafe 6. and save the project when she is done.218 | Appendix A Working with a Revision Control System 3. User B cannot acquire the lock for the project root folder or for User A Folder because both are locked by User A.0 Client on each machine from which you wish to use TIBCO Designer in conjunction with a Visual SourceSafe database. User B can now make changes to User B folder as desired. set the ssdir environment variable to the location of the Visual SourceSafe database. follow these steps: 1. Only the Client Programs component is necessary on the machine where TIBCO Designer runs. To make the Visual SourceSafe database available. TIBCO BusinessWorks Process Design Guide . then includes reference documentation to the Version Control dialog in the following sections: • • Visual SourceSafe Setup on page 218 Using Microsoft Visual SourceSafe on page 219 Microsoft Visual SourceSafe is not supported under UNIX.htm file included with your client explains how to do this on the command line: set ssdir=\\server\share\vss Where \\server\share\vss is the folder where the Srcsafe.ini file in the VSS database is located. 2. The ReadMess. Microsoft Visual SourceSafe This section first discusses prerequisites and looks at a usage scenario. Visual SourceSafe Setup To set up your system to work in conjunction with the TIBCO Designer Visual SourceSafe component.

User A opens TIBCO Designer and chooses New Empty Project. as in the example below. your SourceSafe client cannot find the database where the shared project is located. 2. Password—Password for the current user. Include the root directory and other directories. Using Microsoft Visual SourceSafe Step 1: User A Starts TIBCO Designer and Creates a VSS Project To create a VSS project. If you do not set this variable.Microsoft Visual SourceSafe 219 | You can also set this variable permanently using the control panel. specify the following information: — — — Project Directory—Location Multi-User System—Visual of the project on the local drive. which is the command-line executable for VSS that is used by TIBCO Designer. The user must have been granted access to VSS during the VSS client installation. User A follows these steps: 1. SourceSafe User Name—Name of the current user. Ask your VSS administrator. — — — Figure 46 Save Project Options for Microsoft VSS TIBCO BusinessWorks Process Design Guide .EXE executable on your machine. Ask your VSS administrator.EXE. VSS Project Name—Name of the project in the VSS database. Note that you must use SS. In the dialog that appears. as specified during the VSS client installation. VSS Command—Click Browse to point to the SS.

User B can choose Multi-User > Check In Changes. you check in the resource. If User B adds new resource. User A adds resources to the project and configures them. they may be checked out when you check out the top-level resource. then chooses Multi-User > Add Resource to RCS. Whether this happens depends on the directory structure TIBCO Designer creates. Step 3: User B Checks Out Resources and Makes Changes After User A has checked the whole project into VSS for the first time. All resources are now locked and can be checked out by other users as needed. If you check out a resource that contains other resources. 2. User A saves the project. the check-in console. then chooses Acquire-Check Out Resource from the right-button menu of the resource. you must add. User B selects a resource to be checked out in the project tree. After User A has supplied a label for this version. User B can now make changes to the checked-out resource. Using the TIBCO Designer GUI. If a resource has never been added to RCS. each resource must first be added to the RCS using the Add Resource to RCS menu. 1. which shows the check-in information. 4. each resource can be checked out by each user that has access to VSS. is displayed. 2. User B opens the project from TIBCO Designer. using the Visual SouceSafe as the Revision Control system and providing a username and password. check-in and synchronization is always all or nothing TIBCO BusinessWorks Process Design Guide . User B chooses Multi-User > Project > Synchronize Project to make sure all resources are loaded. If you make additional changes. 3.220 | Appendix A Working with a Revision Control System Step 2: User A Makes Changes to Project and Checks In the Project User A can now make changes to the project and check them in as follows: 1. After all changes have been made. While you can add and checkout recursively.

and requires minimal administration. Every Perforce port has a unique password. Setup a password for your Perforce account. developers can access the Perforce Server through a variety of Perforce clients (Windows GUI. • Install the Perforce software. • • The Perforce server port must be defined. or Command-Line). You can define a new client in the Perforce clientSpecs >New menu. You may need to define a password for all the Perforce ports you access normally. Only the client is necessary on the machine where TIBCO Designer runs. and modify the files you wish to work with under Perforce. — The Perforce server must be installed and running. Requiring only TCP/IP. delete. — The Perforce client must be installed on your machine. TIBCO BusinessWorks Process Design Guide . • • Select the client you use to use or define a new client with any name. Prerequisites Before attempting to use Perforce you must ensure the following procedures have been taken. Perforce is supported on a large number of operating systems. To do this in Microsoft Windows. Web. Assigning user name and passwords may be done by the Perforce administrator at your site. store. Perforce can be deployed quickly and easily. create. TIBCO Designer does not include or install this software. select User > Set Password for UserName. even for large or distributed sites.Perforce Fast Software Configuration Management System 221 | Perforce Fast Software Configuration Management System Perforce has comprehensive software configuration management capabilities built around a scalable client/server architecture. Be sure that you have the appropriate permissions to access.

Use this option to test the validity of the information you are using to access Perforce. 2. — Multi-User System—Perforce— This selection also enables the Test Configuration option. of the current user. Perforce Client—This is the same as Client entered in Perforce Client Specification. ISO8859-1—Default value. If you set your default client in the Perforce native UI you don't need to fill in the user/server type fields when you access Perforce from Designer TIBCO BusinessWorks Process Design Guide . such as Japanese. Server—The port on which you access the Perforce server. as specified during the Perforce client installation.EXE executable on Perforce Command—Click your machine. that is. See TIBCO Adapter Concepts for a discussion of how TIBCO adapters support Unicode. User A follows these steps: 1.222 | Appendix A Working with a Revision Control System Using Perforce Step 1: User A Starts TIBCO Designer to Create a Perforce Project To create a Perforce project. User A opens TIBCO Designer and chooses New Empty Project. Use this option if you ONLY intend to use TIBCO Rendezvous for English and Western European data. — — — — — — User Name—Name Password—Password for the current user. This is the same as Owner entered in Perforce Client Specification. UTF-8— Select this option if you want to use TIBCO Rendezvous activities for processing non-Western European data. This is a project-wide preference. Encoding—This field is used to determine the wire encoding that TIBCO Rendezvous should use for sending and receiving data in this project. Timeout (seconds)—Amount of time available to connect with the Perforce server before a timeout occurs. location where the project is placed by Perforce when you synchronize. User A specifies the following information: — — Project Directory—Location of the project on the local drive. In the dialog that appears. Browse to point to the P4.

After User A has supplied a label for this version. you check in the resource. TIBCO BusinessWorks Process Design Guide . User A saves the project. the check-in console. you must add. which shows the check-in information. User A adds resources to the project and configures them. All resources are now locked and can be checked out by other users as needed. If you make additional changes. each resource can be checked out by each user that has access to Perforce. Using the TIBCO Designer GUI. 2. If a resource has never been added to RCS. is displayed. Step 3: User B Checks Out Resources and Makes Changes After User A has checked the whole project into Perforce for the first time. then chooses Multi-User > Add Resource to RCS.Perforce Fast Software Configuration Management System 223 | Figure 47 Save Project Options for Perforce Version Control System Step 2: User A Makes Changes to Project and Checks In the Project User A can now make changes to the project and check them in as follows: 1.

they may be checked out when you check out the top-level resource. User B can choose Multi-User > Check In Changes. repurposement. XML schemas. If you check out a resource that contains other resources. User B selects a resource to be checked out in the project tree.224 | Appendix A Working with a Revision Control System 1. You can add or check in resources recursively. then chooses Acquire-Check Out Resource from the right-button menu of the resource. If User B adds new resource. 4. XML Canon XML Canon/Developer (XCD) is a comprehensive development platform that allows organizations to store their XML assets (e. XML Canon is an entire persistence system that has some RCS capability but not a multi-file project per se.g. instance documents. protecting the development process from duplicate or conflicting efforts. Whether this happens depends on the directory structure TIBCO Designer creates. XML Canon also provides version control. 3. User B chooses Multi-User > Project > Synchronize Project to make sure all resources are loaded. 2. XML Canon uses permissons to control access to the stored files. TIBCO BusinessWorks Process Design Guide . collaboration. each resource must first be added to the RCS using the Add Resource to RCS menu. User B can now make changes to the checked-out resource. adjuncts. After all changes have been made. using the Perforce as the Revision Control system and providing a username and password. and stylesheets) in a central repository that facilitates adaptability. and other required information. User B opens the project from TIBCO Designer. and management. DTDs.

an XML Canon user name and password with the permissions required to work in the XML Canon category in which the shared project is stored. the typical steps for interacting with XML Canon.XML Canon 225 | Features The following features. XML Document Differencing—track changes between revisions. for example) are used in the project. are provided for the XML-based files in your project. The remainder of this section describes the process for specifying XML Canon as the repository for a project. accessible via XML Canon's web interface. beginning with the initial association of the TIBCO Designer project with an XML Canon category. • • • • • • Custom Property Association—apply custom metadata to documents or individual components. For more information on XML Canon. Document and Component-Level Searching—query for document and components through a wide array of filters. SchemaDOC™—generate a graphical inventory and detailed description of an XML Schema’s or DTD’s components in a user-friendly HTML format. such as your XML Schemas. see the XML Canon Developer documentation available as online help with the product and also via the TIBCO documentation library. Checking In and Acquiring Resources This section provides the typical steps involved in interacting with the XML Canon repository. you must have: • • the address of the XML Canon server and the port number on which it is running. Document/Component Relationship Tracking—track the relationship between documents and their components and determine where schemas or individual components (XML Schema elements or types or WSDL message components. and some tips and tricks that will facilitate the effective use of XML Canon. WSDL files and process definitions. Prerequisites To use XML Canon as the version control system for TIBCO Designer. TIBCO BusinessWorks Process Design Guide . Namespace Management—browse through a listing of target namespaces and see how a given namespace is used in schema and instance documents.

the Save Project dialog appears automatically by default. as depicted in Figure 49. Each project should be associated with a unique XML Canon category. As a result. Password—password associated with the user name. Make sure the proxy server supports required additional functionality. To specify XML Canon as the version control system for a given project. Select the XML Canon tab. select Project > Save As to display the Save Project window. Upon successful authentication.226 | Appendix A Working with a Revision Control System Step 1: Specifying XML Canon as the version control system for a given project This step is performed once for a given project. which will serve as your top-level project folder. the proxy server you specified is taken into account. it is essential that you specify the proxy server before you click Browse.When you open a new empty project. you will be presented with all of the top-level categories. click Browse. The Browse for Project Folder will appear. • XML Canon category—the URL (http://hostName:portNumber/categoryName) of an empty XML Canon category. Figure 48 XML Canon tab If you do not know the location of an empty category. TIBCO BusinessWorks Process Design Guide . • • User name—an XML Canon user name. If you click the Browse button for the XML Canon category field. You will be prompted to enter your XML Canon user name and password. Enter the URL for the XML Canon server and click Connect. Not all proxy servers support the WebDAV extensions to HTTP that XML Canon uses. Figure 48 depicts the XML Canon tab filled in with the required information. which requires you to specify these fields: • Proxy server—You may access XML Canon via a proxy server that does not require authentication.

modified. user name. moved. The XML Canon Check In dialog is shown in TIBCO BusinessWorks Process Design Guide .The specified XML Canon category will now be used to store the project. When you have selected the category in which to store the project. or deleted since the project was last checked-in. Step 2: Check in the project The folders and resources existing in the project prior to Step 1 can be checked into XML Canon by way of the Check In Changes option of the Multi-User menu.XML Canon 227 | Figure 49 Browse for an XML Canon category Double-click a category (or use the Open button) to view its child categories. If you are unable to create a new category. Some XML Canon users may not have the ability to create a new category. click Select Folder. and password have been specified on the XML Canon tab. The XML Canon Check In dialog appears. When a URL. New categories can be created using the new folder icon. see your XML Canon administrator. See Step 2: Check in the project to learn how to make the existing resources in the project accessible to all XML Canon users with the permissions to work in the category. listing the folders and files that have been added. click OK.

TIBCO BusinessWorks Process Design Guide . Checks in the changes associated with the selected files or folders. Check-in options are controlled with the following buttons: Button Close Undo Check in selected Check in all Description Closes the window without checking in any files. Reverts the selected folders or resources to their status prior to the last acquire-check out.228 | Appendix A Working with a Revision Control System Figure 50 XML Canon Check In Dialog Global variable settings will appear in the dialog as "defaultVars". Checks in all of the changes.

a revision label. • The "stage" that the document is currently in does not allow a transition to itself (for example. If the XML Canon Administrator has configured your server to use custom properties. To set all properties. By default you may specify a comment.". your XML Canon user profile may not have the appropriate permission settings. If you are unable to check in changes. indicating that the files are not acquired and cannot be edited. See your XML Canon administrator. or The administrator has specified "custom properties" that are required. it may not be possible to save changes to XML Canon unless you have specified extended properties.XML Canon 229 | Button Properties Description XML Canon augments standard WebDAV functionality by allowing you to specify additional properties when a document is saved. Depending on how the server is configured. or Double-click an item. you may also specify those custom properties.. Figure 51 depicts a project checked into XML Canon. then click "Properties. you: • • Select a file in the "Check In" dialog. Items for which the user has already specified custom properties are shown in bold in the dialog. TIBCO BusinessWorks Process Design Guide . • Checked-in items become marked by a lock icon in the project panel. a "production" document cannot be modified without taking it out of "production").. Figure 51 A project checked into XML Canon. and the document may not be saved unless those properties are specified. This can happen for two reasons. and a stage.

Upon successful authentication. To open a project stored on XML Canon 1. Global variables are acquired through the Acquire-Check out Global Variable Group option of the right-button menu or the Acquire-Check out Global Variable Group icon appearing at the bottom of the global variable display. it cannot be modified by other users. Folders and resources marked by a lock icon are read-only until acquired. for example) as well as any changes made by other users. 2. To acquire a resource 1. Use the global variables display to acquire global variables. Specify (or browse for) the XML Canon category in which the project is stored 3. Select the resource in the project tree 2. Once a resource is acquired by a user. When a resource is acquired. its lock icon will disappear. TIBCO BusinessWorks Process Design Guide . the message shown in Figure 52 will appear. Upon opening a project shared through XML Canon. the project will be opened. you should synchronize the project (Multi-User>Synchronize Project). indicating that you may edit the file.230 | Appendix A Working with a Revision Control System Step 3: Acquiring folders or resources and making changes Once a project has been associated with XML Canon (see Step 1) and checked-in for the first time (see Step 2). but cannot make changes to it. (Other users can view the resource.) If you attempt to acquire a resource that is under the control of another user. Synchronize often to ensure that your project tree reflects any resources you have added outside of TIBCO Designer (through a WebDAV folder or the XML Canon interface. its resources can be acquired (checked out) by other users with access to the XML Canon server and with permission to work in the category associated with the project. Select the XML Canon tab from the Open Project dialog. Select Acquire-Check out Resource from the right button menu or the Multi-User menu. Supply a user name and password.

Viewing Revision Control Information The revision control system (RCS) information for a particular resource can be viewed by selecting the View RCS Info for Resource option from the right-button menu or the Multi-User menu. This applies to XML Schema. available via the right-button menu and the Multi-User menu. following the same procedure outlined in Step 2. and WSDL resources only. Select the modified folder or resource in the project panel and select the Release-Revert Resource option. The information available is described in Table 24. TIBCO BusinessWorks Process Design Guide . DTD.XML Canon 231 | Figure 52 Acquire failed Step 4: Checking in (or reverting) the changes made to an acquired resource Changes made to acquired resources can be checked into XML Canon. Reverting Changes There are two options for returning a folder or resource to its status prior to your acquisition: • • Select the change(s) in the Check In Changes Dialog and click Undo Changes. Table 24 Revision control system information Field Analyzed state Description This indicates if the resource was analyzed for document and component level relationships.

The name of the resource. The time and date of the last modification. The size of the resource in bytes.232 | Appendix A Working with a Revision Control System Table 24 Revision control system information Field Comment Creation date Display name Document flavor Document id Document size Governing namespace Description Displays any comments added when checking the resource into XML Canon. The number of times the resource has been checked into XML Canon. The XML Canon internal id for the resource. The XML Canon internal id of the user making the last modification. the value of the 'targetNamespace' attribute. The user who has acquired the resource. The name of the user making the last modification. The WebDAV resource type. Globally unique identifier for the resource being acquired (locked on the server). A revision label added when checking the resource into XML Canon. Namespace that the document governs. The XML Canon internal stage id for the resource. The default namespace of the resource. The Multipurpose Internet Mail Extension. in XML Schema. Last modified Last modified by Last modified by id Lock token Locked by Mime type Resource type Revision name Revision number Root namespace Stage id Stage name TIBCO BusinessWorks Process Design Guide . The date the resource was created. The resource type. The XML Canon stage of the resource. for example.

DTDs and WSDL files. Tips and Tricks The following tips will help you use XML Canon effectively as a version control system. a new child folder cannot be checked in until its parent folder is checked in. Deleting XML Canon Projects XML Canon-based projects cannot be deleted in TIBCO Designer. Acquisitions are not recursive. For XML Schemas. its resources and sub-folders are not checked-out. A folder must be acquired if you want to: • • • • TIBCO BusinessWorks Process Design Guide . You can apply custom metadata to the resources through the DAV tab of the user’s XML Canon home page. Any conflicts discovered during the synchronization process will be listed along with instructions for resolving the conflict. the other change will also be checked in.) If you check in a single change (using the Check in selected button) with a dependency on another change. the Add Resource to RCS option of the right-button menu Multi-User menus is not applicable when working with XML Canon. To delete a project.XML Canon 233 | Table 24 Revision control system information Field Supported lock Description The WebDAV locks allowed on the resource. (For example. use a WebDAV client. When you acquire a folder. custom properties can be specified for individual components as well. Because XML Canon automatically treats all of the project’s resources as part of the Revision Control System. When checking in changes. • • Synchronize (Multi-User > Synchronize Project) often to ensure your project reflects the changes made by other users. You cannot check in any changes until synchronization conflicts are resolved. keep in mind that some changes are dependent upon other changes.

TIBCO BusinessWorks Process Design Guide . Even though the capability of adding to a locked folder is there. delete. and rename resources in that folder. See Table 25 and Table 26 below. In the table: • Locked means either checked out by someone else or not checked out. If you do. delete the folder Tips and Tricks for Using Version Control Systems The following techniques will help you use your version control system (File Sharing or Visual SourceSafe) effectively: • Check in and synchronize on a regular basis. If you do. • • • • • Access Rights on Resources The following two tables illustrate the access rights on unlocked resources when the parent folder is or is not locked. for example. Do not keep the AESchemas folder locked. only the folder owner can add. When several users work in the same folder. Structure your project so each user owns a folder and works in it. other users cannot add resources in it (not even their own folder). Structure your project so that each user owns a folder in the AESchemas area. and sometimes you can add resources to folders even if someone else has checked out that folder. Do not keep the root folder locked. Sometimes a check-out is recursive (optional or forced). The information displayed by TIBCO Designer may not be completely accurate if there are a large number of differences between the project in TIBCO Designer and the project in VSS.234 | Appendix A Working with a Revision Control System a. other users cannot add resources in it (not even their own folder inside AESchemas). Do not lock folders unless you have to. edit the folder’s description d. it can still cause problems. if two people attempt to add a resource with the same name. move the folder c. rename the folder (or one of its resources or sub-folders) b.

and linking to another location. copy. copying. and link refer to moving. Move. The following table illustrates the access rights on locked resources. Table 25 Actions on resources that are not locked Action on Resource Folder is Locked Folder is not Locked Add N Y Delete N Y Modify Y Y Rename N Y Move N Y Copy Y Y Link Y Y Note that when the folder is locked.Tips and Tricks for Using Version Control Systems 235 | • Move. In the table: • • Locked means either checked out by someone else or not checked out. Table 26 Actions on locked resources Action on Resource Folder is Locked Folder is not Locked Add N Y Delete N N Modify N N Rename N N Move N N Copy Y Y Link Y Y TIBCO BusinessWorks Process Design Guide . and linking to another location. copy. copying. you are able to modify the resource but not rename it. and link refer to moving.

236 | Appendix A Working with a Revision Control System TIBCO BusinessWorks Process Design Guide .

page 240 Available Custom Engine Properties. Topics • • • • Overview of Custom Engine Properties. This appendix describes the custom properties that can be altered. page 238 Setting Custom Engine Properties in Deployed Projects. page 241 TIBCO BusinessWorks Process Design Guide .| 237 Appendix B Custom Engine Properties TIBCO BusinessWorks process engines can be configured using custom properties in configuration files. page 238 Setting Custom Engine Properties for the Testing Environment.

238 | Appendix B Custom Engine Properties Overview of Custom Engine Properties The TIBCO BusinessWorks process engine is responsible for running instances of your process definitions.Role. \ . Properties that have variable portions can use the wildcard character (*) to indicate the property should be set to the specified value for all potential names. and the property name can be variable. equal sign. The following sections describe how to set custom engine properties and list the custom properties that you can set. Custom properties are also available for configuring the maximum and minimum number of connections for the HTTP server that handles incoming HTTP requests for TIBCO BusinessWorks. For example. For example. Trace. For example. Setting Custom Engine Properties for the Testing Environment TIBCO Designer runs a process engine when you test process definitions using the Tester tab.* is the property to control tracing for all roles. Property names and values can be separated by either a space ( ). you must create a properties file and specify its location. you can specify custom properties in the engine’s configuration files to configure the process engine to suit your needs. an equal sign (=). If a property value contains a space. you must escape these characters in the property value by using a \ (for example.error = false Some properties can be set for specific process definitions or activities. To set custom properties for the process engine that TIBCO Designer runs. or colon. This prevents any trace messages for the role named error from being written to the log file or console. You can place comments in the configuration files by placing a hash (#) as the first character in a comment line.Role. However. or \:). Perform the following procedure to set custom engine properties for the testing environment.error to false. custom properties are available for enabling/disabling and setting the level of tracing for the engine. The default configuration settings of the engine are sufficient for most users. Properties are set by specifying their name and value in the configuration files. \=. Trace. the following line sets the property Trace. TIBCO BusinessWorks Process Design Guide .Role. or a colon (:).

on MS Windows machines. perform the following: 1.Args -p c:\\tibco\\properties. For example. Click the Start Testing Viewed Process button to start the test engine (see Process Instances During Testing on page 203 for more information about the process engine during testing).cfg The line above illustrates a properties file placed in the c:\tibco directory of a MS Windows machine.tra to inform TIBCO Designer of the location of the properties file you created in step #1. For example.Setting Custom Engine Properties for the Testing Environment 239 | 1. 6.cfg. 3.cfg If you always use the same properties file. Create a properties file containing the custom properties you wish to set in the process engine that runs in the testing environment. -p c:/tibco/properties. Notice the backslashes in the file path are escaped because backslash is a reserved character in properties files. you can alter the designer. 5. Edit the designer. enter the -p argument. On the Select Processes to Load dialog.tra. Add properties to your file. TIBCO BusinessWorks Process Design Guide . Create your properties file and place it in the desired location. 2.cfg file.tra file. followed by the location of your properties. In the Test Engine User Args field. Start TIBCO Designer and open the project you wish to test. click the Advanced button. To alter the designer. This file is located in the bin subdirectory of the TIBCO Designer installation directory.property. For example.User.testEngine. java. 2. Add the following line to designer. 4. create a file named properties. where <release_number> is the release number of the currently installed TIBCO Designer.tra file to point to a properties file.tra file to specify the location of your properties file. 3. this file is usually located at c:\tibco\designer\<release_number>\bin\designer.

See TIBCO Administrator User’s Guide for more information about creating and managing deployment configurations.xml file has a <properties> element that defines all of the properties you would like to have available in deployed process engine. TIBCO BusinessWorks Process Design Guide .xml where <release_number> is the release number of the currently installed TIBCO Designer. For example.240 | Appendix B Custom Engine Properties Setting Custom Engine Properties in Deployed Projects TIBCO Administrator is responsible for deploying process engines in a production environment.xml file: <property> <name>Trace All Roles</name> <option>Trace. TIBCO BusinessWorks provides a file for specifying any custom properties you wish to set in deployed engines.*</option> <default>false</default> <description>Controls tracing of all roles.</description> </property> Once the property is defined in the bwengine. The bwengine. you would add the following to the bwengine.Role. The bwengine. You can alter the value of any property on the Advanced tab of the deployment configuration and that value will be used in the deployed project.Role.xml file. on MS Windows machines. Each property is contained in a <property> element with the following structure: <property> <name>Name to display in TIBCO Administrator</name> <option>name of property</option> <default>default value</default> <description>short description of property</description> </property> For example. this file would by default be located in c:\tibco\bw\<release_number>\lib\com\tibco\deployment\bwengine. to include the Trace.* property in deployment configurations.xml file is located in the lib\com\tibco\deployment subdirectory of the TIBCO BusinessWorks installation directory.xml file. Be sure to re-save EAR files in TIBCO Designer and re-load them into any deployment configurations created in TIBCO Administrator after changing the bwengine. it is available in Enterprise Archive Files that are created by TIBCO Designer and will be displayed in the Advanced tab of the deployment configuration in TIBCO Administrator.

-1 indicates the duplicateKey values are deleted when the job completes. See Detecting Duplicate Process Instances on page 184 for more information about duplicate detection.enabled This property controls whether duplicate detection is performed.<processName> property to true. bw. See Detecting Duplicate Process Instances on page 184 for more information about duplicate detection.* property to true. When a property has a non-boolean value. You can enable memory saving mode for all process instances by setting the EnableMemorySavingMode.dupKey. Engine Properties This section describes properties that control the behavior of the process engine. TIBCO BusinessWorks Process Design Guide .engine. The default is 30 minutes. Most properties are boolean and can be set to a value of true or false to enable or disable them.dupKey. See Detecting Duplicate Process Instances on page 184 for more information about duplicate detection.<processName> Memory saving mode can reduce the memory used by actively running process instances as well as potentially improve the performance of checkpoints. false indicates duplicateKeys when specified are ignored. true (the default) indicates the process engine will check for identical duplicateKey values.dupKey.engine. 0 indicates to store duplicateKey values indefinately.timeout. By default. Any positive integer greater than 0 indicates the number of minutes to keep stored duplicateKeys. memory saving mode is disabled.minutes This property specifies how long (in minutes) to keep stored duplicateKeys. its syntax is explained in the property description.pollPeriod. bw. EnableMemorySavingMode. but you can enable garbage collection on specific process instances by setting the EnableMemorySavingMode. bw.minutes Specifies the number of minutes to wait before polling for expired duplicateKey values.Available Custom Engine Properties 241 | Available Custom Engine Properties The following sections describe the custom properties that you can set.engine.

the value of the property is false. Engine. The default value is sufficient for most situations. the restarted process instances continue to be processed and may eventually be lost depending upon the type of error at startup. and if the engine encounters errors during startup. Engine. Therefore. a unique constraint violation is thrown when using a database as the data manager for process engines. By default.StandAlone Under some situations. but when a process instance keeps the tread too long.ShutdownOnStartupError controls this behavior.StepCount This property controls the max number of execution steps (unless inside a transaction) for a job before an engine thread switch occurs. but if your process definitions contain a large number of activities and especially if they contain a large number of activities in iteration loops. TIBCO BusinessWorks Process Design Guide . this may cause less concurrency for executing process instances (and therefore inefficient use of CPU). The properties in this section should be set only on deployed engines. you may benefit from setting this property to a higher value.ShutdownOnStartupError By default. The custom engine property named Engine. checkpointed process instances are restarted when the engine restarts. TIBCO Hawk Properties TIBCO Administrator is the preferred monitoring and management tool for TIBCO BusinessWorks. it is difficult to determine the correct value for this property. However. These properties are not intended to be used with process engines started by TIBCO Designer for testing process definitions. Set this property to false if you encounter this situation. You can specify that the process engine should shutdown if any errors are encountered during startup so that checkpointed jobs are not lost in the event of an error. Frequent thread switching can cause engine performance degradation. See the description of the Checkpoint activity in TIBCO BusinessWorks Palette Reference for more information. Engine. process engines have a TIBCO Hawk microagent as well.242 | Appendix B Custom Engine Properties See Memory Usage of Process Variables on page 100 for more information. but setting it to true shuts the engine down if errors are encountered when the engine starts. The default value of this parameter is 20.

Hawk.Service Specifies the service parameter for the TIBCO Rendezvous transport of your TIBCO Hawk configuration. Disabled both TIBCO Hawk and Engine Command activity usage. Enables only Engine Command activity. See the TIBCO Rendezvous documentation for more information about the syntax of the daemon parameter of TIBCO Rendezvous transports. By default this is set to 7474. See the TIBCO Rendezvous documentation for more information about the syntax of the network parameter of TIBCO Rendezvous transports.Daemon Specifies the daemon parameter for the TIBCO Rendezvous transport of your TIBCO Hawk configuration. Hawk. on page 255 for more information about using TIBCO Hawk to monitor and manage TIBCO BusinessWorks. Also.Available Custom Engine Properties 243 | See Appendix C. TIBCO BusinessWorks Process Design Guide . TIBCO Hawk cannot be used when this value is used. local false Hawk.Enabled Controls whether or not TIBCO Hawk can be used to monitor and manage the process engine. Hawk. See the TIBCO Rendezvous documentation for more information about the syntax of the service parameter of TIBCO Rendezvous transports. allows the Engine Command activity to be used. By default this is set to tcp:host:7474. TIBCO Hawk MicroAgent Methods. The following table describes the valid values for this property: Value true Description Enables both TIBCO Hawk and Engine Command activity usage. By default this is set to "".Network Specifies the network parameter for the TIBCO Rendezvous transport of your TIBCO Hawk configuration.

<userRoleName>. Tracing is controlled either by roles. For roles.Term or Trace. Trace Properties Trace properties control which trace messages are sent and where they are sent to. Info.<systemRoleName>. or by process definitions. The instrumentation properties can be set at runtime by calling the TIBCO Hawk setInstrumentProperties method. Trace. Debug).Role. Messages can be sent to the log file. The property value specified in a call to setInsrumentProperties takes effect immediately. Warn. Specifying Location of Trace Messages The following properties control where trace messages are sent. The Write to Log activity allows you to specify a user-defined role for the message to write. Setting this property to false disables the actions.Role.Role. Setting the property Instrumentation.Term to control console output for all user-defined roles. to the console. The actions that can be enabled or disabled are: • • Collection of activity statistics for the GetActivity microagent method Calls to OnProcessActivity and OnProcessStatusChanged microagent methods Setting the engine property Instrumentation.<systemRoleName>. controls whether or not messages for the specified system role (Error.* to true enables those actions for all process definitions. Trace. Info. or published as TIBCO Rendezvous messages. you can configure system role tracing (Error.<userRoleName>. Warn.<processName> Some of the TIBCO Hawk instrumentation methods require runtime actions that impose performance and memory overhead.244 | Appendix B Custom Engine Properties Instrumentation. or Debug) are sent to the console. by activities. or you can configure tracing for user-defined roles.<processName> to true enables those actions for a specified process definition.Term Trace. These actions can be enabled or disabled on a per-process definition basis at any time by setting this property.Term TIBCO BusinessWorks Process Design Guide .Term controls whether or not messages for the specified user-defined role are sent to the console. use Trace.*.

Publish.Service Trace. log file name.Log or Trace.Log.Network Trace. the messages are sent on TIBCO BusinessWorks default transport.Role.Role. and then entries are then directed to the second log file until it reaches its maximum size.<systemRoleName>. • Trace. entries are then directed back to the first log file again.MaxSize TIBCO BusinessWorks Process Design Guide . Info. Specifying Rolling Log Files for UserRole You can specify that entries for the role named UserRole are sent to a set of rolling log files. You can specify a different transport for published trace messages with the following properties: • • • • Trace. the number of log files. and the maximum size of each log file. Warn. Warn.Subject Trace.*.UserRole.Log to control log output for all user-defined roles.Available Custom Engine Properties 245 | Trace.<systemRoleName>.Log controls whether or not messages for the specified user-defined role are sent to the log file. Trace.<systemRoleName>.<systemRoleName>. Trace.<userRoleName>. A number is appended to each new log file created up to the specified maximum number of log files.Daemon See the TIBCO Rendezvous documentation for the correct syntax for specifying transport parameters.Role. — Maximum size of a log file before entries are directed to the next log file in the sequence.Role.Publish. or Debug) are published as a TIBCO Rendezvous message.Role.<systemRoleName>.Log controls whether or not messages for the specified system role (Error. and so on.File — Filename for the log files.UserRole. By default.<systemRoleName>. The following engine properties allow you to configure rolling log files: • • Trace.Log. you specify the location of the log files. To accomplish this.Dir — Location for the set of rolling log files.Publish.Log.Role.<userRoleName>. Trace.UserRole.Publish controls whether or not messages for the specified system role (Error. Once the maximum number of log files is reached. use Trace.<systemRoleName>.Role.Publish.Publish Trace.<systemRoleName>.Log Trace.Role. Entries will be written to the first log file until it reaches its maximum size. Info. or Debug) are sent to the log file.

Specifying a wildcard for the process definition name indicates you would like to control trace messages for all activities with a given name.Role.<userRoleName> or Trace.Task.<processDefinition>. Warn.Log. Trace.Maximum — Maximum number of log files to create.Role. Specify Trace. Trace.JC.* Enables or disables the specified role.246 | Appendix B Custom Engine Properties • Trace. There are three types of advisory messages: Error. Warn. Tracing by Resource The following properties enable or disable tracing for activities and process starters.UserRole. Info. Trace. and Info.* to control trace messages for all process starters.* Controls whether or not trace messages for all activities are output. Trace. Trace. Error advisories are logged by default.* enables or disables the specified system role (Error.<processStarterName> Controls whether or not trace messages for a given process starter are output. Trace. or Debug).JC.Task. Specifying a wildcard for the activity name indicates you would like to control trace messages for all activities in the specified process definition.* to enable or disable all user-defined roles.<userRoleName> enables or disables the specified user-defined role. specify Trace. The following properties control whether TIBCO Rendezvous advisory messages are sent to the log file: TIBCO BusinessWorks Process Design Guide .<systemRoleName>.<systemRoleName>.<activityName> Controls whether or not trace messages for a given activity in a process definition are output. TIBCO Rendezvous Advisory Messages TIBCO Rendezvous advisory messages can be written to the TIBCO BusinessWorks log file. Tracing by Role The following properties enable or disable all tracing for user-defined and system roles. Entries are directed back to the first log file when the maximum number of log files have been created.Role.Role.

client.maxProcessors This property specifies the maximum number of threads available for incoming HTTP requests. The HTTP server creates the number of threads specified by this parameter when it starts up.server.Warn Trace.RV.Advisory. setting the properties to false disables the advisory messages.http. bw. If you set the value too high. This section lists the properties for configuring the HTTP server.RV. TIBCO BusinessWorks Process Design Guide . The thread pool is created when the engine starts. The default minimum number of threads is 10. The number of threads in the pool determines the maximum number of concurrent requests a request/response activity can execute. bw. The value of this property controls the size of the thread pool.server. therefore be careful to set the value of this property to a reasonable number for your system. HTTP Properties In some situations.plugin. it may result in extra resources allocated that are never used.ResponseThreadPool Each Request/Response activity that uses the HTTP protocol (for example.Error Trace. Each request is executed in a separate thread.http.Available Custom Engine Properties 247 | • • • Trace.Advisory.minProcessors This property specifies the minimum number of threads available for incoming HTTP requests. belonging to the thread pool associated with the activity. you may wish to alter the configuration of the HTTP server that receives incoming HTTP requests for TIBCO BusinessWorks. The HTTP server will not create more than the number of threads specified by this parameter.RV. bw.plugin.http. The default maximum number of threads is 75. Send HTTP Request or SOAP Request Reply) is associated with a unique thread pool.Advisory.Info Setting these properties to true enables the associated advisory messages. The default value of this property is 10.plugin.

http.client. See the description of the Send HTTP Request activity in TIBCO BusinessWorks Palette Reference for more information. bw. This property specifies the maximum number of persistent connections to create for all HTTP servers. The default value for this property is 20.client.client.http.client.client. TIBCO BusinessWorks Process Design Guide . The number of connections for each host is limited by the bw.plugin.client.usePersistentConnectionManager property is set to true.client.http.plugin. See the description of the Send HTTP Request activity in TIBCO BusinessWorks Palette Reference for more information.usePersistentConnectionManager property is set to true. The default value for this property is 200. When this property is set to true. bw.http.plugin.maxTotalConnections The value of this property is ignored unless the bw.maxConnectionsPerHost property.plugin. The total number of connections in the pool is limited by the bw. The default value of this property is false.plugin. This property specifies the maximum number of persistent connections to each remote HTTP server.248 | Appendix B Custom Engine Properties bw. See the description of the Send HTTP Request activity in TIBCO BusinessWorks Palette Reference for more information.usePersistentConnectionManager This property specifies that a pool of HTTP connections to each HTTP server should be created so that connections can be reused by Send HTTP Request activities.http.maxConnectionsPerHost The value of this property is ignored unless the bw.http. Refer to your HTTP server documentation for more information about support for persistent connections.maxTotalConnections property.http.plugin. Not all HTTP servers support persistent connections. a pool of connections is created for each HTTP server that Send HTTP Request activities connect to.plugin.

TIBCO BusinessWorks Process Design Guide . but you can set this property to the amount of time you would like to keep database connections open.plugin.server.checkForStaleConnections The value of this property is ignored unless the bw.http. The default value for this property is false.plugin.SetLoginTimeout Time (in seconds) to wait for a successful database connection. bw. This parameter specifies the time (in minutes) to allow database connections to remain idle before closing them. The value of this property overrides any value set for connection timeouts in the Configuration tab of the JDBC Connection resource. but it does improve reliability.server. the value of this field is ignored. bw.client.client.usePersistentConnectionManager property is set to true. JDBC Properties This section describes custom engine properties that can be set for resources in the JDBC palette.idleTimeout Normally.defaultHost Specifies the name of the default host to use when the machine has multiple domains or IP addresses.deferClientAuthentication Defers client authentication and outputs the client’s security context when the client connects to the server using HTTPS.http.Available Custom Engine Properties 249 | bw.plugin. Checking for stale connections adds significant processing overhead. a persistent connection is checked to determine if it is stale before it is used by a Send HTTP Request activity.https.JDBC. The value of this parameter can be either a host name or IP address.Connection. Config. When this property is set to true.plugin.http. Most JDBC drivers should support connection timeouts. The default timeout for database connections is 5 minutes. If the JDBC driver does not support connection timeouts.engine. a connection can become stale. Only JDBC drivers that support connection timeouts can use this property.dbConnection. See the description of the Send HTTP Request activity in TIBCO BusinessWorks Palette Reference for more information. bw. When using persistent connections. connections in the database connection pool close after a period of time when they are idle.

250 | Appendix B Custom Engine Properties JMS Properties This section describes custom engine properties that can be set for resources in the JMS palette. This typically occurs when sending large messages. For example. there will be only one retry. The number of retries within that three-minute limit depends upon the value of the polling interval. then the Receive Mail process starter will attempt to receive the message for two minutes. but indicate later that the message is unavailable.mail. the JMS process starters cannot connect to the JMS server. the mail server may expose the message to the Receive Mail process starter. the process starter will attempt to receive the message for three minutes. This property allows you to specify the number of times the Receive Mail process starter will attempt to receive the same message. if the polling interval is set to 30 seconds. Mail Properties This section describes custom engine properties that can be set for the resources in the Mail palette. For example.plugin. Setting this property to true allows the process engine to start and the JMS process starters will wait until the JMS sever is up before starting. TIBCO BusinessWorks Process Design Guide . and the retry count is set to 12.plugin. The amount of time allotted for retries will be the value of this property multiplied by the polling interval. there will be up to six retries. bw. The Receive Mail process starter attempts to receive the message during subsequent polls of the mail server. If the polling interval is set to 4 minutes. bw.receiverRetryCount When a mail sender is in the process of sending a message. if the polling interval is every 10 seconds.recoverOnStartupError When a process engine attempts to startup and the JMS server that JMS activities connect to is not up. By default.jms.

However.javaCode. the activity used URL encoding for the Query specified in the QueryString element. It is now the user's responsibility to properly URL-encode the query specified in the QueryString. TIBCO BusinessWorks Process Design Guide .0.0.stripLineFeedInPut Prior to release 5. the activity does attempt to encode the value supplied in this element. bw.ftp.2. you can set the bw. While properties in this section can be used to revert to behavior of previous releases. Therefore. These properties are not intended for long-term use. The FTP Put activity no longer strips the \n. and if you rely on this behavior in existing projects.ftp. relying on the behavior of previous releases is not recommended for new projects. the Java Code activity omits the value in its output. This section lists properties that are included for backwards compatibility with projects created in previous versions. Functionality changes are usually introduced to improve the product or to correct erroneous behavior. Other activities pass an explicit null for null references. bw.2.plugin. functional behavior of TIBCO BusinessWorks changes. there are properties that allow you to revert to the behavior of previous releases.stripLineFeedInPut to true to obtain the behavior of previous releases.Available Custom Engine Properties 251 | Properties for Backwards Compatibility From time to time.http. the QueryString input element of the Send HTTP Request activity is not automatically URL encoded. the FTP Put activity stripped the \n when \r\n was used for a new line in a file. This change may cause backward compatibility issues if you rely on the activity to perform the URL-encoding of the QueryString. bw. Therefore.urlEncodeQueryString As of release 5.2. The properties in this section are intended to allow backward compatibility of legacy projects until the project can be corrected to accommodate the new behavior.plugin. Prior to release 5. This property is set to false by default.plugin. This caused files to be unusable when a file was taken from a MS Windows machine and put onto a VMS machine.client. other activities did not behave in this way.plugin. This causes a String value used as a null place holder when another activity attempts to read the null in its input.explicitNull To indicate a null reference. If you rely on the behavior of previous releases. use of these properties is not recommended for most circumstances. but setting it to true reverts to the behavior of previous releases.

2. Setting this property to false (the default value) omits the time zone from the function output (the same behavior as 5.0. However. the function was changed to omit the time zone.no_xsi_type SOAP activities were enhanced in release 2.x). you can do so by setting this property to true.plugin. the JDBC Call Procedure activity created input elements that were optional for stored procedure parameters.5 to emit xsi:type attributes. com.tibco.JDBC.0. If you wish to migrate a project without fixing this problem. bw. In Release 5.plugin. Setting this property to true causes the time zone to be included in the function output (the same behavior as 2.CallProcedure. the XPath function create-dateTime() returned a value that included a time zone.1.has.1.useJavaMonth In previous releases.2.xml.soap. the Java Code activity still behaves the same.xpath.x.plugin.252 | Appendix B Custom Engine Properties To preserve backward compatibility. These migrated projects cannot be executed until the errors are resolved (by using the Mapper Check and Repair button on the Input tab).InputOptional In releases prior to 5.timer. you must set this property to true. however. the expected convention for month numbers is 1-12. com.2 and 5. When this property is set to true. there will be validation errors for any unspecified input elements for stored procedure parameters. TIBCO BusinessWorks Process Design Guide .tibco. you can set this property to true to maintain compatibility with previous releases. the Timer process starter used the Java convention (0-11) for month numbers in its output.create-dateTime.3.timezone In Release 2.1. If you rely on the behavior of previous releases. In release 5.0.javaCode. If you wish to maintain backward compatibility and not emit these attributes.explicitNull to true to cause the Java Code activity to behave in the same way as other activities. This property is set to false by default. an explicit null is set for a null reference. the month is returned as a number between 1 and 12. This property controls whether the time zone is included in the output of the create-dateTime() function. you can set the bw.x). When migrating a project from a previous release. Optional parameters have never been supported by this activity (see the Known Issues list under the JDBC Palette heading in TIBCO BusinessWorks Release Notes). maintaining the behavior of the previous releases. Config.

schema. this property controls whether elements that are nil are contained in the output. The element is now placed into the output schema and has "xsi:nil = true" to indicate the element is null.1. if you chose a comma as the delimiter. To disable this functionality.2.Available Custom Engine Properties 253 | Config. This BOM is not necessary for UTF-8. if the output element was optional. set the value of this property to true.4.OutputUseNil Prior to release 5.makeNillable Certain TIBCO ActiveEnterprise-based schema elements do not display as nillable in the Input mapping tab.delimiters. This can result in mappings (optional to optional) that do not copy the xsi:nil attributes at runtime to the output elements. The BOM is now stripped when it is encountered. ignore. when using the activities in the Parse palette. In most cases. CA".quotes Prior to Release 2. the File Reader activity’s output includes the BOM at the beginning of the data read from the file. You should surround elements that can be nil with an if statement to determine whether to output the element. If you wish to retain the functionality of previous releases. java. You may need to set this property to true if your process definition is expecting a file that contains the BOM. To maintain the behavior of previous releases. you will not need to set this property.6.ae. See the description of the Data Format shared configuration resource in TIBCO BusinessWorks Palette Reference for more information about the new semantics for parsing input text. and subsequently validation errors. java.DiscardUTF8BOM When a file is saved on a Windows platform using UTF-8 encoding.0. Also. TIBCO BusinessWorks Process Design Guide .tibco. you can set this property to false. Prior to release 2. For example. Now fields can be surrounded in double quotes. there was no way to have a field span multiple lines or include leading and trailing spaces. there was no way to have a field contain a comma as in "Fresno. delimiter-separated data was not treated in a standard way.under.0.CallProcedure.com. Windows adds a Byte Order Mark (BOM) to the beginning of the file.property.property. if a value returned from a database table was null.JDBC. There was no mechanism to escape the specified delimiter character. the output element corresponding to that table value was not placed into the output schema for a JDBC Call Procedure activity. Set the property to false to achieve the behavior of previous releases. but it is valid.

Selecting the input mapping with an error and clicking the Mapper Check and repair button will display yellow warnings: “The input and this element are both nillable.254 | Appendix B Custom Engine Properties Setting this property to true causes mappings that meet the criteria to show warnings. the Mapper Check and repair button can be used to update the mappings to copy xsi:nil attributes.2. set to copy-nil”. Clicking OK changes the mappings to add the copy-of for the nil attribute (“Optional and nillable to optional and nillable”). Any new mapping done by drag-and-drop with the property set to true will have the “Optional and nillable” style mapping. Typically.1 and subsequent releases. the default setting for this property is true. In Release 5. If it is preferable to have empty elements emitted in this case. it will be copied to the target element. then the property can be set to false. TIBCO BusinessWorks Process Design Guide . instead of the “optional to optional” style. This is generally a better way to map this structure and ensures if the element in the source data has the xsi:nil attribute. which may cause new warnings to appear in existing projects.

Topics • • Enabling TIBCO Hawk. However.| 255 Appendix C TIBCO Hawk MicroAgent Methods TIBCO Administrator is the preferred monitoring and management application for TIBCO BusinessWorks. This appendix describes the microagent methods available for the TIBCO BusinessWorks process engine. page 256 TIBCO BusinessWorks Process Design Guide . page 256 TIBCO Hawk Microagent Methods. the process engine is instrumented with a TIBCO Hawk microagent that can be used to perform most administrative functions.

set the Hawk. you must enable the TIBCO Hawk microagent in the process engine. use the Instrumentation. Some microagent methods require memory and processor overhead for gathering statistics or for getting information on the current state of the process.<processName> property.Network. and Hawk. To do this. None TIBCO BusinessWorks Process Design Guide .* property. Custom Engine Properties. Hawk. certain instrumentation is disabled by default. This can only be set for deployed process engines.Service. Enabling instrumentation can lead to significant performance degradation. You can enable instrumentation for a specific process definition with the Instrumentation. Process engines in the test environment are not normally monitored and administered. If you are using non-default transport parameters for TIBCO Hawk.256 | Appendix C TIBCO Hawk MicroAgent Methods Enabling TIBCO Hawk Before using the TIBCO Hawk with TIBCO BusinessWorks. therefore TIBCO Hawk is not recommended for use in the testing environment. Because of the performance implications. on page 237 for more information about setting properties for process engines. you must also set the Hawk. TIBCO Hawk Microagent Methods This section describes the TIBCO Hawk microagent methods for the TIBCO BusinessWorks process engine.Enabled property to true. See Appendix B. To enable instrumentation for all processes. GetExecInfo Description: Method Arguments: Retrieves the process engine execution information.Daemon properties to the values for the transport you are using. You should only enable instrumentation for brief periods while testing performance.

Number of times process instances have been swapped to disk. Can be one of the following: • • • • Uptime Threads Version ACTIVE SUSPENDED STANDBY STOPPING Elapsed time (in milliseconds) since the process engine was started. TIBCO BusinessWorks Process Design Guide . Number of process instances created for this process definition. Name of the process starter for the process. Number of times process instances have been suspended. Version of the process engine. None The following table describes the output of this microagent method: Column Name Name Starter Created Suspended Swapped Description Name of the process definition. Number of worker threads used by the process engine.TIBCO Hawk Microagent Methods 257 | Output: The following table describes the output of this microagent method: Column Name Staus Description Engine status. GetProcessDefinitions Description: Method Arguments: Output: Retrieves information about executing process definitions.

MaxElapsed MinExecution MaxExecution MostRecentExecutionTime MostRecentElapsedTime TIBCO BusinessWorks Process Design Guide . Execution time (in milliseconds) of the process instance that has completed in the longest amount of execution time.258 | Appendix C TIBCO Hawk MicroAgent Methods Column Name Queued Aborted Completed Checkpointed TotalExecution AverageExecution TotalElapsed AverageElapsed MinElapsed Description Number of times process instances have been queued for execution. Total execution time (in milliseconds) for all successfully completed process instances. Elapsed clock time (in milliseconds) of the process instance that has completed in the longest amount of elapsed time. Number of times process instances have been aborted. Elapsed clock time (in milliseconds) of the process instance that has completed in the shortest amount of elapsed time. Execution time (in milliseconds) of the process instance that has completed in the shortest amount of execution time. Execution time (in milliseconds) of the most recently completed process instance. Number of times process instances have executed a checkpoint. Total elapsed time (in milliseconds) for all successfully completed process instances. Number of process instances that have been successfully completed. Average elapsed clock time (in milliseconds) for all successfully completed process instances. Average execution time (in milliseconds) for all successfully completed process instances. Elapsed clock time (in milliseconds) of the most recently completed process instance.

The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Description Name of the process definition. For example.pe. Name of the process definition used by the process instance.TIBCO Hawk Microagent Methods 259 | Column Name TimeSinceLastUpdate CountSinceReset Description Time (in milliseconds) since the statistics have been updated. Method Arguments: Output: The following table describes the output of this microagent method: Column Name Name Type Description Name of the activity as specified in TIBCO Designer. com.CallProcessActivity. A Java class name. for the type of the activity.tibco. If arguments are specified. Number of process instances that have completed since the last reset of the statistics. Method Arguments: TIBCO BusinessWorks Process Design Guide . The following table describes the arguments of this microagent method: Argument Name Id Name Description ID for the process instance. GetProcesses Description: Retrieves information about active process instances. GetStaticActivityInfo Description: Retrieves design time activity information for all activities in a given process definition. information for process instances that match the specified arguments is returned.core.

Elapsed clock time (in milliseconds) since the process instance started. MinimumDuration MainProcessName Output: The following table describes the output of this microagent method: Column Name Id Name TrackingId CustomId Status StartTime Duration MainProcessName CurrentActivityName StarterName SubProcessName Description ID for the process instance. Status of the process. Time when the process instance started.260 | Appendix C TIBCO Hawk MicroAgent Methods Argument Name EarliestStartTime Description Earliest time (in milliseconds) at which the process instance started. Name of the process definition used by the process instance. Custom ID for the process instance. All process instances started after the specified time will be retrieved. Name of the currently executing activity in the process instance. Tracking ID for the process instance. Name of the process starter that started this process instance. Name of the main process definition. Name of the process definition for the sub-process. All process instances that have elapsed times greater than the specified minimum duration will be retrieved. Name of the main process definition. TIBCO BusinessWorks Process Design Guide . Minimum time (in milliseconds) in elapsed clock time since the process instance started.

and Wait For..TIBCO Hawk Microagent Methods 261 | GetActivities Description: Retrieves information about the activities that have been executed for a given process definition since the engine was started. DEAD. activities. The min/max fields can be reset with the ResetActivityStats method.. Total clock time (in milliseconds) used by all executions of this activity. ExecutionTime ErrorCount LastReturnCode TIBCO BusinessWorks Process Design Guide . Call Process. This does not include waiting time for Sleep. This can be either OK. Total number of executions of the activity that have returned an error. not just the execution time for the call process activity itself. Status code returned by most recent execution of this activity. Number of times the activity has been executed. activities. Output: The following table describes the output of this microagent method: Column Name ProcessDefName Name ActivityClass ExecutionCount ElapsedTime Description Name of the process definition. Call Process. Method Arguments: The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Description Name of the process definition. This includes waiting time for Sleep. A single activity name represents all executions of that activity.. Total clock time (in milliseconds) used by all executions of this activity. Name of the class that implements the activity.. The ExecutionTime computation for the Call Process Activity includes the sum of the execution times for all activities in the called process. and Wait For. Name of the activity. or ERROR. The activity information is cumulative.

Time (in milliseconds) since the statistics have been updated.262 | Appendix C TIBCO Hawk MicroAgent Methods Column Name Tracing MinElapsedTime Description True if tracing is enabled for this activity. false if tracing is disabled. TIBCO BusinessWorks Process Design Guide . Elapsed clock time (in milliseconds) of the activity execution that has completed in the shortest amount of elapsed time. Execution time (in milliseconds) of the activity execution that has completed in the shortest amount of execution time. MaxElapsedTime MinExecutionTime MaxExecutionTime MostRecentElapsedTime MostRecentExecutionTime TimeSinceLastUpdate CalledProcessDefs ExecutionCountSinceReset GetProcessStarters Description: Retrieves information about either active or inactive process starters. A comma-separated list of names of process definitions called by this activity. Execution time (in milliseconds) of the most recently completed activity execution. Execution time (in milliseconds) of the activity execution that has completed in the longest amount of execution time. Number of activity executions that have completed since the last reset of the statistics. The information is cumulative. A single process starter name represents all executions of that process starter. Elapsed clock time (in milliseconds) of the activity execution that has completed in the longest amount of elapsed time. Elapsed clock time (in milliseconds) of the most recently completed activity execution.

false if tracing is disabled. Number of process instances that have completed. The status can be INACTIVE. Elapsed clock time since the process starter was started.TIBCO Hawk Microagent Methods 263 | Method Arguments: The following table describes the arguments of this microagent method: Argument Name ActiveOrInactive Description Specify Active to retrieve information about process starters with the ACTIVE or READY status. Status of the process starter. Time (in milliseconds) at which the process starter was started. or READY. Number of process instances currently executing. Number of process instances per hour created by this process starter. True if the process was restarted from a checkpoint. ACTIVE. Name of the process starter. Output: The following table describes the output of this microagent method: Column Name ProcessDef Name Status Created CreationRate Running Completed StartTime Duration CheckpointedStart Tracing Description Name of the process definition. TIBCO BusinessWorks Process Design Guide . Specify Inactive to retrieve information about process starters with the INACTIVE status. True if tracing is enabled for this process starter. Number of process instances created by this process starter.

Exception message. This displays the [ProcessName/GroupName/ActivityName] of the activity issuing the exception. Name of the process definition. then the calling activity’s process stack plus a '>' separator character will be pre-pended to the normal information to produce the process stack of the activity issuing the exception. The following table describes the arguments of this microagent method: Argument Name Id Description ID for the process instance. Exception class name. If not specified.264 | Appendix C TIBCO Hawk MicroAgent Methods GetProcessesExceptions Description: Method Arguments: Retrieves error information reported by the specified process. TrackingId ProcessDef State SuspendAll Description: Suspends all process starters and/or processes. with the most recent exception first. Output: The following table describes the output of this microagent method: Column Name Seq Id Message StackTrace ExceptionClass ProcessStack Description Sequence number of the exception. Process stack at exception. TIBCO BusinessWorks Process Design Guide . If the activity is in a called sub-process. Exception stack trace. Tracking ID for the process instance. State of the process. ID for the process instance. or if 0 is specified. exceptions for all process instances are returned.

— resumes AllProcessStartersAndProcesses all processes and process starters.TIBCO Hawk Microagent Methods 265 | Method Arguments: The following table describes the arguments of this microagent method: Argument Name Action Description Specifies what to suspend. Can be one of the following: • • • ProcessDefinition AllProcessStarters — suspends all process starters. The following table describes the arguments of this microagent method: Argument Name Action Description Specifies what to resume. AllProcesses — suspends all processes. Output: None ResumeAll Description: Method Arguments: Resumes all process starters and/or processes. AllProcesses — resumes all processes. The name of the process definition. TIBCO BusinessWorks Process Design Guide . The name of the process definition. Can be one of the following: • • • ProcessDefinition AllProcessStarters — resumes all process starters. AllProcessStartersAndProcesses — suspends all processes and process starters. All process instances are stopped immediately and are permanently removed from the engine. Output: None KillAllProcesses Description: Kills all process instances.

The following table describes the arguments of this microagent method: Argument Name ProcessNameOrId Description The name or process ID of the process instance you wish to resume. ResumeProcess Description: Method Arguments: Resumes the specified process instance. You can retrieve the process ID for a process instance by using the GetProcesses method. Output: The following table describes the output of this microagent method: Column Name Status Description Status of the process instance after executing this operation.266 | Appendix C TIBCO Hawk MicroAgent Methods Method Arguments: The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Description The name of the process definition. The following table describes the arguments of this microagent method: Argument Name ProcessNameOrId Description The name or process ID of the process instance you wish to suspend. You can retrieve the process ID for a process instance by using the GetProcesses method. If unspecified. TIBCO BusinessWorks Process Design Guide . Output: None SuspendProcess Description: Method Arguments: Suspends the specified process instance. Only process instances for the specified process definition are killed. this action applies to all process definition.

You can retrieve the process ID for a process instance by using the GetProcesses method.TIBCO Hawk Microagent Methods 267 | Output: The following table describes the output of this microagent method: Column Name Status Description Status of the process instance after executing this operation. Output: The following table describes the output of this microagent method: Column Name Status Description Status of the process starter after executing this operation. The following table describes the arguments of this microagent method: Argument Name ProcessNameOrId Description The name or process ID of the process instance you wish to kill. Method Arguments: Output: None SuspendProcessStarter Description: Method Arguments: Suspends the specified process starter. The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Description Name of the process definition whose process starter you wish to suspend. TIBCO BusinessWorks Process Design Guide . The process instance is stopped immediately and permanently removed from the engine. KillProcess Description: Kills the specified process instance.

268

| Appendix C

TIBCO Hawk MicroAgent Methods

ResumeProcessStarter
Description: Method Arguments:

Resumes the specified process starter. The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Description Name of the process definition whose process starter you wish to resume.

Output:

The following table describes the output of this microagent method: Column Name Status Description Status of the process starter after executing this operation.

ListTraceProperties
Description: Method Arguments: Output:

Returns the names and current values for all engine trace properties. None The following table describes the output of this microagent method: Column Name Property Description Lists the tracing properties and their values in the form:
<TracingPropertyName>=<CurrentValue>

SetTraceProperty
Description:

Sets the specified engine tracing property to the specified value. While you can set properties with this method, ConfigureActivityTracing, ConfigureProcessStarterTracing, and ConfigureUserDefinedTracing are simpler to use for setting trace properties. See Trace Properties on page 244 for more information about tracing properties.

TIBCO BusinessWorks Process Design Guide

TIBCO Hawk Microagent Methods 269

|

Method Arguments:

The following table describes the arguments of this microagent method: Argument Name Name Value Description Name of the tracing property you wish to set.
true

if you wish to enable the property. false if you wish to disable the property.

Output:

None

ListInstrumentProperties
Description: Method Arguments: Output:

Retrieves the current settings for all Instrumentation properties. None

The following table describes the output of this microagent method: Column Name Property Description Lists the Instrumentation properties that are currently set in the form:
<ProcessDefinitionName>=<CurrentValue>

SetInstrumentProperty
Description:

Sets the Instrumentation property for the specified process definition to a given value. The OnProcessActivity and OnProcessStateChanged methods will be called for the specified processes definition names. For example, use property name "*" and value "true" to enable those asynchronous methods for all process definitions. The property name does not need to begin with "Instrumentation.", but if it does, the leading "Instrumentation." will be ignored. See Enabling TIBCO Hawk on page 256 for more information about the Instrumentation property.

TIBCO BusinessWorks Process Design Guide

270

| Appendix C

TIBCO Hawk MicroAgent Methods

Method Arguments:

The following table describes the arguments of this microagent method: Argument Name Name Description Name of the process definition for which you wish to alter the Instrumentation property. Specify * for this argument if you wish to enable or disable instrumentation for all process definitions.
true

Value

if you wish to enable instrumentation for the given process definition. false if you wish to disable instrumentation for the given process definition.

Output:

None

ListAllRoles
Description:

Returns a list of all roles, along with the current state (enabled or disabled) of each role. None

Method Arguments: Output:

The following table describes the output of this microagent method: Column Name Role Enabled Description Name of the role. True if the role is enabled, false if the role is disabled.

ListUserDefinedRoles
Description:

Returns a list of user-defined roles, along with the current state (enabled or disabled) of each role. None

Method Arguments:

TIBCO BusinessWorks Process Design Guide

TIBCO Hawk Microagent Methods 271

|

Output:

The following table describes the output of this microagent method: Column Name Role Enabled Description Name of the role. True if the role is enabled, false if the role is disabled.

GetProcessCount
Description: Method Arguments: Output:

Returns the total number of running process instances. None

The following table describes the output of this microagent method: Column Name TotalRunningProcesses Description Total number of currently executing process instances.

GetMemoryUsage
Description: Method Arguments: Output:

Retrieves information about the process engine’s memory usage. None

The following table describes the output of this microagent method: Column Name TotalBytes FreeBytes UsedBytes PercentUsed Description Total number of bytes allocated to the process engine. Total number of bytes that are not currently in use. Total number of bytes that are currently in use. Percentage of total bytes that are in use.

TIBCO BusinessWorks Process Design Guide

272

| Appendix C

TIBCO Hawk MicroAgent Methods

stopApplicationInstance
Description:

Shuts down the process engine immediately. All checkpoint files are preserved and the engine's operating system process exits. None None

Method Arguments: Output:

DelayedStopApplicationInstance
Description:

Instructs all process starters to stop further job creation but stay active. The engine shuts down after all process instances have completed or the specified maximum delay has been reached. After shutdown, any remaining checkpoint files are preserved and the engine's operating system process exits. The following table describes the arguments of this microagent method: Argument Name MaxDelay WaitForCheckpoints Description Specifies the amount of time (in seconds) to wait before shutting down the process engine. When true is specified, the engine waits for any checkpointed process instances to complete before shutting down.

Method Arguments:

Output:

None

GetStatus
Description: Method Arguments: Output:

Retrieves basic status information about the engine. None The following table describes the output of this microagent method: Column Name InstanceID Description Name of this instance of the process engine.

TIBCO BusinessWorks Process Design Guide

TIBCO Hawk Microagent Methods 273

|

Column Name AdapterName Uptime NewErrors TotalErrors ProcessID Host

Description Name of the application. Number of seconds since this process engine was started. Total number of errors encountered since the last time this method was called. Total number of errors encountered since the process engine was started. Operating system process ID of the process engine. Name of the host machine on which the process engine is running.

OnProcessStatusChanged
Description:

This method is called when a process is suspended or resumed, and it is only called when instrumentation on. None

Method Arguments: Output:

The following table describes the output of this microagent method: Column Name ProcessId When Active TrackingID ProcessDef Description ID of the process instance. Date and time when the status of the process instance changed. Status of the process instance. True when the process instance is active, false when it is inactive. Tracking ID for the process instance. Process definition name.

TIBCO BusinessWorks Process Design Guide

Process definition name. Method Arguments: Output: getHostInformation Description: Returns the value of the specified property on the host machine on which the process engine is running. Application State — state of the process engine. INITIALIZING. None The following table describes the output of this microagent method: Column Name ProcessId ProcessDef ActivityName TrackID Description ID of the process instance.AMI. ID of the execution track in which the activity was executed.274 | Appendix C TIBCO Hawk MicroAgent Methods OnProcessActivity Description: This method is called when a process executes an activity. Application Name — TIBCO Hawk display name of the process engine. or STOPPED Method Arguments: • TIBCO BusinessWorks Process Design Guide . Leave this argument blank to return all properties. RUNNING.DisplayName. and it is only called when instrumentation is on. STOPPING. The following are the properties that can be returned: • • Application Instance — is the name of the project that is running in the process engine. Can be UNINITIALIZED. he following table describes the arguments of this microagent method: Argument Name Name Description Name of the property to return. Name of the activity. This is set by the engine property Hawk.

If ActivityClass is specified. Specifying * signifies all process definitions. The class name is the Java implementation class' name. tracing will be disabled for all activities. ConfigureAllTracing Description: Method Arguments: Controls tracing for all activities and process starters. Value of the property. If true. this argument is optional. Method Arguments: TIBCO BusinessWorks Process Design Guide . If false. The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Description Name of the process definition for which you wish to configure tracing. If true.TIBCO Hawk Microagent Methods 275 | Output: The following table describes the output of this microagent method: Column Name Name Value Description Name of the property returned. Activities can be specified by process definition and activity name or by class name. If false. tracing will be disabled for all user-defined roles. EnableAllUserRoles Output: None ConfigureActivityTracing Description: Enables or disables tracing for specified activity. tracing is enabled for all activities. tracing is enabled for all user-defined roles. If false. The following table describes the arguments of this microagent method: Argument Name EnableAllActivities EnableAllStarters Description If true. tracing is enabled for all process starters. tracing will be disabled for all process starters.

Java implementation class name of the activity for which you wish to configure tracing. this argument is optional. this argument is optional. Specifying * signifies all process starters. Method Arguments: StarterClass Enable Output: None TIBCO BusinessWorks Process Design Guide . Specifying * signifies all activities. The class name is the Java implementation class' name. Process starters can be specified by name or class name. If ActivityClass is specified.276 | Appendix C TIBCO Hawk MicroAgent Methods Argument Name Activity Description Name of the activity for which you wish to configure tracing. Specify true if you wish to enable tracing. false if you wish to disable tracing. ActivityClass Enable Output: None ConfigureProcessStarterTracing Description: Enables or disables tracing for specified process starter. Specify true if you wish to enable tracing. false if you wish to disable tracing. The following table describes the arguments of this microagent method: Argument Name ProcessStarter Description Name of the process starter for which you wish to configure tracing. This argument is optional if you specify the ProcessStarter argument. If StarterClass is specified. This argument is optional if you specify the ProcessDefinition and Activity arguments. Java implementation class name of the process starter for which you wish to configure tracing.

If tracing is enabled for all activities and/or process starters by specifying a tracing parameter individually for each one. Enable Output: None ConfigureRole Description: Method Arguments: Enables or disables tracing for the specified role. false if you wish to disable tracing. Specifying * signifies all roles. this method will return false. Output: None IsAllTracingEnabled Description: Reports whether tracing is enabled or disabled for all activities and process starters. The following table describes the arguments of this microagent method: Argument Name Role Enable Description Name of the role for which you wish to configure tracing.TIBCO Hawk Microagent Methods 277 | ConfigureUserDefinedTracing Description: Method Arguments: Enables or disables tracing for the specified user-defined role. The following table describes the arguments of this microagent method: Argument Name Role Description Name of the user-defined role for which you wish to configure tracing. Specify true if you wish to enable tracing. None Method Arguments: TIBCO BusinessWorks Process Design Guide . Specifying * signifies all user-defined roles. false if you wish to disable tracing. True is returned when tracing is enabled using a wildcard (*). Specify true if you wish to enable tracing.

The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Activity Description Name of the process definition for which you wish to determine tracing status. Method Arguments: Output: The following table describes the arguments of this microagent method: Column Name Enabled Description true false if tracing is enabled for the specified activity. this method returns false because tracing is not enabled for the process starter specifically. IsProcessStarterTracingEnabled Description: Reports whether tracing is enabled or disabled for the specified process starter. this method returns false because tracing is not enabled for the activity specifically. false when tracing is disabled for all process starters. if tracing is disabled. false when tracing is disabled for all activities. If tracing is enabled for all process starters by way of a wildcard (*). Name of the activity for which you wish to determine tracing status. If tracing is enabled for all activities by way of a wildcard (*). IsActivityTracingEnabled Description: Reports whether tracing is enabled or disabled for the specified activity.278 | Appendix C TIBCO Hawk MicroAgent Methods Output: The following table describes the output of this microagent method: Column Name ActivityTracingEnabled Description true when tracing is enabled for all activities. TIBCO BusinessWorks Process Design Guide . ProcessStarterTracingEnabled true when tracing is enabled for all process starters.

TIBCO Hawk Microagent Methods 279 | Method Arguments: The following table describes the arguments of this microagent method: Argument Name ProcessStarter Description Name of the process starter for which you wish to determine tracing status. TIBCO BusinessWorks Process Design Guide . The following table describes the arguments of this microagent method: Argument Name Role Description Name of the role for which you wish to determine tracing status. Output: The following table describes the arguments of this microagent method: Column Name Enabled Description true if tracing is enabled for the specified process starter. ResetActivityStats Description: Resets the min and max time calculations for each activity in the specified process definition. this method returns false because tracing is not enabled for the role specifically. IsRoleEnabled Description: Reports whether tracing is enabled or disabled for the specified role. if tracing is disabled. false if tracing is disabled. Method Arguments: Output: The following table describes the arguments of this microagent method: Column Name Enabled Description true false if tracing is enabled for the specified role. This method is for internal use only and should not be invoked. If tracing is enabled for all roles by way of a wildcard (*).

and average time statistics gathered for process instances. The following table describes the argument of this microagent method: Argument Name ProcessDefinition Description Name of the process definition whose statistics you wish to reset. See GetProcessDefinitions on page 257 for more information about process instance statistics. Output: None ResetProcessDefinitionStats Description: Resets the minimum. and it is only called if instrumentation is on. None Method Arguments: Output: The following table describes the arguments of this microagent method: Column Name ProcessId Description Process ID of the process instance that was added. OnProcessRemoved Description: This method is called whenever a process instance is removed.280 | Appendix C TIBCO Hawk MicroAgent Methods Method Arguments: The following table describes the arguments of this microagent method: Argument Name ProcessDefinition Description Name of the process definition. OnProcessAdded Description: This method is called whenever a process instance is added. and it is only called if instrumentation is on. TIBCO BusinessWorks Process Design Guide . maximum. Method Arguments: Output: None.

_onUnsolicitedMsg Description: Subscribing to this method returns any unsolicited notifications that are sent from the managed application corresponding to this microagent. None Method Arguments: TIBCO BusinessWorks Process Design Guide . Invoking this method returns the last such message that was received (if any).TIBCO Hawk Microagent Methods 281 | Method Arguments: Output: None The following table describes the arguments of this microagent method: Column Name ProcessId Description Process ID of the process instance that was added.

282 | Appendix C TIBCO Hawk MicroAgent Methods TIBCO BusinessWorks Process Design Guide .

200 breakpoints 201 icons 207 B breakpoints 201 icon when set 202 business processes 32 E edit custom palette 17 End activity 62 process error schemas 164 enforcing order of execution 196 enterprise computing 32 error handling 159 error propagation 162 no-action groups 79 overview 160 process error schemas 164 repeat on error until true group 86 errors 108 errors in mappings 108 evaluation context 149 TIBCO BusinessWorks Process Design Guide C Call Process activity 39 category mode 15 changing current selection 11 clearing breakpoints 201 colors used when testing process definitions 206 conditions 68 constants in XPath 114 creating . adapter resources adding 26 addressing schema elements 148 groups 72 process definitions 40 transitions 67 creating custom palettes 17 creating projects 21 current selection 11 custom palettes 17 customer support xix D data sent across process instances 192.| 283 Index Symbols $_error process variable 160 A activities 36. 44 creating groups 72 End 62 Input tab icons 108 Start 60 stepping through when testing 205 ungrouping 73 adding adapter resources. 193 database storage inter-process communication 195 debugging 199.

194 G Generate Error activity error propagation 162 process error schemas 164 groups 38.284 | Index examples inter-process communication 195 K key incoming event 49 used for inter-process communication 192. 72 creating 72 error propagation 163 loops 80 accumulate output 81 index variable 81 no action 79 ungroupping 73 L loops 80 accumulate output 81 index variable 81 iterate 82 repeat on error until true 86 repeat until true 84 M H handling errors 159 hints 108 main window 8 mapping addressing schema elements 148 Input tab icons 108 XPath operators and functions 153 mappings 108 multiple events resuming a running process instance 196 I icons test mode 207 incoming events key 49 scalability 197 timeout 49 index variable 81 Input tab icons 108 inter-process communication 191 database storage 195 examples 195 overview 192 timeout 194 iterate loop 82 TIBCO BusinessWorks Process Design Guide N no action groups 79 Notify activity 192 Notify Configuration shared configuration 193 O opening projects 25 .

Index 285 | P palette mode 15 palettes 11 closing 17 custom 17 preferences 15 process definitions 35 breakpoints 201 breakpoints for testing 201 conditions 68 creating 40 creating transitions 67 debugging 199. contacting xix T technical support xix templates TIBCO BusinessWorks Process Design Guide . 200 grouping activities 72 handling errors 159 index variable in loops 81 new 36 process error schemas 164 process starters 58 propagating errors 162 scalability and incoming events 197 stepping through to test 205 subprocesses 39 test window 202 testing 200 ungroupping activities 73 process engines in operation 35 process instances communicating 192 enforcing order of execution 196 multiple events resumnig 196 when testing 203 process modeling 32 process starters 58 process variables $_error 160 processes 34 project templates 21 projects 9 adding adapter resources 26 opening 25 saving 23 propagation of errors 162 R Receive Notification activity 192 repeat on error until true loop 86 repeat until true loop 84 resources 10 unknown 11 S saving project as template 24 saving projects 23 scalability incoming events 197 schema elements 106 addressing 148 schemas process error schemas 164 search predicates in XPath expressions 150 semaphores 192 setting a breakpoint 202 setting breakpoints 201 setting which palettes display 17 shared configuration 38 specifying constants in XPath expressions 114 Start activity 60 subprocesses 39 starting process instances 58 starting TIBCO Designer 3 startup options 3 subprocesses 39 Call Process activity 39 error propagation 164 illustrated 40 support.

66 conditions 68 creating 67 specifying constants 114 XSLT statements 108 U ungrouping 73 unknown resource 11 W Wait activity 192 waiting for incoming events 49 X XPath 147 basics 148 conditions 68 editor 151 evaluation context 149 example 153 operators and functions 153 search predicates 150 TIBCO BusinessWorks Process Design Guide .286 | Index project 21 project templates 24 test mode 199 testing process definitions 199. 200 breakpoint locations 201 colors in test mode 206 menus and toolbar icons 207 overview 200 process instances 203 stepping through activities 205 test window 202 TIBCO Designer roadmap 7 timeout incoming events 49 inter-process communication 194 transitions 37.

You're Reading a Free Preview

Download
scribd
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->