class BytesTool {
    public static Map<Integer, Session> agentSessionMap = new HashMap<>();

    public static void sendText(Session session, String message) {<FILL_FUNCTION_BODY>}
}

        if (session == null || !session.isOpen()) {
            return;
        }
        synchronized (session) {
            try {
                session.getBasicRemote().sendText(message);
            } catch (IllegalStateException | IOException e) {
                log.error("WebSocket send msg failed...");
            }
        }
    
<no_super_class>