We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CF linagora/tmail-flutter#3331
That's a lot of Echo request, I am unsure of the generated system load... I'd rather try to switch it to a less impactful mechanism.
Echo
Cf chatGPT
public class WebSocketServer { public static void main(String[] args) { HttpServer.create() .port(8080) // Port d'écoute du serveur .route(routes -> routes.ws("/ws", WebSocketServer::handleWebSocket)) .bindNow() .onDispose() .block(); } private static Mono<Void> handleWebSocket(WebsocketInbound inbound, WebsocketOutbound outbound) { // Gestion des messages reçus Flux<String> inboundMessages = inbound.receive() .asString() .doOnNext(message -> System.out.println("Message reçu : " + message)); // Envoi périodique de pings au client Flux<WebSocketFrame> pings = Flux.interval(Duration.ofSeconds(10)) // Ping toutes les 10 secondes .map(i -> new PingWebSocketFrame(Unpooled.copiedBuffer("ping", StandardCharsets.UTF_8))) .doOnNext(frame -> System.out.println("Envoi d'un ping au client")); // Flux combiné : traiter les messages entrants et envoyer des pings return outbound.send(pings) .mergeWith(inboundMessages.then()) // Continue d'écouter les messages entrants .then(); } }
Validate that it is enough to maintain a websocket connection opened through Apisix + Nginx
Add in jmap.properties the following configutration values:
jmap.properties
websocket.ping.interval=30s
If not specified then defaults to no ping!
The text was updated successfully, but these errors were encountered:
pr apache#2561
Sorry, something went wrong.
vttranlina
No branches or pull requests
Why ?
CF linagora/tmail-flutter#3331
That's a lot of
Echo
request, I am unsure of the generated system load... I'd rather try to switch it to a less impactful mechanism.How?
Cf chatGPT
Validate that it is enough to maintain a websocket connection opened through Apisix + Nginx
Add in
jmap.properties
the following configutration values:If not specified then defaults to no ping!
The text was updated successfully, but these errors were encountered: