Change shutdown_process_on_error thread spawn settings.

Now princeple is following: acceptor threads (libpq and http) error will
bring the pageserver down, but all per-tenant thread failures will be treated
as an error.
This commit is contained in:
Stas Kelvich
2022-05-03 23:57:24 +03:00
parent 2f83f793bc
commit 5642d0b2b8
2 changed files with 4 additions and 4 deletions

View File

@@ -287,7 +287,7 @@ fn start_pageserver(conf: &'static PageServerConf, daemonize: bool) -> Result<()
None,
None,
"http_endpoint_thread",
false,
true,
move || {
let router = http::make_router(conf, auth_cloned, remote_index)?;
endpoint::serve_thread_main(router, http_listener, thread_mgr::shutdown_watcher())
@@ -301,7 +301,7 @@ fn start_pageserver(conf: &'static PageServerConf, daemonize: bool) -> Result<()
None,
None,
"libpq endpoint thread",
false,
true,
move || page_service::thread_main(conf, auth, pageserver_listener, conf.auth_type),
)?;

View File

@@ -244,7 +244,7 @@ pub fn activate_tenant(tenant_id: ZTenantId) -> anyhow::Result<()> {
Some(tenant_id),
None,
"Compactor thread",
true,
false,
move || crate::tenant_threads::compact_loop(tenant_id),
)?;
@@ -253,7 +253,7 @@ pub fn activate_tenant(tenant_id: ZTenantId) -> anyhow::Result<()> {
Some(tenant_id),
None,
"GC thread",
true,
false,
move || crate::tenant_threads::gc_loop(tenant_id),
)
.with_context(|| format!("Failed to launch GC thread for tenant {tenant_id}"));