Skip to content

Commit 9b9c7eb

Browse files
committed
docs(fault_manager): clarify the capture pool parallelizes snapshots only
Document that capture_pool_size parallelizes freeze-frame snapshot capture only - rosbag is single-writer and records one fault at a time regardless of pool size - and that the capture_* parameters govern the shared pool, which is created when snapshots or rosbag is enabled.
1 parent fc3df8b commit 9b9c7eb

5 files changed

Lines changed: 14 additions & 6 deletions

File tree

docs/config/fault-manager.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,10 @@ Basic Snapshot Settings
207207
new snapshots for that fault are rejected. Set to 0 for unlimited.
208208
* - ``snapshots.capture_pool_size``
209209
- ``2``
210-
- Max concurrent capture threads under a fault storm (>= 1).
210+
- Max concurrent capture threads under a fault storm (>= 1). The capture pool is
211+
shared and created when snapshots **or** rosbag is enabled, so these parameters
212+
bound both. ``capture_pool_size`` parallelizes freeze-frame snapshot capture
213+
only; rosbag is single-writer and records one fault at a time regardless.
211214
* - ``snapshots.capture_queue_depth``
212215
- ``16``
213216
- Max pending captures before the full-queue policy applies (>= 1).

docs/tutorials/snapshots.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,9 @@ Configure snapshot capture via fault manager parameters:
9292
new snapshots for that fault are rejected. Set to 0 for unlimited.
9393
* - ``snapshots.capture_pool_size``
9494
- ``2``
95-
- Max concurrent capture threads under a fault storm (>= 1).
95+
- Max concurrent capture threads under a fault storm (>= 1). This parallelizes
96+
freeze-frame snapshot capture only; rosbag capture is single-writer and
97+
records one fault at a time regardless of this value.
9698
* - ``snapshots.capture_queue_depth``
9799
- ``16``
98100
- Max pending captures before the full-queue policy applies (>= 1).

src/ros2_medkit_fault_manager/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ ros2 service call /fault_manager/clear_fault ros2_medkit_msgs/srv/ClearFault \
7070

7171
Snapshots capture topic data when faults are confirmed for post-mortem debugging.
7272

73-
Under a fault storm, captures are bounded by a worker pool (`capture_pool_size`) draining a bounded queue (`capture_queue_depth`); excess captures are dropped per `capture_queue_full_policy` and logged (throttled).
73+
Under a fault storm, captures are bounded by a worker pool (`capture_pool_size`) draining a bounded queue (`capture_queue_depth`); excess captures are dropped per `capture_queue_full_policy` and logged (throttled). The pool is shared and is created when snapshots **or** rosbag is enabled, so these parameters bound both. `capture_pool_size` parallelizes freeze-frame snapshot capture only - rosbag is single-writer and records one fault at a time regardless of pool size.
7474

7575
| Parameter | Type | Default | Description |
7676
|-----------|------|---------|-------------|
@@ -82,7 +82,7 @@ Under a fault storm, captures are bounded by a worker pool (`capture_pool_size`)
8282
| `snapshots.config_file` | string | `""` | Path to YAML config for `fault_specific` and `patterns` |
8383
| `snapshots.recapture_cooldown_sec` | double | `60.0` | Min seconds between captures for the same fault code. |
8484
| `snapshots.max_per_fault` | int | `10` | Max snapshots retained per fault. |
85-
| `snapshots.capture_pool_size` | int | `2` | Max concurrent capture threads under a fault storm (>= 1). |
85+
| `snapshots.capture_pool_size` | int | `2` | Max concurrent capture threads under a fault storm (>= 1). Parallelizes snapshot capture only; rosbag stays single-writer. |
8686
| `snapshots.capture_queue_depth` | int | `16` | Max pending captures before the full-queue policy applies (>= 1). |
8787
| `snapshots.capture_queue_full_policy` | string | `reject_newest` | Policy when the queue is full: `reject_newest` or `drop_oldest`. |
8888

src/ros2_medkit_fault_manager/config/fault_manager.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,10 @@ fault_manager:
2020
# storage backend is usable).
2121
snapshots.rosbag.enabled: false
2222

23-
# Capture concurrency bound under fault storms (issue #441):
23+
# Capture concurrency bound under fault storms (issue #441). These govern the
24+
# shared capture pool, which is created when snapshots OR rosbag is enabled, so
25+
# they also bound rosbag capture. Note: pool_size parallelizes freeze-frame
26+
# snapshots only - rosbag is single-writer and records one fault at a time.
2427
# snapshots.capture_pool_size: 2 # max concurrent capture threads (>= 1)
2528
# snapshots.capture_queue_depth: 16 # max pending captures (>= 1)
2629
# snapshots.capture_queue_full_policy: reject_newest # reject_newest | drop_oldest

src/ros2_medkit_gateway/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -932,7 +932,7 @@ Snapshots are configured via FaultManager parameters:
932932
| `snapshots.config_file` | string | `""` | Path to YAML config file for `fault_specific` and `patterns` |
933933
| `snapshots.recapture_cooldown_sec` | double | `60.0` | Min seconds between captures for the same fault code. |
934934
| `snapshots.max_per_fault` | int | `10` | Max snapshots retained per fault. |
935-
| `snapshots.capture_pool_size` | int | `2` | Max concurrent capture threads under a fault storm (>= 1). |
935+
| `snapshots.capture_pool_size` | int | `2` | Max concurrent capture threads under a fault storm (>= 1). Parallelizes snapshot capture only; rosbag stays single-writer (one fault at a time). |
936936
| `snapshots.capture_queue_depth` | int | `16` | Max pending captures before the full-queue policy applies (>= 1). |
937937
| `snapshots.capture_queue_full_policy` | string | `reject_newest` | Policy when the queue is full: `reject_newest` or `drop_oldest`. |
938938

0 commit comments

Comments
 (0)