修改部署文件

This commit is contained in:
xiuting.xu
2026-05-09 10:12:51 +08:00
parent ddeff71618
commit 84866c1d86
16 changed files with 117 additions and 30 deletions

View File

@@ -1,8 +1,9 @@
use arc_swap::ArcSwap;
use std::fs;
use std::io::BufReader;
use std::net::SocketAddr;
use std::path::{Path, PathBuf};
use std::sync::{Arc, RwLock};
use std::sync::Arc;
use std::time::Duration;
use rustls::{ClientConfig, RootCertStore};
@@ -45,7 +46,7 @@ fn load_pem_key(path: &Path) -> PrivateKeyDer<'static> {
}
fn test_cache() -> SharedRtrCache {
Arc::new(RwLock::new(
Arc::new(ArcSwap::from_pointee(
RtrCacheBuilder::new()
.session_ids(SessionIds::from_array([42, 42, 42]))
.serials([100, 100, 100])

View File

@@ -157,9 +157,17 @@ async fn start_tls_session_server_with_cert(
return;
};
let _ =
handle_tls_connection(cache, stream, peer_addr, acceptor, notify_rx, shutdown_rx, None)
.await;
let _ = handle_tls_connection(
cache,
stream,
peer_addr,
acceptor,
true,
notify_rx,
shutdown_rx,
None,
)
.await;
});
(addr, shutdown_tx, handle)