remove rate
Some checks are pending
Docker Build and Push / build (push) Waiting to run

This commit is contained in:
Tsuki 2025-08-17 22:34:15 +08:00
parent 22f57d1c7e
commit 2f55eec940

View File

@ -105,19 +105,19 @@ pub async fn create_router(
router_s
.route("/graphql", get(not_found).post(graphql_handler))
.route_layer(
RateLimitLayer::<RealIp>::builder()
.with_route(
(Method::GET, "/graphql"),
Quota::new(Duration::from_millis(100), NonZero::new(10).unwrap()),
)
.with_route(
(Method::POST, "/graphql"),
Quota::new(Duration::from_millis(100), NonZero::new(10).unwrap()),
)
.with_gc_interval(1000)
.default_handle_error(),
)
// .route_layer(
// RateLimitLayer::<RealIp>::builder()
// .with_route(
// (Method::GET, "/graphql"),
// Quota::new(Duration::from_millis(100), NonZero::new(10).unwrap()),
// )
// .with_route(
// (Method::POST, "/graphql"),
// Quota::new(Duration::from_millis(100), NonZero::new(10).unwrap()),
// )
// .with_gc_interval(1000)
// .default_handle_error(),
// )
.route_service("/ws", GraphQLSubscription::new(schema))
.layer(CorsLayer::permissive())
.merge(router)