Redwood Documentation

Product Documentation

 

›Chain Definitions

RunMyJobsProcess and Chain Definitions

Process Definitions

  • Creating Process Definitions
  • Setting Chain Definition and Chain Definition Properties
  • Integrating Redwood Server with Web Services
  • Redwood Definition Types
  • Maintenance Process Definitions
  • Template Process Definitions
  • Top Level Process Definition
  • Submit Form Editor
  • Default System Process Definitions

Processes and Chains

  • Advanced Chain Diagram Quick Reference
  • Chain Diagram Quick Reference
  • Chain Runtime Viewer Quick Reference
  • Advanced Chain Definition Editor Quick Reference
  • Advanced Chain Runtime Viewer Quick Reference
  • Advanced Diagram Quick Reference
  • Parameter Validation using Constraints
  • Processes Waiting on Events
  • Setting the Scheduling Behavior on the Control Tab
  • Setting the Retention Period for Processes
  • Runtime Limits
  • Setting Process Definition Options
  • Defining Parameters
  • Constraint Definitions
  • Constraint Class
  • Raising Events
  • Processes with Locks
  • Reaction Processes
  • Restart Behavior on the Process Status Tab
  • Searching Files
  • Setting the Name and Editing the Process Definition Source
  • Customizing Processes with Specific Actions
  • Using Table Parameters
  • Automatically Deleting Old Processes and Chains
  • Editing Process Definitions Safely
  • Parameter Formats

Chain Definitions

  • Using Chain Definitions
  • Creating Chain Definitions
  • Steps
  • Chain Processes
  • Creating Chain Definitions with Sequential Processes
  • Creating Chain Definitions with Parameter Handling
  • Creating Chain Definitions with Parallel Chain Processes
  • Creating Chain Definitions with Chain Processes Dependencies
  • Creating Chain Definitions for Multiple SAP Systems
  • Precondition Functions

Restart Behavior

  • Controlling Global and Partition Restart Behavior
← Creating Chain Definitions with Parallel Chain ProcessesCreating Chain Definitions for Multiple SAP Systems →

Creating Chain Definitions with Chain Processes Dependencies

Complex dependencies can be implemented with chain definitions in combination with other repository objects in an intuitive way.

The following different repository objects can be used to create dependencies:

  • Locks - Prevent specific processes from running simultaneously.
  • Events - process and chains can raise and clear events as well as get submitted by events.

The following chain definition properties allow you to create dependencies:

  • Status Handlers - Chain execution can be adapted at runtime by the use of status handlers.
  • Precondition function - Allow or disallow chain processes or steps execution based on the output of a function.

Procedure

  1. Choose "Definitions > Chains" in the Navigation bar.
  2. Choose New Chain Definition from the context-menu.
  3. Choose the $fcaJobChainDef; tab and fill in a name for the chain definition, choose Save.
  4. On the Chain Definition tab, choose the name of the chain definition.
  5. Choose Add Step from the context-menu, notice that a new step with the caption Step 1 has been added.
  6. Select Step 1.
  7. Specify a precondition expression in the Precondition field, an empty Precondition field is evaluated as true.
  8. Expand Status Handlers and specify an action to be performed for each desired status.
  9. Choose Add chain process from the context-menu of Step 1.
  10. Choose chain process 1 and enter the part of the process definition name into the Process Definition field.
  11. Choose the desired process definition out of the list of available process definitions.
  12. Under Scheduling, enter a parameter for Queue.
  13. Specify a precondition expression in the Precondition.
  14. Perform actions 6 to 9 of this procedure for each required process.
  15. Set dependencies:
  16. On the Locks tab, fill in a name of a desired lock that the chain should hold; specify a count is required.
  17. On the Wait Events tab, choose Add and fill the name of an event. Select a value for Auto submit.
  18. On the Raise Events tab, choose Add and fill the name of an event, specify a Raiser Comment and select a Status To Raise On.
  19. Choose Save to save the chain definition.

Examples

Using Locks

Two independent chain definitions are not to run simultaneously. Here the default count ( 1 ) is used.

  1. Creating a lock.

  2. Choose "Definitions > Locks" in the Navigation bar.

  3. Choose New Lock and fill in a name.

  4. Choose Save and Close.

  5. Attaching the lock to the chain definitions

  6. Choose "Definitions > Chains".

  7. From the context-menu, choose Edit.

  8. Choose the chain definition.

  9. Choose the Locks tab, fill in the name of a previously created lock.

  10. Choose Save and Close.

Using Events

  1. Create an event definition.

  2. Choose "Definitions > Event Definitions" in the Navigation bar.

  3. Choose New Event Definition and fill in a name.

  4. Choose Save and Close.

  5. Attach an event to be raised by the chain definition.

  6. Choose "Definitions > Chains".

  7. From the context-menu, choose Edit.

  8. Choose the chain definition.

  9. Choose the Raise Events tab and choose Add, choose the previously created event.

  10. Choose Save to save the chain definition.

  11. Attach an event to be raised on Wednesdays by process 1 of the first step for status Completed.

  12. Choose "Definitions > Chains".

  13. Choose process 1 of the first step.

  14. Choose Raise Events, choose.

  15. Select an event definition, fill Wednes in the Time Window field.

  16. Choose Save to save the chain definition.

  17. Attach an event to be raised by process 1 of the first step for status Error only if another event is raised.

  18. Choose "Definitions > Chains".

  19. Choose process 1 of the first step.

  20. Choose Raise Events, choose.

  21. Select an event definition, fill =Event.isEventRaised('Mypartition.MyEvent') in the When expression field.

  22. Choose Save to save the chain definition.

  1. Attach an event to submit the chain definition.
  2. Choose "Definitions > Chains".
  3. Choose the chain definition.
  4. Choose the Wait Events tab and choose Add, choose the previously created event definition.
  5. Choose Save to save the chain definition.

Using Status Handlers

A chain definition with four steps should run step 4 only when one of the three previous steps failed and upon successful completion restart the chain.

When step 4 fails an operator should be informed of the problem.

  1. Choose "Definitions > Chains".
  2. From the context-menu, choose Edit.
  3. Under Error, choose GotoStep and step 4.
  4. Edit the second step in the same way.
  5. Choose the third Step, choose the Status Handler tab.
  6. Under Error, choose GotoStep and step 4.
  7. Under Completed, choose MarkCompleted.
  8. Choose the last Step.
  9. Under Completed, choose RestartChain.
  10. Under Error, choose RequestRestart.
  11. Choose Save to save the chain definition.

Using Precondition Functions

The 1st step should only run on Mondays (with time window)

  1. Choose "Definitions > Chains".
  2. From the context-menu of the chain definition, choose Edit.
  3. Choose the first Step.
  4. Fill Monday into the Time Window field and select System_Week_Monday.
  5. Select is open in the Time Window Status field.
  6. Choose Save & Close to save the chain definition.

The 1st step should run on Mondays (with an expression)

  1. Choose "Definitions > Chains".
  2. From the context-menu of the chain definition, choose Edit.
  3. Choose the first Step.
  4. Fill =Time.isTimeWindowOpen(Time.now('GMT'), 'System_Week_Monday').
  5. Choose Save & Close to save the chain definition.

See Also

  • Chains

JobChain

← Creating Chain Definitions with Parallel Chain ProcessesCreating Chain Definitions for Multiple SAP Systems →
  • Procedure
  • Examples
    • Using Locks
    • Using Events
    • Using Status Handlers
    • Using Precondition Functions
  • See Also
Docs
Getting StartedInstallationFinance InstallationConcepts
TroubleshootingArchiving
Learn and Connect
Support Portal
BlogEventsResources
ISO/ IEC 27001 Information Security Management
Automate to be human

2023 All Rights Reserved |

Terms of Service | Policies | Cookies | Glossary | Third-party Software | Contact | Copyright | Impressum |