Teamworks does not provide a model artefact specifically designed to maintain constants used within the Solution. Constants are used to promote consistency, improve maintenance and reduce typographical errors. Exposed Process Values (EPVs) are intended to be used to allow business users modify the parameters affecting business rules within the solution. However, EPVs may also be used to maintain constants.

For each EPV variable the External Name, Variable Name, External Description and Default Value should all be identical, as illustrated in Figure 1. Constants should not be directly exposed within the user interfaces, use localization resources instead.


2 comments on"Constants Pattern"

  1. This pattern is controversial. Indeed it is one way of trying to implement constants or enumerations, which are not a native concept or feature in IBM BPM. However there are multiple reasons not to do it, at least not as a general practice.

    First three discussion threads about constants, enumerations, exposed process value, environment variables etc:

    Constant Variables

    EPV (Exposed Process Variables) preferred over ENV as process constants

    Best Practices – Global Variables\Constants\Enums

    Also see the official documentation (this link is for 8.5.6):
    The recommended naming convention, in case one would ever like to expose EPV constants to an admin group, is different from the typical constant/enumeration naming such as EXAMPLE_CONSTANT.
    “Variable names should start with a lowercase letter, with subsequent words capitalized like so: myVar. Do not use underscores or spaces in variable names. Variable names are case sensitive.”

    • DennisParrott May 24, 2017

      Of course there are many techniques as outlined in the various discussions that can be used to implement constants in IBM BPM. The important thing is to promote consistency within your organisation to avoid multiple developers using different techniques within the same solution, as this will only lead to higher maintenance costs. Personally I have not found any issues using EPVs to implement constants. EPVs should not be used for text strings used for display purposes. Localization resources should be used for this purpose. Therefore the 64 character limit for EPVs should not cause an issue.

Join The Discussion

Your email address will not be published. Required fields are marked *