code: private void doPushMessage(AbstractMessage message) {
          if (log.isTraceEnabled()) {
              String msgType = message.getMessageType();
              log.trace("doPushMessage: {}", msgType);
          }
          IMessageOutput out = msgOutReference.get();
          if (out != null) {
              try {
                  out.pushMessage(message);
                  if (message instanceof RTMPMessage) {
                      IRTMPEvent body = ((RTMPMessage) message).getBody();
                      // update the last message sent's timestamp
                      lastMessageTs = body.getTimestamp();
                      IoBuffer streamData = null;
                      if (body instanceof IStreamData && (streamData = ((IStreamData<?>) body).getData()) != null) {
                          bytesSent.addAndGet(streamData.limit());
                      }
                  }
              } catch (IOException err) {
                  log.warn("Error while pushing message", err);
              }
          } else {
              log.warn("Push message failed due to null output pipe");
          }
      }
docs: Send message to output stream and handle exceptions.
  
  @param message
  The message to send.