Pass start_timeout to the neon_fixtrures.py::NeonEnvBuilder::start() method and set it to 30s

This commit is contained in:
Fedor Dikarev
2024-11-28 14:45:16 +01:00
parent e82f7f0dfc
commit 0e0d8276da
2 changed files with 5 additions and 2 deletions

View File

@@ -469,6 +469,7 @@ class NeonEnvBuilder:
default_remote_storage_if_missing: bool = True,
initial_tenant_shard_count: int | None = None,
initial_tenant_shard_stripe_size: int | None = None,
timeout_in_seconds: int | None = None,
) -> NeonEnv:
"""
Default way to create and start NeonEnv. Also creates the initial_tenant with root initial_timeline.
@@ -478,7 +479,7 @@ class NeonEnvBuilder:
Configuring pageserver with remote storage is now the default. There will be a warning if pageserver is created without one.
"""
env = self.init_configs(default_remote_storage_if_missing=default_remote_storage_if_missing)
env.start()
env.start(timeout_in_seconds=timeout_in_seconds)
# Prepare the default branch to start the postgres on later.
# Pageserver itself does not create tenants and timelines, until started first and asked via HTTP API.

View File

@@ -52,7 +52,9 @@ def test_sharding_smoke(
neon_env_builder.enable_pageserver_remote_storage(s3_storage())
env = neon_env_builder.init_start(
initial_tenant_shard_count=shard_count, initial_tenant_shard_stripe_size=stripe_size
initial_tenant_shard_count=shard_count,
initial_tenant_shard_stripe_size=stripe_size,
timeout_in_seconds=30, # Just 10s is not always enough
)
tenant_id = env.initial_tenant