You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2019/08/30 16:30:58 UTC

[GitHub] [incubator-druid] leventov opened a new issue #8443: Standardized way to make intra-cluster (REST) queries

leventov opened a new issue #8443: Standardized way to make intra-cluster (REST) queries
URL: https://github.com/apache/incubator-druid/issues/8443
 
 
   ### Problem
   While we don't have nice Java API binding, as, for example, gRPC provides, intra-cluster queries are done in various ad-hoc ways, for example, using manual String formatting:
   
   https://github.com/apache/incubator-druid/blob/984958122b962ab019a590f4fd01792de81b75df/server/src/main/java/org/apache/druid/client/DirectDruidClient.java#L150-L151
   
   Or, constructing URLs in static methods:
   
   https://github.com/apache/incubator-druid/blob/984958122b962ab019a590f4fd01792de81b75df/server/src/main/java/org/apache/druid/server/lookup/cache/LookupCoordinatorManager.java#L717-L735
   
   This creates difficulty finding places in the code where a certain Druid API is called. Ideally, the experience should not be significantly worse than IDE's "Find usages" action.
   
   ### Proposed solution
   
   Every REST method (`@GET`/`@POST`-annotated) which is called within the cluster has an accompanying static method for forming an URL to call the method from a remote node. This accompanying static method is placed in a centralized place, such as `IntraClusterCalls` class. Javadocs for the REST method and the accompanying static method link to each other for easy navigation. All intra-cluster calls should be made using these static methods for creating URLs.
   
   
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org