knox-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (KNOX-1055) Spark page characters "&amp;" should be treated as a delimiter
Date Mon, 02 Oct 2017 15:38:00 GMT

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

ASF subversion and git services commented on KNOX-1055:
-------------------------------------------------------

Commit 90f1df7f5b4ed33a9462a46f2fc5afff032890a2 in knox's branch refs/heads/master from [~moresandeep]
[ https://git-wip-us.apache.org/repos/asf?p=knox.git;h=90f1df7 ]

KNOX-1055 - Spark page characters &amp; should be treated as a delimiter (Mars via Sandeep
More)


> Spark page characters "&amp;" should be treated as a delimiter
> --------------------------------------------------------------
>
>                 Key: KNOX-1055
>                 URL: https://issues.apache.org/jira/browse/KNOX-1055
>             Project: Apache Knox
>          Issue Type: Improvement
>          Components: Server
>    Affects Versions: 0.13.0
>            Reporter: Mars
>            Priority: Trivial
>              Labels: easyfix
>             Fix For: 0.14.0
>
>         Attachments: KNOX-1055.002.patch, KNOX-1055.patch
>
>
> I am a beginner of apache knox. When I use knox to proxy my sparkhistoryui, I meet this
problem.
> {noformat} <a href="/history/application_1505879554093_0036/stages/stage?id=0&amp;attempt=0"
class="name-link">{noformat}
> Some query parameters in the response body of the spark history ui contain a {noformat}&amp;{noformat}
> org.apache.hadoop.gateway.util.urltemplate.Parser#consumeQueryToken does not handle this
case
> {code:java}
> StringTokenizer tokenizer = new StringTokenizer( token, "?&" );
>       while( tokenizer.hasMoreTokens() ) {
>         consumeQuerySegment( builder, tokenizer.nextToken() );
>       }
> {code}
> so,I changed the code block as bellows
> {code:java}
> String[] tokens = token.split("(&amp;|\\?|&)");
>       if (tokens != null){
>         for (String nextToken : tokens){
>           consumeQuerySegment(builder,nextToken);
>         }
>       }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message