@Override
  public void activateOptions() {
    String containerName = System.getProperty(JAVA_OPTS_CONTAINER_NAME);
    if (containerName == null) {
      throw new SamzaException("Got null container name from system property: " + JAVA_OPTS_CONTAINER_NAME +
          ". This is used as the key for the log appender, so can't proceed.");
    }
    key = containerName; // use the container name as the key for the logs
  }
Additional configurations needed before logging to stream. Called once in the container before the first log event is sent.
samza-log4j/src/main/java/org/apache/samza/logging/log4j/StreamAppender.java