HMSH_BATCH_SIZE_MIN: number = ...

Minimum batch size under adaptive scaling (default: 1).

When stream depth is high, the adaptive logic reduces batch size to relieve back-pressure. This value is the floor — the smallest batch the system will fetch per consume cycle.

  • 1 (default): fully serial under max stress, safest
  • 2: retains some parallelism while limiting contention

Both values produce equivalent throughput in practice (~233s for 1000 concurrent workflows). The reduction from the configured HMSH_BATCH_SIZE is what matters most — the floor is a safety net.