code: protected void writingMessage(Packet message) {
          if (message.getMessage() instanceof VideoData) {
              Number streamId = message.getHeader().getStreamId();
              final AtomicInteger value = new AtomicInteger();
              AtomicInteger old = pendingVideos.putIfAbsent(streamId.doubleValue(), value);
              if (old == null) {
                  old = value;
              }
              old.incrementAndGet();
          }
      }
docs: Mark message as being written.
  
  @param message
  Message to mark