Skip to content

Commit

Permalink
page_service: enable batching in Rust & Python Tests + Python benchmarks
Browse files Browse the repository at this point in the history
This is the first step towards batching rollout.

Refs

- rollout neondatabase/cloud#20620
- task #9377
- uber-epic: #9376
  • Loading branch information
problame committed Dec 3, 2024
1 parent 4d422b9 commit e2a3ae0
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
9 changes: 8 additions & 1 deletion libs/pageserver_api/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,14 @@ impl Default for ConfigToml {
tenant_config: TenantConfigToml::default(),
no_sync: None,
wal_receiver_protocol: DEFAULT_WAL_RECEIVER_PROTOCOL,
page_service_pipelining: PageServicePipeliningConfig::Serial,
page_service_pipelining: if !cfg!(test) {
PageServicePipeliningConfig::Serial
} else {
PageServicePipeliningConfig::Pipelined(PageServicePipeliningConfigPipelined {
max_batch_size: NonZeroUsize::new(32).unwrap(),
execution: PageServiceProtocolPipelinedExecutionStrategy::ConcurrentFutures,
})
},
}
}
}
Expand Down
7 changes: 7 additions & 0 deletions test_runner/fixtures/neon_fixtures.py
Original file line number Diff line number Diff line change
Expand Up @@ -1094,6 +1094,13 @@ def __init__(self, config: NeonEnvBuilder):
# Disable pageserver disk syncs in tests: when running tests concurrently, this avoids
# the pageserver taking a long time to start up due to syncfs flushing other tests' data
"no_sync": True,
# Batching (https://github.com/neondatabase/neon/issues/9377):
# enable batching by default in tests and benchmarks.
"page_service_pipelining": {
"mode": "pipelined",
"execution": "concurrent-futures",
"max_batch_size": 32,
},
}
if self.pageserver_virtual_file_io_engine is not None:
ps_cfg["virtual_file_io_engine"] = self.pageserver_virtual_file_io_engine
Expand Down

0 comments on commit e2a3ae0

Please sign in to comment.