[router] support http2 in router (#6487)

This commit is contained in:
Zilin Zhu
2025-05-21 16:42:45 +08:00
committed by GitHub
parent 4024e1d2a8
commit 669caa0a3f

View File

@@ -264,7 +264,7 @@ pub async fn startup(config: ServerConfig) -> std::io::Result<()> {
// Default handler for unmatched routes.
.default_service(web::route().to(sink_handler))
})
.bind((config.host, config.port))?
.bind_auto_h2c((config.host, config.port))?
.run()
.await
}