paul-rogers commented on issue #13469: URL: https://github.com/apache/druid/issues/13469#issuecomment-1384741510
The first step in this project is to get a basic framework working. This is now done, see [this branch](https://github.com/paul-rogers/druid/tree/grpc-query). This branch points out a risk identified in the proposal: Druid's version of Guava is not compatible with the one that rRPC requires, resulting in the following exception: ```text java.lang.NoSuchMethodError: 'void com.google.common.base.Preconditions.checkArgument(boolean, java.lang.String, char, java.lang.Object)' ``` We will likely need to shade the gRPC + Guava library into a new library that the gRPC query extension can use. Some highlights of the "starter" code: * The code is in an extension: `extensions-contrib/grpc-query`. * The rRPC request, response and supporting Protobuf objects are coded, which required a few fixes to the first-cut draft in the proposal. * A gRPC server class exists, adapted from a gRPC example. It won't run, however, because of the Guava issue. * The gRPC server wants to start its own web server. This is awkward: we'll require many tuning and security settings in a production cluster. It would be better to run gRPC within Druid's existing Jetty web server. A quick internet search didn't return an obvious solution, so this is an open question. * To allow progress, the bulk of query execution is done in a "driver" (`QueryDriver`) class. This class works: it can run a SQL query and return results. It presently uses the existing SQL result formats. (I.e. CSV.) We'll need to add the protobuf encoding. Given this outline, next steps are: * Resolve the Guava conflict. * Resolve how to host gRPC within the Jetty server. If this can't be done, resolve the tuning and security issues associated with running a second web server. * Based on the above, define the `DruidModule` needed to integrate gRPC into the Druid server. * Work out how user authentication will be done. Create a `AuthenticationResult` object that identifies the user (actually, gives the result of authenticating the user.) * Design and code the Protobuf result format. There is much work to do. This starter code should, at least, take care of the boilerplate so we can focus on the gRPC-specific issues. -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
