NeoGraph 0.10.0
A C++17 Graph Agent Engine Library — LangGraph for C++
Loading...
Searching...
No Matches
neograph::graph::RetryPolicy Struct Reference

Retry policy for node execution with exponential backoff. More...

#include <types.h>

Public Attributes

float backoff_multiplier = 2.0f
 Multiplier applied to delay after each retry.
 
int initial_delay_ms = 100
 Delay before the first retry (milliseconds).
 
float jitter_pct = 0.0f
 Random jitter as a fraction of the computed delay, in [0, 1].
 
int max_delay_ms = 5000
 Maximum delay cap (milliseconds).
 
int max_retries = 0
 Maximum retry attempts. 0 = no retry.
 

Detailed Description

Retry policy for node execution with exponential backoff.

When a node fails, the engine retries according to this policy. Delay between retries grows exponentially: delay = initial_delay_ms * backoff_multiplier^attempt, capped at max_delay_ms.

Definition at line 172 of file types.h.

Member Data Documentation

◆ jitter_pct

float neograph::graph::RetryPolicy::jitter_pct = 0.0f

Random jitter as a fraction of the computed delay, in [0, 1].

The actual sleep is delay * (1 + uniform(-jitter_pct, +jitter_pct)). Default 0.0 = deterministic backoff (back-compat). Set to ~0.2 in fan-out scenarios where N parallel branches hit the same upstream rate-limit; without jitter they all retry in lockstep, producing thundering-herd 429 second waves.

Definition at line 183 of file types.h.


The documentation for this struct was generated from the following file: