avro-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Doug Cutting (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AVRO-585) add async RPC cllient
Date Thu, 24 Jun 2010 16:26:50 GMT

    [ https://issues.apache.org/jira/browse/AVRO-585?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12882207#action_12882207

Doug Cutting commented on AVRO-585:

Java Future's seem a good way to do this, Google's ListenableFuture in particular.


Here's a possible design:

Change Transceiver's primary method to:

ListenableFuture<List<ByteBuffer>> transceive(List<ByteBuffer>);

Change Responder's primary method to:

ListenableFuture<Object> respond(String messageName, Object parameters) throws Exception;

Re-define the old, synchronous, version in terms of this.

Have the compiler emit a second interface for each protocol, something like:

public interface Test$Future FutureProtocol {
  ListenableFuture<Utf8> echo(Utf8 greeting);

Add a method to SpecificRequestor to create a future-generating proxy with:

public FutureProtocol getFutureClient(Class<FutureClient>, Transceiver);

> add async RPC cllient
> ---------------------
>                 Key: AVRO-585
>                 URL: https://issues.apache.org/jira/browse/AVRO-585
>             Project: Avro
>          Issue Type: New Feature
>          Components: java
>            Reporter: Doug Cutting
> An async Java RPC client would be useful.  It could, for example, send out a set of requests
to be computed in parallel, then gather and combine the results as they are returned.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message