carbondata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kumarvishal09 <...@git.apache.org>
Subject [GitHub] incubator-carbondata pull request #470: [WIP]Fixed Performance issue for dic...
Date Tue, 28 Feb 2017 06:09:36 GMT
Github user kumarvishal09 commented on a diff in the pull request:

    https://github.com/apache/incubator-carbondata/pull/470#discussion_r103383147
  
    --- Diff: integration/spark/src/main/scala/org/apache/spark/sql/CarbonDictionaryDecoder.scala
---
    @@ -224,21 +226,39 @@ case class CarbonDictionaryDecoder(
       }
     
       private def getDictionary(atiMap: Map[String, AbsoluteTableIdentifier],
    -      cache: Cache[DictionaryColumnUniqueIdentifier, Dictionary]) = {
    -    val dicts: Seq[Dictionary] = getDictionaryColumnIds.map { f =>
    +                            cache: Cache[DictionaryColumnUniqueIdentifier, Dictionary])
= {
    +    val dictionaryColumnIds = getDictionaryColumnIds.map { f =>
           if (f._2 != null) {
    -        try {
    -          cache.get(new DictionaryColumnUniqueIdentifier(
    -            atiMap(f._1).getCarbonTableIdentifier,
    -            f._2, f._3))
    -        } catch {
    -          case _: Throwable => null
    -        }
    +        new DictionaryColumnUniqueIdentifier(
    +          atiMap(f._1).getCarbonTableIdentifier,
    +          f._2, f._3)
           } else {
             null
           }
         }
    -    dicts
    +    try {
    +      val noDictionaryIndexes = new java.util.ArrayList[Int]()
    +      dictionaryColumnIds.zipWithIndex.foreach { x =>
    +        if (x._1 == null) {
    --- End diff --
    
    ok


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message