code: public void sendMessage(final String message) {
          try {
              session.sendMessage(new TextMessage(message));
          }
          catch (IOException e) {
              logger.error("[sendTextMessage]", e);
          }
      }
docs: Sends a text message using this object's websocket session.
  @param message json binary message