@Override
      public void onNext(StreamingExample.Average average) {
        if (started.compareAndSet(false, true)) {
          subscriber.onStart();
        }
        subscriber.onNext(average);
      }
Created by rayt on 11/2/16.
Thanks Mark (@mp911de) for helping out on this example!
streaming-example/streaming-client/src/main/java/com/example/grpc/client/AverageOnSubscribe.java