[
https://issues.apache.org/jira/browse/DRILL-4841?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15553341#comment-15553341
]
ASF GitHub Bot commented on DRILL-4841:
---------------------------------------
Github user paul-rogers commented on a diff in the pull request:
https://github.com/apache/drill/pull/565#discussion_r82268707
--- Diff:
exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/auth/AbstractDrillLoginService.java
---
@@ -46,8 +46,11 @@ protected DrillClient createDrillClient(final String
userName, final String pass
try {
// Create a DrillClient
- drillClient = new DrillClient(drillbitContext.getConfig(),
- drillbitContext.getClusterCoordinator(),
drillbitContext.getAllocator());
+ drillClient = DrillClient.newBuilder()
+ .setConfig(drillbitContext.getConfig())
+ .setClusterCoordinator(drillbitContext.getClusterCoordinator())
+ .setAllocator(drillbitContext.getAllocator())
+ .build();
--- End diff --
Should the builder be extended to also (optionally) do connect? Or, return
a connect builder?
Here I'm thinking that it would be helpful to have a single builder gather
things like the user name property and the connection string (which would seem
to be a DrillClient parameter but is actually a connection property.)
That is, either:
DrillClient.builder( ) ...
.withUser( userName )
.connectTo( "myHost", 1234 )
.build( );
Or
DrillClient.builder( ) ...
.buildClient( )
.withUser( userName )
.connectTo( "myHost", 1234 )
.connect( );
> Use user server event loop group for web clients
> ------------------------------------------------
>
> Key: DRILL-4841
> URL: https://issues.apache.org/jira/browse/DRILL-4841
> Project: Apache Drill
> Issue Type: Improvement
> Components: Client - HTTP
> Reporter: Sudheesh Katkam
> Assignee: Sorabh Hamirwasia
> Priority: Minor
>
> Currently we spawn an event loop group for handling requests from clients.
> This group should also be used to handles responses (from server) for web
> clients.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)