hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zhijie Shen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-3009) TimelineWebServices always parses primary and secondary filters as numbers if first char is a number
Date Wed, 07 Jan 2015 19:46:34 GMT

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

Zhijie Shen commented on YARN-3009:
-----------------------------------

I didn't remember where we made the comment, but said the filter value is the JSON object
instead of the string. Therefore, it could be a number, a string or even a nested Jason structure,
couldn't it? In this case, 123 and "123" mean different things. Without quotes, the value
is considered as number. It seems that jackson ObjectReader is parsing the numeric value as
an ordinary atoi method, stopping at the first non-numeric letter. If the value cannot parse
it into a number at all, it will be taken as the string. Need to double check the behavior.

I'm not sure the aforementioned method is semantically correct if we assume the filter value
is a Json object. In addition, if the value is a nexted Json structure but not well formatted,
such as 
{code}
{     'a':1,    'b':       2}
{code}
After being converted to a Json object and then to a string, will it still be the aforementioned
string, or in a pretty format as follows
{code}
{
     'a':1,
     'b': 2
}
{code}
If it is the latter case, the string value is different from the original one, and the nested
Json structure will be mistaken as a string

> TimelineWebServices always parses primary and secondary filters as numbers if first char
is a number
> ----------------------------------------------------------------------------------------------------
>
>                 Key: YARN-3009
>                 URL: https://issues.apache.org/jira/browse/YARN-3009
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: timelineserver
>    Affects Versions: 2.6.0
>            Reporter: Chris K Wensel
>            Assignee: Naganarasimha G R
>         Attachments: YARN-3009.20150108-1.patch
>
>
> If you pass a filter value that starts with a number (7CCA...), the filter value will
be parsed into the Number '7' causing the filter to fail the search.
> Should be noted the actual value as stored via a PUT operation is properly parsed and
stored as a String.
> This manifests as a very hard to identify issue with DAGClient in Apache Tez and naming
dags/vertices with alphanumeric guid values.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message