carbondata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jack...@apache.org
Subject [06/50] [abbrv] incubator-carbondata git commit: update CompareTest
Date Tue, 02 May 2017 14:12:30 GMT
update CompareTest


Project: http://git-wip-us.apache.org/repos/asf/incubator-carbondata/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-carbondata/commit/d3abcd91
Tree: http://git-wip-us.apache.org/repos/asf/incubator-carbondata/tree/d3abcd91
Diff: http://git-wip-us.apache.org/repos/asf/incubator-carbondata/diff/d3abcd91

Branch: refs/heads/12-dev
Commit: d3abcd91b4fa07c2ee09ea1e811ca008d10e3e1c
Parents: 462e29a
Author: jackylk <jacky.likun@huawei.com>
Authored: Sun Apr 23 12:51:34 2017 -0600
Committer: jackylk <jacky.likun@huawei.com>
Committed: Sun Apr 23 12:51:34 2017 -0600

----------------------------------------------------------------------
 .../main/scala/org/apache/carbondata/examples/CompareTest.scala  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-carbondata/blob/d3abcd91/examples/spark2/src/main/scala/org/apache/carbondata/examples/CompareTest.scala
----------------------------------------------------------------------
diff --git a/examples/spark2/src/main/scala/org/apache/carbondata/examples/CompareTest.scala
b/examples/spark2/src/main/scala/org/apache/carbondata/examples/CompareTest.scala
index 41a7850..1d24e36 100644
--- a/examples/spark2/src/main/scala/org/apache/carbondata/examples/CompareTest.scala
+++ b/examples/spark2/src/main/scala/org/apache/carbondata/examples/CompareTest.scala
@@ -70,7 +70,7 @@ object CompareTest {
     val rdd = spark.sparkContext
         .parallelize(1 to 10 * 1000 * 1000, 4)
         .map { x =>
-          ("city" + x % 8, "country" + x % 1103, "planet" + x % 10007, x.toString,
+          ("city" + x % 8, "country" + x % 1103, "planet" + x % 10007, "IDENTIFIER" + x.toString,
           (x % 16).toShort, x / 2, (x << 1).toLong, x.toDouble / 13, x.toDouble / 11)
         }.map { x =>
           Row(x._1, x._2, x._3, x._4, x._5, x._6, x._7, x._8, x._9)
@@ -279,6 +279,7 @@ object CompareTest {
     val loadParquetTime = loadParquetTable(spark, df)
     val loadCarbonV3Time = loadCarbonTable(spark, df, version = "3")
     println(s"load completed, time: $loadParquetTime, $loadCarbonV3Time")
+    df.unpersist()
     spark.read.parquet(parquetTableName).registerTempTable(parquetTableName)
   }
 
@@ -326,7 +327,6 @@ object CompareTest {
           s""""fetched":${parquetResult(index)._2}, """ +
           s""""type":"${query.queryType}", """ +
           s""""desc":"${query.desc}",  """ +
-          s""""timestamp": "$timestamp" """ +
           s""""date": "${formatter.format(date)}" """ +
           "}"
       )


Mime
View raw message