Policies can control particular node properties, such as connection credentials, and certain aspects of message flow behavior, including flow rate. Policies provide a shared and managed definition that you can reuse.
{PolicyProjectName}:PolicyName
If the
named policy cannot be found, the message flow cannot be started.You can also reference a policy from a JavaCompute node by using the name of the policy in the Java code; for example:
Policies are XML documents, which are defined by an XML Schema Definition (Policy.xsd) that is found in the default installation directory. For example, on Windows, you can find the policy definition file at C:\Program Files\IBM\ACE\version\common\schemas\Policy.
Policies replace configurable services in App Connect Enterprise. You can migrate your existing configurable services to policies by using the mqsiextractcomponents command (see mqsiextractcomponents command).
The mqsicreateconfigurableservice command is deprecated in App Connect Enterprise, and no longer creates configurable services. However, if you have used the mqsicreateconfigurableservice command in your IBM Integration Bus scripts, this command creates equivalent policies (where supported) in App Connect Enterprise (see mqsicreateconfigurableservice command (deprecated)).
Policies that are created by the mqsicreateconfigurableservice command are created in the default policy project (DefaultPolicies) and are associated with an integration node. These policies therefore apply to resources that are deployed to all integration servers on that integration node. You can override a policy that is inherited by an integration server from the integration node by deploying an updated version of the policy to that integration server. Alternatively, you can put an updated policy in the overrides sub-directory of the integration server work directory (see Order of precedence for overrides).
Defaults:
defaultApplication: '' # Name a default application under which independent resources will be placed
policyProject: 'DefaultPolicies' # Name of the Policy project that will be used for unqualified Policy references
Policies:
# Set default policy names, optionally qualified with a policy project as {policy project}:name
httpConnector: '' # Default HTTP connector policy
httpsConnector: '' # Default HTTPS connector policy
mqConnector: '' # Default MQ connector policy
monitoringProfile: '' # Default Monitoring profile
After you create the policy, set the name of
the policy in the server.conf.yaml file. If the default policy is in the
default policy project, you do not need to specify the name of the policy project. If the default
policy is in a non-default policy project, qualify the name of the policy with the name of the
policy project
({policyProject}:PolicyName).You deploy policies in policy projects in an independent BAR file, or in a BAR file with the associated message flow. As an administrator, you can also copy the policy project to the overrides sub-directory of the integration server. If a policy name is set specifically on a message flow or message flow node, you must deploy the policy before the message flow can be started. If a policy is not specified explicitly on a message flow or message flow node, you must deploy the policy before or with the message flow.
You cannot update the values of a policy after it is deployed and you cannot delete a policy project after it is deployed. To change the values for a deployed policy, you must delete all deployed resources from the integration server by using the IBM App Connect Enterprise Toolkit or the -m parameter on the mqsideploy command. You must then redeploy the updated policy project and message flows. Alternatively, you can put an updated copy of the policy in the overrides sub-directory of the integration server work directory, then restart the integration server to pick up the new values.
Deployed policies are shown in the run sub-directory of the integration server work directory, within a sub-directory with the name of the policy project. You can see the properties of deployed policies in the Integration Explorer of the IBM App Connect Enterprise Toolkit or on the Policies tab of the web user interface (see Accessing the web user interface). You can also see which properties are being used by the deployed flow at run time by using the REST API or web user interface.
You can override a deployed policy by putting an updated policy project in the overrides sub-directory of the integration server work directory and restarting the integration server (see Overriding deployed policies at run time with the overrides directory).
Policies replace configurable services in IBM App Connect Enterprise Version 11.0. In previous versions, if you used a configurable service to override node properties at run time, a blank property in a configurable service overrode a node property with an empty value. However, when you use a policy, an empty property in a policy does not override the node property with an empty value. In this case, the value that is set by the node property is used.
For a list of available policy types, see Policy properties.