Skip to main content

Background processing best practices

Suggest edit
Updated on August 25, 2021

To maintain and manage your work resources and to ensure that resource performance is not compromised if a node becomes unexpectedly unavailable, design your work assignments to be thread-safe and use a multi-threaded environment.

To ensure your work resources remain thread-safe, follow these best practices:

  • Instead of agents, use job schedulers and queue processors for all new development. Agent rules are no longer being actively developed; queue processor rules replace standard agents. For best performance and maintainability, replace agents with queue processor rules. For more information, see Using job schedulers and queue processors instead of agents.
  • For advanced agents, ensure that any custom actions are thread-safe or specify that the agent runs only on one node at a time. For more information, see Avoiding race conditions for advanced agents. For more information about client-required post-upgrade steps in Pega Cloud services environments, see Post-upgrade tasks following Pega Platform upgrades (7.x to 8.x).
  • For Pega Cloud services environments: Associate resources with node types rather than with specific node names or node IDs; associating a resource with a node ID can cause the resource to stop unexpectedly when the node is replaced, for example, due to a health check failure.
  • For on-premises environments:
    • To apply one or more node types to a node, use the JVM argument -DNodeTypes. For more information, see Assigning node types to nodes for on-premises environments.
    • To ensure system availability in the event that a node goes down unexpectedly, assign the same node type to multiple node instances.
    • Associate resources with node types rather than with specific node names or node IDs; this avoids resource failure if a node fails or you stop a node for maintenance.
  • Previous topic Managing background processing resources
  • Next topic Using job schedulers and queue processors instead of agents
Did you find this content helpful? YesNo

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us