MCPcopy Create free account
hub / github.com/Dstack-TEE/dstack / start_bg_tasks

Method start_bg_tasks

gateway/src/main_service.rs:304–316  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

302
303impl Proxy {
304 pub(crate) async fn start_bg_tasks(&self) -> Result<()> {
305 start_recycle_thread(self.clone());
306 // Start WaveKV periodic sync (bootstrap already done in new())
307 if let Some(ref wavekv_sync) = self.wavekv_sync {
308 start_wavekv_sync_task(self.clone(), wavekv_sync.clone()).await;
309 }
310 start_wavekv_watch_task(self.clone()).context("Failed to start WaveKV watch task")?;
311 start_certbot_task(self.clone()).await;
312 start_cert_store_watch_task(self.clone());
313 start_zt_domain_watch_task(self.clone());
314 start_bootnode_discovery_task(self.clone());
315 Ok(())
316 }
317
318 /// Reload all certificates from KvStore into CertStore (atomic replacement)
319 pub(crate) fn reload_all_certs_from_kvstore(&self) -> Result<()> {

Callers 1

mainFunction · 0.80

Calls 8

start_recycle_threadFunction · 0.85
start_wavekv_sync_taskFunction · 0.85
start_wavekv_watch_taskFunction · 0.85
start_certbot_taskFunction · 0.85
cloneMethod · 0.80

Tested by

no test coverage detected