From 87773235eb18e5b711f1d1e09a017322229c623c Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Thu, 10 May 2018 14:14:49 +0300 Subject: send message read events to websocket users --- juick-server/src/main/java/com/juick/server/ServerManager.java | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'juick-server/src') diff --git a/juick-server/src/main/java/com/juick/server/ServerManager.java b/juick-server/src/main/java/com/juick/server/ServerManager.java index b6e3afcf..92821feb 100644 --- a/juick-server/src/main/java/com/juick/server/ServerManager.java +++ b/juick-server/src/main/java/com/juick/server/ServerManager.java @@ -202,6 +202,11 @@ public class ServerManager implements NotificationListener { serviceMessage.setUser(userTo); serviceMessage.setMid(source.getMid()); serviceMessage.setUnread(false); + try { + u.session.sendMessage(new TextMessage(jsonMapper.writeValueAsString(serviceMessage))); + } catch (IOException e) { + logger.error("JSON error", e); + } }); } } -- cgit v1.2.3