Skip to content

Commit 65fda65

Browse files
authored
Merge branch 'main' into tracing-part-10-da-retriever-v2
2 parents eeea8b6 + 50b35a9 commit 65fda65

File tree

1 file changed

+88
-0
lines changed

1 file changed

+88
-0
lines changed

docs/learn/config.md

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,11 @@ This document provides a comprehensive reference for all configuration options a
2929
- [DA Data Namespace](#da-data-namespace)
3030
- [DA Block Time](#da-block-time)
3131
- [DA Mempool TTL](#da-mempool-ttl)
32+
- [DA Request Timeout](#da-request-timeout)
33+
- [DA Batching Strategy](#da-batching-strategy)
34+
- [DA Batch Size Threshold](#da-batch-size-threshold)
35+
- [DA Batch Max Delay](#da-batch-max-delay)
36+
- [DA Batch Min Items](#da-batch-min-items)
3237
- [P2P Configuration (`p2p`)](#p2p-configuration-p2p)
3338
- [P2P Listen Address](#p2p-listen-address)
3439
- [P2P Peers](#p2p-peers)
@@ -508,6 +513,89 @@ _Example:_ `--rollkit.da.request_timeout 45s`
508513
_Default:_ `"30s"`
509514
_Constant:_ `FlagDARequestTimeout`
510515

516+
### DA Batching Strategy
517+
518+
**Description:**
519+
Controls how blocks are batched before submission to the DA layer. Different strategies offer trade-offs between latency, cost efficiency, and throughput. All strategies pass through the DA submitter which performs additional size checks and may further split batches that exceed the DA layer's blob size limit.
520+
521+
Available strategies:
522+
523+
- **`immediate`**: Submits as soon as any items are available. Best for low-latency requirements where cost is not a concern.
524+
- **`size`**: Waits until the batch reaches a size threshold (fraction of max blob size). Best for maximizing blob utilization and minimizing costs when latency is flexible.
525+
- **`time`**: Waits for a time interval before submitting. Provides predictable submission timing aligned with DA block times.
526+
- **`adaptive`**: Balances between size and time constraints—submits when either the size threshold is reached OR the max delay expires. Recommended for most production deployments as it optimizes both cost and latency.
527+
528+
**YAML:**
529+
530+
```yaml
531+
da:
532+
batching_strategy: "time"
533+
```
534+
535+
**Command-line Flag:**
536+
`--rollkit.da.batching_strategy <string>`
537+
_Example:_ `--rollkit.da.batching_strategy adaptive`
538+
_Default:_ `"time"`
539+
_Constant:_ `FlagDABatchingStrategy`
540+
541+
### DA Batch Size Threshold
542+
543+
**Description:**
544+
The minimum blob size threshold (as a fraction of the maximum blob size, between 0.0 and 1.0) before submitting a batch. Only applies to the `size` and `adaptive` strategies. For example, a value of 0.8 means the batch will be submitted when it reaches 80% of the maximum blob size.
545+
546+
Higher values maximize blob utilization and reduce costs but may increase latency. Lower values reduce latency but may result in less efficient blob usage.
547+
548+
**YAML:**
549+
550+
```yaml
551+
da:
552+
batch_size_threshold: 0.8
553+
```
554+
555+
**Command-line Flag:**
556+
`--rollkit.da.batch_size_threshold <float64>`
557+
_Example:_ `--rollkit.da.batch_size_threshold 0.9`
558+
_Default:_ `0.8` (80% of max blob size)
559+
_Constant:_ `FlagDABatchSizeThreshold`
560+
561+
### DA Batch Max Delay
562+
563+
**Description:**
564+
The maximum time to wait before submitting a batch regardless of size. Applies to the `time` and `adaptive` strategies. Lower values reduce latency but may increase costs due to smaller batches. This value is typically aligned with the DA chain's block time to ensure submissions land in consecutive blocks.
565+
566+
When set to 0, defaults to the DA BlockTime value.
567+
568+
**YAML:**
569+
570+
```yaml
571+
da:
572+
batch_max_delay: "6s"
573+
```
574+
575+
**Command-line Flag:**
576+
`--rollkit.da.batch_max_delay <duration>`
577+
_Example:_ `--rollkit.da.batch_max_delay 12s`
578+
_Default:_ `0` (uses DA BlockTime)
579+
_Constant:_ `FlagDABatchMaxDelay`
580+
581+
### DA Batch Min Items
582+
583+
**Description:**
584+
The minimum number of items (headers or data) to accumulate before considering submission. This helps avoid submitting single items when more are expected soon, improving batching efficiency. All strategies respect this minimum.
585+
586+
**YAML:**
587+
588+
```yaml
589+
da:
590+
batch_min_items: 1
591+
```
592+
593+
**Command-line Flag:**
594+
`--rollkit.da.batch_min_items <uint64>`
595+
_Example:_ `--rollkit.da.batch_min_items 5`
596+
_Default:_ `1`
597+
_Constant:_ `FlagDABatchMinItems`
598+
511599
## P2P Configuration (`p2p`)
512600

513601
Settings for peer-to-peer networking, enabling nodes to discover each other, exchange blocks, and share transactions.

0 commit comments

Comments
 (0)