[ 
https://issues.apache.org/jira/browse/CALCITE-1539?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15934027#comment-15934027
 ] 

Josh Elser commented on CALCITE-1539:
-------------------------------------

bq. Oh, I see your confusion. Just don't create your own method. Make

Nevermind, I forgot that you need to pass in an {{HttpServletRequest}} as an 
argument. I think you can just make {{RemoteUserExtractor}} not extend 
{{Callable}}. Maybe simplify {{extractRemoteUser}} into just {{extract}}? :)

{code}
            remoteUser = 
serverConfig.getRemoteUserExtractor().extractRemoteUser(request);
{code}

This may be null. I think you should default to the 
{{HttpRequestRemoteUserExtractor}} instance. This avoids the null extractor as 
well avoiding a change in the semantics.

{code}
private RemoteUserExtractor remoteUserExtractor = new 
HttpRequestRemoteUserExtractor();
{code}

Otherwise, this looks pretty good. No tests though :) It would probably be 
relatively straightforward to copy {{BasicAuthHttpServerTest}} into a new class 
and exercise the new functionality you've added.

> Enable proxy access to Avatica server for third party on behalf of end users
> ----------------------------------------------------------------------------
>
>                 Key: CALCITE-1539
>                 URL: https://issues.apache.org/jira/browse/CALCITE-1539
>             Project: Calcite
>          Issue Type: Improvement
>          Components: avatica
>            Reporter: Jerry He
>            Assignee: Shi Wang
>         Attachments: 
> 0001-CALCITE-1539-Enable-proxy-access-to-Avatica-server-f.patch, 
> 0001-CALCITE-1539.patch, 0001-CALCITE-1539_without_testcase.patch
>
>
> We want to enable proxy access to Avatica server from an end user, but the 
> end user comes in via a third party impersonation.  For example, Knox and Hue.
> The Knox server user conveys the end user to Avatica.
> Similar things have been done for HBase Rest Sever HBASE-9866 and Hive Server 
> HIVE-5155



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to