Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Heartbeat Period: 
    • The period after which the Agent sends a heartbeat to Master should no other HTTP operation on behalf of the Master be executed.
    • Default: 10s
  • Heartbeat Timeout: 
    • The overall timeout that determines if a connection is considered to be lost permanently.
    • Includes the heartbeat period and the delay after which the Master will send its heartbeat.
    • Default: 60s
  • Anchor
    heartbeat_delay
    heartbeat_delay
    Heartbeat Delay:
    • The time that the Master waits for before it receives the Agent's heartbeat should have come. 
    • Value: 2s
    • This is fixed parameter and can not be customized.

Behavior

Let suppose a connection between a Master and an Agent. The Master and the Agent will behave as follows:

  • In case where there is no connection loss:
    • the Master sends a HTTP Request to the Agent
    • the Agent sends
      • a heartbeat after 10s to the Master should no other HTTP operation on behalf of the Master be executed.
      • a HTTP response when an operation is executed on behalf of the Master.
  • In case the connection is lost after the Master has sent a HTTP Request:
    • the Master waits 12s for the heartbeat from the Agent to arrive.
      • The Agent should answer with the heartbeat after 10s
      • The Master waits 2s more just in case - this is the Heartbeat Delay mentioned above. 
    • If a heartbeat from the Agent came within 12s, any running tasks will be continued and completed by the Agent.
    • Otherwise, the Master repeats the HTTP Request sent 12s before and repeats this action until the Agent is able to answer
      • If the Agent is able to answer before 60s effected - that is, 48s after the HTTP Request repeat, any running tasks will be continued and completed by the Agent.
      • If the Agent is not able to answer before 60s effected - that is, 48s after the HTTP Request repeat, the Master will kill any running tasks on the Agent.

To summarize:

  • the Master could kill any running task on the Agent if the connection loss exceeded 48s. This limit case would happen if the connection loss takes place exactly when the Master should receive the Agent's heartbeat.
  • the Master will always kill any running task if the connection loss exceeds 60s. 

Use Case

Kill Tasks in case of Connection Loss

...

  • If the Master successfully re-connects to the Agent within the grace period then
    • running tasks will be continued and completed by the Agent.
    • the task status and execution result will be reported to the Master.
  • In case of reconciliation the task status, log information and execution result are available for the Master and are visible with JOC.

Behavior

Let suppose a connection between a Master and an Agent. The Master and the Agent will behave as follows:

  • In case where there is no connection loss:
  • the Master sends a HTTP Request to the Agent
  • the Agent sends
    a heartbeat after 10s to the Master should no other HTTP operation on behalf of the Master be executed

    .

  • a HTTP response when an operation is executed on behalf of the Master.
  • In case the connection is lost after the Master has sent a HTTP Request:
    • the Master waits 12s for the heartbeat from the Agent to arrive.
      • The Agent should answer with the heartbeat after 10s
      • The Master waits 2s more just in case - this is the Heartbeat Delay mentioned above. 
    • If a heartbeat from the Agent came within 12s, any running tasks will be continued and completed by the Agent.
    • Otherwise, the Master repeats the HTTP Request sent 12s before and repeats this action until the Agent is able to answer
      • If the Agent is able to answer before 60s effected - that is, 48s after the HTTP Request repeat, any running tasks will be continued and completed by the Agent.
      • If the Agent is not able to answer before 60s effected - that is, 48s after the HTTP Request repeat, the Master will kill any running tasks on the Agent.

...

Configuration

  • The heartbeat settings can be configured with the Process Classes that specify the Agent connection. 
  • The configuration is located with the Master, no configuration items are stored with the Agent.

...