Skip to content

Commit 066ded6

Browse files
vaadin-botArtur-
andauthored
fix: log "Connection remotely closed" IOException at debug level (#22102) (#22125)
Changes the log level from ERROR to DEBUG for the specific IOException that occurs when a client connection dies during push communication. This reduces noise in logs, especially during integration tests. Fixes #21782 Co-authored-by: Artur <artur@vaadin.com>
1 parent b231680 commit 066ded6

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

‎flow-server/src/main/java/com/vaadin/flow/server/communication/PushAtmosphereHandler.java‎

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,14 @@ public void onDisconnect(AtmosphereResourceEvent event) {
108108

109109
@Override
110110
public void onThrowable(AtmosphereResourceEvent event) {
111-
getLogger().error("Exception in push connection",
112-
event.throwable());
111+
Throwable throwable = event.throwable();
112+
if (throwable instanceof IOException
113+
&& throwable.getMessage() != null && throwable.getMessage()
114+
.contains("Connection remotely closed")) {
115+
getLogger().debug("Push connection remotely closed", throwable);
116+
} else {
117+
getLogger().error("Exception in push connection", throwable);
118+
}
113119
pushHandler.connectionLost(event);
114120
}
115121
}

0 commit comments

Comments
 (0)