public void process(IncomingMessageEnvelope envelope, MessageCollector collector, TaskCoordinator coordinator) {
    store.put((String) envelope.getMessage(), (String) envelope.getMessage());
    count++;
    if (count % LOG_INTERVAL == 0) {
      double ellapsedSecs = (System.currentTimeMillis() - start) / 1000.0;
      System.out.println(String.format("Throughput = %.2f messages/sec.", count / ellapsedSecs));
      start = System.currentTimeMillis();
      count = 0;
      coordinator.commit(RequestScope.ALL_TASKS_IN_CONTAINER);
    }
  }
A simple performance test that just reads in messages and writes them to a state store as quickly as possible and periodically prints out throughput numbers
samza-test/src/main/java/org/apache/samza/test/integration/StatePerfTestTask.java