private void insertEnvelope(PendingEnvelope pendingEnvelope) {
      pendingEnvelopeQueue.add(pendingEnvelope);
      int queueSize = pendingEnvelopeQueue.size();
      taskMetrics.pendingMessages().set(queueSize);
      log.trace("Insert envelope to task {} queue.", taskName);
      log.trace("Insert envelope to task {} queue.", taskName);
      log.debug("Task {} pending envelope count is {} after insertion.", taskName, queueSize);
    }
Insert an PendingEnvelope into the pending envelope queue.
The function will be called in the run loop thread so no synchronization.
@param pendingEnvelope
samza-core/src/main/java/org/apache/samza/container/RunLoop.java