From http://googlecloudplatform.github.io/google-cloud-java/0.9.2/apidocs/com/google/cloud/pubsub/spi/v1/Publisher.html
(Checked both 0.9.0-alpha or 0.9.2-alpha):
:
List<RpcFuture> results = new ArrayList<>();
:
Futures.addCallback(
Futures.allAsList(results),
:
Futures.allAsList & Futures.addCallback both require a ListenableFuture, not an RpcFuture.
The Rpc implementation is coming from Gax-0.1.0.