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

Varun Saxena commented on YARN-4447:
------------------------------------

bq. I understand the reader code now wants to use it, but it should be able to 
use it from TimelineStorageUtils, right? I would be in favor of keeping it in 
TimelineStorageUtils and have the reader code use it.
Ok...I am fine with that.

bq. That's a good reason. However, you didn't mean that we write the 
expressions in the queries to the backend, right? We're talking about reading 
the values from the storage as is and comparing them to the query expression as 
is?
Yes, I meant that as from the writer side, configs,metrics,etc. are written 
as-is, we cannot convert them to lowercase when they arrive in filters. The 
responsibility of sending the config/metric in the correct case is 
responsibility of client.

bq. Specifically for checking for OR and AND, I believe it should be completely 
equivalent to expr.toLowerCase().indexOf("or ", offset) == offset
Sorry for the confusion.Yes, I agree with this suggestion of yours. Will change 
that.

 bq. If we were to avoid mutable filters, we would need to delay constructing 
the current filter until the value is successfully parsed. It doesn't look very 
obvious whether that is doable given the current shape of the parser code.
Will check on that. Current structure of code is such that they have to 
mutable. If we were to make them immutable, as you said, I will have to keep 
some extra variables and expose a single abstract method for setting 
everything(key, compare op and value in one shot).

> Provide a mechanism to represent complex filters and parse them at the REST 
> layer 
> ----------------------------------------------------------------------------------
>
>                 Key: YARN-4447
>                 URL: https://issues.apache.org/jira/browse/YARN-4447
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>          Components: timelineserver
>    Affects Versions: YARN-2928
>            Reporter: Varun Saxena
>            Assignee: Varun Saxena
>              Labels: yarn-2928-1st-milestone
>         Attachments: Timeline-Filters.pdf, YARN-4447-YARN-2928.01.patch
>
>




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

---------------------------------------------------------------------
To unsubscribe, e-mail: yarn-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: yarn-issues-h...@hadoop.apache.org

Reply via email to