Dan Newton
05/08/2026, 11:00 AMRocky
05/08/2026, 11:00 AMmax_batch_interval | 10 seconds | The scheduling interval for tasks. It defines how often a new task is started.
task_consume_second | 15 seconds | The maximum duration a task spends consuming data before it stops and commits.
max_routine_load_batch_size | 4 GB | The maximum amount of data (in bytes) a task will consume before committing.
3. Typical Data Freshness
Under default settings, data typically becomes visible within 10 to 15 seconds.
* If data is flowing continuously, a task will consume for up to 15 seconds (or until the 4GB limit is hit) and then commit.
* If data volume is very low, the system waits for the max_batch_interval to trigger new tasks.
4. Tuning for Lower Latency
If you need higher freshness (lower latency), you can tune these parameters in your CREATE ROUTINE LOAD statement:
* Decrease max_batch_interval: You can lower this to a minimum of 5 seconds.
* Decrease task_consume_second: Setting this to a lower value (e.g., 5s) will force tasks to commit more frequently.
Note on Performance: While you can reduce these values to achieve 5-second freshness, setting them too low (e.g., below 5s) can lead to an excessive number of small data versions (tablets), which increases the overhead on the StarRocks compaction process and can eventually impact query performance. For best performance, the recommended minimum for max_batch_interval is 10 seconds.
References
• administration/management/FE_configuration.md
• sql-reference/sql-statements/loading_unloading/routine_load/CREATE_ROUTINE_LOAD.md
• administration/management/monitoring/metrics.md
• faq/loading/Routine_load_faq.md