Show TOC

Advanced Project Deployment OptionsLocate this document in the navigation structure

Project deployment options determine how your project is deployed in a cluster, and how it functions at runtime. Use Studio to set these parameters, including project options, active-active instances, failover intervals, and project deployment type options.

Active-Active Deployments

To deploy a project in active-active or HA (high availability) mode, set <Project ha="true"> in the CCR file. In an active-active deployment, two instances of a project run simultaneously in a cluster. Active-active projects are typically configured so that the cluster starts the two instances of the project on different nodes (hosts). This avoids the risk of a single point of failure at the project level.

One instance of the project is elected as the primary instance. If one of the instances is already active, it is the primary instance. If the failed instance restarts, it assumes the secondary position and maintains this position unless the current instance fails or is stopped.

Project Options
Project options are used as runtime parameters for the project, and include a predefined list of available option names that reflect most command line entries.
Instances

When a project is deployed in HA (active-active) mode, two instances are created: primary and secondary. Whether the project is in HA mode or not, you can set affinity and cold failover options for each instance, including failover intervals and failure per interval options. Non-HA projects have one instance, numbered 0 (zero). HA project instances are numbered 0 and 1. Some commands require instance numbers to identify instances of a project.

Failover

A project fails when it does not run properly, or stops running properly. If cold failover is enabled, a failover occurs when a failed project switches to another server to continue processing. Failover typically results during a project restart, though a strong positive affinity to a node that is not available can prevent a project from restarting. Restarts can be limited based on failure intervals and restarts per interval. Failover options, accessed using an instance configuration, include:

Field Description
Failover Valid values are enabled or disabled. When disabled, project failover restarts are not permitted. When enabled, failure interval and failures per interval fields can be accessed.
Failures per interval Specifies the number of restarts the project can attempt within a given interval. This count resets to zero if you restart the project manually, or if failures are dropped from the list because they are older than the size of the interval.
Failure interval (Optional) Specifies the time, in seconds, of an interval. If unspecified, the interval time is infinite.
Affinities
Affinities limit where a project does or does not run in a cluster. There are two types of affinities:
  • Controller – for active-active and non-active-active configurations. Controller affinities let you establish rules and preferences as to which controller nodes your project can run on. A project can have affinities for more than one node, but it can have a strong positive affinity for only one node.
  • Instance – only for active-active configurations. The two instances of an active-active project can have affinities for each other. For example, if you want such instances never to run on the same node, set strong negative instance affinities. If you want them to avoid running on the same node if possible, set weak negative instance affinities.
Define these parameters for each affinity:
Field Description
Name The name of the object of the affinity, which is the controller name or instance name that the affinity is set for. For instance affinities, the affinity for one instance must refer to the other instance.
Strength The strength of the affinity. Valid values are strong or weak.

Strong requires the project to run on a specific controller. If you have strong positive affinity set for a controller node, and the node fails, the failover process tries to restart the project on that node. If the node has not recovered, the project restart fails, and you must restart manually.

Weak requires the project to start on the preferred controller if possible, but if that controller is unavailable it may start on another available controller.

Charge The charge of the affinity. Valid values are positive or negative. If positive, the project runs (for a strong affinity) or prefers to run (for a weak affinity) on the named controller. If negative, the project does not run (or prefers not to run) on the named controller.
Processor Affinity

Processor Affinity lets you set a project to only run on specified processors. In HA (active-active) mode, processor affinities can be set separately for each instance.