You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@kylin.apache.org by "Shaofeng SHI (JIRA)" <ji...@apache.org> on 2019/07/01 08:37:00 UTC

[jira] [Created] (KYLIN-4063) Avoid repeatedly calling "string.toLowerCase" in TimedJsonStreamParser#parse

Shaofeng SHI created KYLIN-4063:
-----------------------------------

             Summary: Avoid repeatedly calling "string.toLowerCase" in TimedJsonStreamParser#parse
                 Key: KYLIN-4063
                 URL: https://issues.apache.org/jira/browse/KYLIN-4063
             Project: Kylin
          Issue Type: Improvement
          Components: NRT Streaming
            Reporter: Shaofeng SHI


In TimedJsonStreamParser#parse, it has this:

 
{code:java}
for (TblColRef column : allColumns) {
    final String columnName = column.getName().toLowerCase(Locale.ROOT);
    if (populateDerivedTimeColumns(columnName, result, t) == false) {
        result.add(getValueByKey(column, root));
    }
}
{code}
 

As this method will be invoked for each message, and then for each column it will have a "toLowerCase(Locale.ROOT)", which is unnecessary, because the "allColumns" won't change.

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)