tajo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jihoon...@apache.org
Subject [2/2] git commit: TAJO-494: Extend TajoClient to run a query with a plan context serialized as the JSON form. (jihoon)
Date Mon, 12 May 2014 05:13:28 GMT
TAJO-494: Extend TajoClient to run a query with a plan context serialized as the JSON form. (jihoon)


Project: http://git-wip-us.apache.org/repos/asf/tajo/repo
Commit: http://git-wip-us.apache.org/repos/asf/tajo/commit/9bbf87e3
Tree: http://git-wip-us.apache.org/repos/asf/tajo/tree/9bbf87e3
Diff: http://git-wip-us.apache.org/repos/asf/tajo/diff/9bbf87e3

Branch: refs/heads/master
Commit: 9bbf87e3a4396d90346fa41a0aef036f0e4f6a9f
Parents: ad53ffe
Author: Jihoon Son <jihoonson@apache.org>
Authored: Mon May 12 14:12:41 2014 +0900
Committer: Jihoon Son <jihoonson@apache.org>
Committed: Mon May 12 14:12:41 2014 +0900

----------------------------------------------------------------------
 CHANGES                                         |   3 +
 pom.xml                                         |   1 +
 .../org/apache/tajo/algebra/Aggregation.java    |   6 +
 .../org/apache/tajo/algebra/AlterTable.java     |   8 +
 .../apache/tajo/algebra/AlterTablespace.java    |   5 +
 .../apache/tajo/algebra/BetweenPredicate.java   |   8 +-
 .../org/apache/tajo/algebra/BinaryOperator.java |   4 +
 .../apache/tajo/algebra/CaseWhenPredicate.java  |   6 +
 .../java/org/apache/tajo/algebra/CastExpr.java  |   3 +
 .../apache/tajo/algebra/ColumnDefinition.java   |   4 +
 .../tajo/algebra/ColumnReferenceExpr.java       |   4 +
 .../org/apache/tajo/algebra/CreateDatabase.java |  21 ++
 .../org/apache/tajo/algebra/CreateTable.java    |  65 ++++++
 .../org/apache/tajo/algebra/DataTypeExpr.java   |   5 +
 .../org/apache/tajo/algebra/DateLiteral.java    |   3 +
 .../java/org/apache/tajo/algebra/DateValue.java |   5 +
 .../org/apache/tajo/algebra/DropDatabase.java   |   7 +-
 .../java/org/apache/tajo/algebra/DropTable.java |   5 +
 .../apache/tajo/algebra/ExistsPredicate.java    |   3 +
 .../main/java/org/apache/tajo/algebra/Expr.java |  20 +-
 .../org/apache/tajo/algebra/FunctionExpr.java   |   8 +-
 .../tajo/algebra/GeneralSetFunctionExpr.java    |   3 +
 .../java/org/apache/tajo/algebra/Having.java    |   3 +
 .../org/apache/tajo/algebra/InPredicate.java    |   4 +
 .../java/org/apache/tajo/algebra/Insert.java    |   9 +
 .../apache/tajo/algebra/IntervalLiteral.java    |   4 +
 .../apache/tajo/algebra/IsNullPredicate.java    |   3 +
 .../main/java/org/apache/tajo/algebra/Join.java |   6 +
 .../org/apache/tajo/algebra/JsonHelper.java     |   5 +-
 .../java/org/apache/tajo/algebra/Limit.java     |   3 +
 .../org/apache/tajo/algebra/LiteralValue.java   |  26 ++-
 .../java/org/apache/tajo/algebra/NamedExpr.java |   3 +
 .../tajo/algebra/PatternMatchPredicate.java     |   4 +
 .../org/apache/tajo/algebra/Projection.java     |   5 +-
 .../tajo/algebra/QualifiedAsteriskExpr.java     |   3 +
 .../java/org/apache/tajo/algebra/Relation.java  |   4 +
 .../org/apache/tajo/algebra/RelationList.java   |   3 +
 .../org/apache/tajo/algebra/ScalarSubQuery.java |   4 -
 .../java/org/apache/tajo/algebra/Selection.java |   3 +
 .../org/apache/tajo/algebra/SetOperation.java   |   3 +
 .../org/apache/tajo/algebra/SignedExpr.java     |   3 +
 .../tajo/algebra/SimpleTableSubQuery.java       |   4 -
 .../main/java/org/apache/tajo/algebra/Sort.java |   6 +
 .../tajo/algebra/TablePrimarySubQuery.java      |   4 +
 .../org/apache/tajo/algebra/TimeLiteral.java    |   3 +
 .../java/org/apache/tajo/algebra/TimeValue.java |   6 +
 .../apache/tajo/algebra/TimestampLiteral.java   |   4 +
 .../org/apache/tajo/algebra/UnaryOperator.java  |   3 +
 .../org/apache/tajo/algebra/ValueListExpr.java  |   3 +
 .../java/org/apache/tajo/algebra/TestExpr.java  |  43 ++++
 .../main/java/org/apache/tajo/cli/TajoCli.java  |  39 +++-
 .../java/org/apache/tajo/client/TajoClient.java |  70 +++++-
 tajo-client/src/main/proto/ClientProtos.proto   |   1 +
 .../org/apache/tajo/master/GlobalEngine.java    |  68 ++++--
 .../tajo/master/TajoMasterClientService.java    |   6 +-
 .../tajo/master/event/QueryStartEvent.java      |  10 +-
 .../master/querymaster/QueryInProgress.java     |  23 +-
 .../tajo/master/querymaster/QueryInfo.java      |  10 +-
 .../master/querymaster/QueryJobManager.java     |   6 +-
 .../tajo/master/querymaster/QueryMaster.java    |   2 +-
 .../querymaster/QueryMasterManagerService.java  |   2 +-
 .../master/querymaster/QueryMasterTask.java     |  22 +-
 .../src/main/proto/TajoWorkerProtocol.proto     |   4 +-
 .../java/org/apache/tajo/QueryTestCaseBase.java |  14 ++
 .../tajo/engine/query/TestGroupByQuery.java     |   9 +
 .../apache/tajo/engine/query/TestJoinQuery.java |  41 +++-
 .../tajo/engine/query/TestSelectQuery.java      |   7 +
 .../apache/tajo/engine/query/TestSortQuery.java |  16 ++
 .../tajo/engine/query/TestTableSubQuery.java    |  21 ++
 .../TestGroupByQuery/testGroupbyWithJson.json   |  98 +++++++++
 .../testJoinOnMultipleDatabasesWithJson.json    | 210 ++++++++++++++++++
 .../queries/TestJoinQuery/testJoinWithJson.json |  84 +++++++
 .../TestJoinQuery/testJoinWithJson2.json        | 219 +++++++++++++++++++
 .../TestSelectQuery/testSelectWithJson.json     |  74 +++++++
 .../queries/TestSortQuery/testSortWithJson.json |  65 ++++++
 .../queries/TestSortQuery/testTopkWithJson.json |  51 +++++
 .../testGroupbySubqueryWithJson.json            |  59 +++++
 .../testJoinSubqueryWithJson.json               | 108 +++++++++
 .../TestGroupByQuery/testGroupbyWithJson.result |   5 +
 .../testJoinOnMultipleDatabasesWithJson.result  |   5 +
 .../TestJoinQuery/testJoinWithJson.result       |  27 +++
 .../TestJoinQuery/testJoinWithJson2.result      |   5 +
 .../TestSelectQuery/testSelectWithJson.result   |   7 +
 .../TestSortQuery/testSortWithJson.result       |   5 +
 .../TestSortQuery/testTopkWithJson.result       |   5 +
 .../testGroupbySubqueryWithJson.result          |   3 +
 .../testJoinSubqueryWithJson.result             |   4 +
 87 files changed, 1671 insertions(+), 105 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/CHANGES
----------------------------------------------------------------------
diff --git a/CHANGES b/CHANGES
index a830776..17af7bc 100644
--- a/CHANGES
+++ b/CHANGES
@@ -4,6 +4,9 @@ Release 0.9.0 - unreleased
 
   NEW FEATURES
 
+    TAJO-494: Extend TajoClient to run a query with a plan context serialized as the 
+    JSON form. (jihoon)
+
     TAJO-761: Implements INTERVAL type. (Hyoungjun Kim via hyunsik)
 
     TAJO-790: Implements ADD_MONTHS() function. (Hyoungjun Kim via hyunsik)

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 47643e4..bf33c69 100644
--- a/pom.xml
+++ b/pom.xml
@@ -358,6 +358,7 @@
             <exclude>**/*.tbl</exclude>
             <exclude>**/*.js</exclude>
             <exclude>**/*.result</exclude>
+            <exclude>**/*.json</exclude>
             <exclude>**/*.avsc</exclude>
             <!-- generated content -->
             <exclude>**/target/**</exclude>

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Aggregation.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Aggregation.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Aggregation.java
index d1a6bd3..bf95e89 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Aggregation.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Aggregation.java
@@ -19,10 +19,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class Aggregation extends UnaryOperator {
+  @Expose @SerializedName("Targets")
   private NamedExpr[] namedExprs;
+  @Expose @SerializedName("Groups")
   private GroupElement [] groups;
 
   public Aggregation() {
@@ -64,7 +68,9 @@ public class Aggregation extends UnaryOperator {
   }
 
   public static class GroupElement implements JsonSerializable {
+    @Expose @SerializedName("GroupType")
     private GroupType group_type;
+    @Expose @SerializedName("Dimensions")
     private Expr [] grouping_sets;
 
     public GroupElement(GroupType groupType, Expr[] grouping_sets) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTable.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTable.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTable.java
index 4bb0ed2..0f56bc2 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTable.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTable.java
@@ -20,15 +20,23 @@ package org.apache.tajo.algebra;
 
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class AlterTable extends Expr {
 
+  @Expose @SerializedName("OldTableName")
   private String tableName;
+  @Expose @SerializedName("NewTableName")
   private String newTableName;
+  @Expose @SerializedName("OldColumnName")
   private String columnName;
+  @Expose @SerializedName("NewColumnName")
   private String newColumnName;
+  @Expose @SerializedName("NewColumnDef")
   private ColumnDefinition addNewColumn;
+  @Expose @SerializedName("AlterTableType")
   private AlterTableOpType alterTableOpType;
 
   public AlterTable(final String tableName) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTablespace.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTablespace.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTablespace.java
index ceec08b..b9cb0c7 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTablespace.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/AlterTablespace.java
@@ -20,13 +20,18 @@ package org.apache.tajo.algebra;
 
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class AlterTablespace extends Expr {
 
+  @Expose @SerializedName("TablespaceName")
   private String tablespaceName;
+  @Expose @SerializedName("AlterTablespaceType")
   private AlterTablespaceSetType setType;
 
+  @Expose @SerializedName("URI")
   private String uri;
 
   public AlterTablespace(final String tablespaceName) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/BetweenPredicate.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/BetweenPredicate.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/BetweenPredicate.java
index 4409f4e..4d4f09e 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/BetweenPredicate.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/BetweenPredicate.java
@@ -19,16 +19,22 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class BetweenPredicate extends Expr {
+  @Expose @SerializedName("IsNot")
   private boolean not;
   // if symmetric is not set, asymmetric is implicit.
+  @Expose @SerializedName("IsSymmetric")
   private boolean symmetric = false;
+  @Expose @SerializedName("Predicand")
   private Expr predicand;
+  @Expose @SerializedName("Begin")
   private Expr begin;
+  @Expose @SerializedName("End")
   private Expr end;
 
-
   public BetweenPredicate(boolean not, boolean symmetric, Expr predicand, Expr begin, Expr end) {
     super(OpType.Between);
     this.not = not;

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/BinaryOperator.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/BinaryOperator.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/BinaryOperator.java
index fa53067..0cc6376 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/BinaryOperator.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/BinaryOperator.java
@@ -19,9 +19,13 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class BinaryOperator extends Expr {
+  @Expose @SerializedName("LeftExpr")
   protected Expr left;
+  @Expose @SerializedName("RightExpr")
   protected Expr right;
 
   BinaryOperator(OpType opType) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/CaseWhenPredicate.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CaseWhenPredicate.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CaseWhenPredicate.java
index 6af1fb2..41eba6e 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CaseWhenPredicate.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CaseWhenPredicate.java
@@ -19,6 +19,8 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 import java.util.ArrayList;
@@ -26,7 +28,9 @@ import java.util.Collection;
 import java.util.List;
 
 public class CaseWhenPredicate extends Expr {
+  @Expose @SerializedName("WhenExprs")
   private List<WhenExpr> whens = new ArrayList<WhenExpr>();
+  @Expose @SerializedName("ElseExpr")
   private Expr elseResult;
 
   public CaseWhenPredicate() {
@@ -70,7 +74,9 @@ public class CaseWhenPredicate extends Expr {
   }
 
   public static class WhenExpr {
+    @Expose @SerializedName("Condition")
     Expr condition;
+    @Expose @SerializedName("Result")
     Expr result;
 
     public WhenExpr(Expr condition, Expr result) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/CastExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CastExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CastExpr.java
index 24f6415..5e0c5f0 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CastExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CastExpr.java
@@ -19,8 +19,11 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class CastExpr extends UnaryOperator {
+  @Expose @SerializedName("CastType")
   private DataTypeExpr target;
 
   public CastExpr(Expr operand, DataTypeExpr target) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnDefinition.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnDefinition.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnDefinition.java
index ce935dd..c20d409 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnDefinition.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnDefinition.java
@@ -17,7 +17,11 @@
  */
 package org.apache.tajo.algebra;
 
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
+
 public  class ColumnDefinition extends DataTypeExpr {
+  @Expose @SerializedName("ColumnDefName")
   String col_name;
 
   public ColumnDefinition(String columnName, String dataType) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnReferenceExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnReferenceExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnReferenceExpr.java
index 58f7b81..97bf332 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnReferenceExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ColumnReferenceExpr.java
@@ -19,10 +19,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class ColumnReferenceExpr extends Expr {
+  @Expose @SerializedName("Qualifier")
   private String qualifier;
+  @Expose @SerializedName("ColumnName")
   private String name;
 
   public ColumnReferenceExpr(String referenceName) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateDatabase.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateDatabase.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateDatabase.java
index a4ebc84..2ff0ce7 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateDatabase.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateDatabase.java
@@ -19,12 +19,21 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
+import java.util.Map;
+
 public class CreateDatabase extends Expr {
+  @Expose @SerializedName("DatabaseName")
   private String databaseName;
+  @Expose @SerializedName("TablespaceName")
   private String tablespaceName;
+  @Expose @SerializedName("IfNotExists")
   private boolean ifNotExists;
+  @Expose @SerializedName("DatabaseProperties")
+  private Map<String, String> params;
 
   public CreateDatabase(final String databaseName, final String tablespaceName, final boolean ifNotExists) {
     super(OpType.CreateDatabase);
@@ -49,6 +58,18 @@ public class CreateDatabase extends Expr {
     return ifNotExists;
   }
 
+  public boolean hasParams() {
+    return params != null;
+  }
+
+  public void setParams(Map<String, String> params) {
+    this.params = params;
+  }
+
+  public Map<String, String> getParams() {
+    return params;
+  }
+
   @Override
   public int hashCode() {
     return Objects.hashCode(databaseName, tablespaceName, ifNotExists);

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateTable.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateTable.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateTable.java
index 63ca364..f60b571 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateTable.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/CreateTable.java
@@ -19,20 +19,33 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.*;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
+import java.lang.reflect.Type;
 import java.util.List;
 import java.util.Map;
 
 public class CreateTable extends Expr {
+  @Expose @SerializedName("IsExternal")
   private boolean external = false;
+  @Expose @SerializedName("TableName")
   private String tableName;
+  @Expose @SerializedName("Attributes")
   private ColumnDefinition [] tableElements;
+  @Expose @SerializedName("StorageType")
   private String storageType;
+  @Expose @SerializedName("Location")
   private String location;
+  @Expose @SerializedName("SubPlan")
   private Expr subquery;
+  @Expose @SerializedName("TableProperties")
   private Map<String, String> params;
+  @Expose @SerializedName("PartitionMethodDesc")
   private PartitionMethodDescExpr partition;
+  @Expose @SerializedName("IfNotExists")
   private boolean ifNotExists;
 
   public CreateTable(final String tableName, boolean ifNotExists) {
@@ -163,6 +176,7 @@ public class CreateTable extends Expr {
   }
 
   public static abstract class PartitionMethodDescExpr {
+    @Expose @SerializedName("PartitionType")
     PartitionType type;
 
     public PartitionMethodDescExpr(PartitionType type) {
@@ -172,10 +186,50 @@ public class CreateTable extends Expr {
     public PartitionType getPartitionType() {
       return type;
     }
+
+    static class JsonSerDer implements JsonSerializer<PartitionMethodDescExpr>,
+        JsonDeserializer<PartitionMethodDescExpr> {
+
+      @Override
+      public PartitionMethodDescExpr deserialize(JsonElement json, Type typeOfT, JsonDeserializationContext context)
+          throws JsonParseException {
+        JsonObject jsonObject = json.getAsJsonObject();
+        PartitionType type = PartitionType.valueOf(jsonObject.get("PartitionType").getAsString());
+        switch (type) {
+          case RANGE:
+            return context.deserialize(json, RangePartition.class);
+          case HASH:
+            return context.deserialize(json, HashPartition.class);
+          case LIST:
+            return context.deserialize(json, ListPartition.class);
+          case COLUMN:
+            return context.deserialize(json, ColumnPartition.class);
+        }
+        return null;
+      }
+
+      @Override
+      public JsonElement serialize(PartitionMethodDescExpr src, Type typeOfSrc, JsonSerializationContext context) {
+        switch (src.getPartitionType()) {
+          case RANGE:
+            return context.serialize(src, RangePartition.class);
+          case HASH:
+            return context.serialize(src, HashPartition.class);
+          case LIST:
+            return context.serialize(src, ListPartition.class);
+          case COLUMN:
+            return context.serialize(src, ColumnPartition.class);
+          default:
+            return null;
+        }
+      }
+    }
   }
 
   public static class RangePartition extends PartitionMethodDescExpr {
+    @Expose @SerializedName("Columns")
     ColumnReferenceExpr [] columns;
+    @Expose @SerializedName("Specifiers")
     List<RangePartitionSpecifier> specifiers;
 
     public RangePartition(ColumnReferenceExpr [] columns, List<RangePartitionSpecifier> specifiers) {
@@ -208,8 +262,11 @@ public class CreateTable extends Expr {
   }
 
   public static class HashPartition extends PartitionMethodDescExpr {
+    @Expose @SerializedName("Columns")
     ColumnReferenceExpr [] columns;
+    @Expose @SerializedName("Quantity")
     Expr quantity;
+    @Expose @SerializedName("Specifiers")
     List<PartitionSpecifier> specifiers;
 
     public HashPartition(ColumnReferenceExpr [] columns, Expr quantity) {
@@ -260,7 +317,9 @@ public class CreateTable extends Expr {
   }
 
   public static class ListPartition extends PartitionMethodDescExpr {
+    @Expose @SerializedName("Columns")
     ColumnReferenceExpr [] columns;
+    @Expose @SerializedName("Specifiers")
     List<ListPartitionSpecifier> specifiers;
 
     public ListPartition(ColumnReferenceExpr [] columns, List<ListPartitionSpecifier> specifers) {
@@ -293,7 +352,9 @@ public class CreateTable extends Expr {
   }
 
   public static class ColumnPartition extends PartitionMethodDescExpr {
+    @Expose @SerializedName("Columns")
     private ColumnDefinition [] columns;
+    @Expose @SerializedName("IsOmitValues")
     private boolean isOmitValues;
 
     public ColumnPartition(ColumnDefinition [] columns, boolean isOmitValues) {
@@ -325,7 +386,9 @@ public class CreateTable extends Expr {
   }
 
   public static class RangePartitionSpecifier extends PartitionSpecifier {
+    @Expose @SerializedName("End")
     Expr end;
+    @Expose @SerializedName("IsMaxValue")
     boolean maxValue;
 
     public RangePartitionSpecifier(String name, Expr end) {
@@ -365,6 +428,7 @@ public class CreateTable extends Expr {
   }
 
   public static class ListPartitionSpecifier extends PartitionSpecifier {
+    @Expose @SerializedName("ValueList")
     ValueListExpr valueList;
 
     public ListPartitionSpecifier(String name, ValueListExpr valueList) {
@@ -393,6 +457,7 @@ public class CreateTable extends Expr {
   }
 
   public static class PartitionSpecifier {
+    @Expose @SerializedName("PartitionSpecName")
     private String name;
 
     public PartitionSpecifier(String name) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/DataTypeExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DataTypeExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DataTypeExpr.java
index 044a372..6978b84 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DataTypeExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DataTypeExpr.java
@@ -19,11 +19,16 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class DataTypeExpr extends Expr {
+  @Expose @SerializedName("DataTypeName")
   String typeName;
+  @Expose @SerializedName("LengthOrPrecision")
   Integer lengthOrPrecision;
+  @Expose @SerializedName("Scale")
   Integer scale;
 
   public DataTypeExpr(String typeName) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateLiteral.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateLiteral.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateLiteral.java
index 54b2b20..fafa8f8 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateLiteral.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateLiteral.java
@@ -19,8 +19,11 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class DateLiteral extends Expr {
+  @Expose @SerializedName("Date")
   private DateValue date;
 
   public DateLiteral(DateValue date) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateValue.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateValue.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateValue.java
index ad9d575..8424ab4 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateValue.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DateValue.java
@@ -19,10 +19,15 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class DateValue {
+  @Expose @SerializedName("Year")
   private String years;
+  @Expose @SerializedName("Month")
   private String months;
+  @Expose @SerializedName("Day")
   private String days;
 
   public DateValue(String years, String months, String days) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropDatabase.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropDatabase.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropDatabase.java
index 88e799c..fc949fd 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropDatabase.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropDatabase.java
@@ -20,10 +20,13 @@ package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
 import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class DropDatabase extends Expr {
-  @Expose private String databaseName;
-  @Expose private boolean ifExists;
+  @Expose @SerializedName("DatabaseName")
+  private String databaseName;
+  @Expose @SerializedName("IfExists")
+  private boolean ifExists;
 
   public DropDatabase(final String databaseName, final boolean ifExists) {
     super(OpType.DropDatabase);

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropTable.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropTable.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropTable.java
index cb0bbf4..c6e69dc 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropTable.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/DropTable.java
@@ -19,10 +19,15 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class DropTable extends Expr {
+  @Expose @SerializedName("TableName")
   private final String tableName;
+  @Expose @SerializedName("IfExists")
   private final boolean ifExists;
+  @Expose @SerializedName("IsPurge")
   private final boolean purge;
 
   public DropTable(String tableName, boolean ifExists, boolean purge) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/ExistsPredicate.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ExistsPredicate.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ExistsPredicate.java
index fcb8531..6bf2ddd 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ExistsPredicate.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ExistsPredicate.java
@@ -19,8 +19,11 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class ExistsPredicate extends UnaryOperator {
+  @Expose @SerializedName("IsNot")
   private boolean not;
 
   public ExistsPredicate(SimpleTableSubQuery simpleTableSubQuery, boolean not) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Expr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Expr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Expr.java
index 1ca42d7..daf59b6 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Expr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Expr.java
@@ -19,10 +19,16 @@
 package org.apache.tajo.algebra;
 
 import com.google.gson.*;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
+import org.apache.tajo.algebra.LiteralValue.LiteralType;
 
 import java.lang.reflect.Type;
 
 public abstract class Expr implements JsonSerializable {
+  private static final String SERIALIZED_NAME_OF_OP_TYPE = "OpType";
+
+  @Expose @SerializedName(SERIALIZED_NAME_OF_OP_TYPE)
   protected OpType opType;
 
 	public Expr(OpType opType) {
@@ -111,8 +117,18 @@ public abstract class Expr implements JsonSerializable {
                                     JsonDeserializationContext context)
         throws JsonParseException {
       JsonObject jsonObject = json.getAsJsonObject();
-      String operator = jsonObject.get("type").getAsString();
-      return context.deserialize(json, OpType.valueOf(operator).getBaseClass());
+      String opType = jsonObject.get(SERIALIZED_NAME_OF_OP_TYPE).getAsString();
+      if (OpType.valueOf(opType).equals(OpType.Literal)) {
+        String value = jsonObject.get("Value").getAsString();
+        JsonElement valueTypeElem = jsonObject.get("ValueType");
+        if (valueTypeElem != null) {
+          return new LiteralValue(value, LiteralType.valueOf(valueTypeElem.getAsString()));
+        } else {
+          return new LiteralValue(value, LiteralValue.getLiteralType(value));
+        }
+      } else {
+        return context.deserialize(json, OpType.valueOf(opType).getBaseClass());
+      }
     }
 
 

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/FunctionExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/FunctionExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/FunctionExpr.java
index 91517e7..b776cd2 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/FunctionExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/FunctionExpr.java
@@ -19,10 +19,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class FunctionExpr extends Expr {
+  @Expose @SerializedName("Signature")
   private String signature;
+  @Expose @SerializedName("FuncParams")
   private Expr[] params;
 
   public FunctionExpr(String signature) {
@@ -78,8 +82,4 @@ public class FunctionExpr extends Expr {
     return signature.equals(another.signature) &&
         TUtil.checkEquals(params, another.params);
   }
-
-  public String toJson() {
-    return JsonHelper.toJson(this);
-  }
 }

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/GeneralSetFunctionExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/GeneralSetFunctionExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/GeneralSetFunctionExpr.java
index d7eb4ed..fcb48df 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/GeneralSetFunctionExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/GeneralSetFunctionExpr.java
@@ -15,11 +15,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Preconditions;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 /**
  * Describes SQL Standard set function (e.g., sum, min, max, avg, and count)
  */
 public class GeneralSetFunctionExpr extends FunctionExpr {
+  @Expose @SerializedName("IsDistinct")
   private boolean distinct = false;
 
   /**

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Having.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Having.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Having.java
index 53bd9ba..dbe6f21 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Having.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Having.java
@@ -19,9 +19,12 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class Having extends UnaryOperator implements JsonSerializable {
+  @Expose @SerializedName("HavingCondition")
   private Expr qual;
 
   public Having(Expr qual) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/InPredicate.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/InPredicate.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/InPredicate.java
index 4eafe6e..52eb92a 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/InPredicate.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/InPredicate.java
@@ -18,7 +18,11 @@
 
 package org.apache.tajo.algebra;
 
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
+
 public class InPredicate extends BinaryOperator {
+  @Expose @SerializedName("IsNot")
   private boolean not;
 
   public InPredicate(Expr predicand, Expr in_values, boolean not) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Insert.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Insert.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Insert.java
index c427a39..3f15957 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Insert.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Insert.java
@@ -19,17 +19,26 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 import java.util.Map;
 
 public class Insert extends Expr {
+  @Expose @SerializedName("IsOverwrite")
   private boolean overwrite = false;
+  @Expose @SerializedName("TableName")
   private String tableName;
+  @Expose @SerializedName("TargetColumns")
   private String [] targetColumns;
+  @Expose @SerializedName("StorageType")
   private String storageType;
+  @Expose @SerializedName("Location")
   private String location;
+  @Expose @SerializedName("SubPlan")
   private Expr subquery;
+  @Expose @SerializedName("InsertParams")
   private Map<String, String> params;
 
   public Insert() {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/IntervalLiteral.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/IntervalLiteral.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/IntervalLiteral.java
index 6e0f2d0..f947d4f 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/IntervalLiteral.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/IntervalLiteral.java
@@ -18,7 +18,11 @@
 
 package org.apache.tajo.algebra;
 
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
+
 public class IntervalLiteral extends Expr {
+  @Expose @SerializedName("LiteralExpr")
   private String exprStr;
 
   public IntervalLiteral(String str) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/IsNullPredicate.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/IsNullPredicate.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/IsNullPredicate.java
index 40f5dd2..f9f6e11 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/IsNullPredicate.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/IsNullPredicate.java
@@ -19,8 +19,11 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class IsNullPredicate extends UnaryOperator {
+  @Expose @SerializedName("IsNot")
   private final boolean not;
 
   public IsNullPredicate(boolean not, Expr column) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Join.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Join.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Join.java
index 258f750..2acdde3 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Join.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Join.java
@@ -19,12 +19,18 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class Join extends BinaryOperator {
+  @Expose @SerializedName("JoinType")
   private JoinType joinType;
+  @Expose @SerializedName("JoinCondition")
   private Expr joinQual;
+  @Expose @SerializedName("JoinColumns")
   private ColumnReferenceExpr[] joinColumns;
+  @Expose @SerializedName("IsNatural")
   private boolean natural = false;
 
   public Join(JoinType joinType) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/JsonHelper.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/JsonHelper.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/JsonHelper.java
index f05a4ea..7d853d6 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/JsonHelper.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/JsonHelper.java
@@ -20,6 +20,7 @@ package org.apache.tajo.algebra;
 
 import com.google.gson.Gson;
 import com.google.gson.GsonBuilder;
+import org.apache.tajo.algebra.CreateTable.PartitionMethodDescExpr;
 
 public class JsonHelper {
   private static JsonHelper instance;
@@ -37,9 +38,11 @@ public class JsonHelper {
   }
 
   private void initBuilder() {
-    builder = new GsonBuilder().setPrettyPrinting();
+    builder = new GsonBuilder().setPrettyPrinting().
+        excludeFieldsWithoutExposeAnnotation();
     builder.registerTypeAdapter(OpType.class, new OpType.JsonSerDer());
     builder.registerTypeAdapter(Expr.class, new Expr.JsonSerDer());
+    builder.registerTypeAdapter(PartitionMethodDescExpr.class, new PartitionMethodDescExpr.JsonSerDer());
   }
 
 

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Limit.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Limit.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Limit.java
index a217c5e..20dad6b 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Limit.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Limit.java
@@ -20,8 +20,11 @@ package org.apache.tajo.algebra;
 
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class Limit extends UnaryOperator {
+  @Expose @SerializedName("Num")
   private Expr fetchFirstNum;
 
   public Limit(Expr fetchFirstNum) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/LiteralValue.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/LiteralValue.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/LiteralValue.java
index 2978c06..7747ff9 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/LiteralValue.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/LiteralValue.java
@@ -19,10 +19,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class LiteralValue extends Expr {
-  protected LiteralType valueType;
+  @Expose @SerializedName("Value")
   protected String value;
+  @Expose @SerializedName("ValueType")
+  protected LiteralType valueType;
 
   public static enum LiteralType {
     Boolean,
@@ -63,4 +67,24 @@ public class LiteralValue extends Expr {
     sb.append("(").append(valueType).append(")");
     return sb.toString();
   }
+
+  public static LiteralType getLiteralType(String value) {
+    if (value.equals("TRUE") || value.equals("FALSE")) {
+      return LiteralType.Boolean;
+    } else {
+      try {
+        Long.parseLong(value);
+        return LiteralType.Unsigned_Integer;
+      } catch (NumberFormatException e) {}
+
+      try {
+        Double.parseDouble(value);
+        return LiteralType.Unsigned_Float;
+      } catch (NumberFormatException e) {}
+
+      // TODO: handle unsigned_large_integer
+
+      return LiteralType.String;
+    }
+  }
 }

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/NamedExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/NamedExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/NamedExpr.java
index bd73481..31e835f 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/NamedExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/NamedExpr.java
@@ -19,6 +19,8 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 /**
@@ -35,6 +37,7 @@ import org.apache.tajo.util.TUtil;
  * Each expression can be explicitly aliased as an given name.
  */
 public class NamedExpr extends UnaryOperator {
+  @Expose @SerializedName("AliasName")
   private String alias;
 
   public NamedExpr(Expr expr) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/PatternMatchPredicate.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/PatternMatchPredicate.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/PatternMatchPredicate.java
index 6f5ab68..2399e03 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/PatternMatchPredicate.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/PatternMatchPredicate.java
@@ -19,9 +19,13 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Preconditions;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class PatternMatchPredicate extends BinaryOperator {
+  @Expose @SerializedName("IsNot")
   private boolean not;
+  @Expose @SerializedName("IsCaseInsensitive")
   private boolean caseInsensitive;
 
   public PatternMatchPredicate(OpType opType, boolean not, Expr predicand, Expr pattern,

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Projection.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Projection.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Projection.java
index 0e8ed46..6ffc502 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Projection.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Projection.java
@@ -19,11 +19,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class Projection extends UnaryOperator implements Cloneable {
+  @Expose @SerializedName("IsDistinct")
   private boolean distinct = false;
-
+  @Expose @SerializedName("Projections")
   private NamedExpr[] targets;
 
   public Projection() {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/QualifiedAsteriskExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/QualifiedAsteriskExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/QualifiedAsteriskExpr.java
index d26deb9..f067e59 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/QualifiedAsteriskExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/QualifiedAsteriskExpr.java
@@ -19,10 +19,13 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class QualifiedAsteriskExpr extends Expr {
   private final static String ASTERISK = "*";
+  @Expose @SerializedName("Qualifier")
   private String qualifier;
 
   public QualifiedAsteriskExpr() {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Relation.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Relation.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Relation.java
index 406794a..c865454 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Relation.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Relation.java
@@ -19,10 +19,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class Relation extends Expr {
+  @Expose @SerializedName("TableName")
   private String tableName;
+  @Expose @SerializedName("TableAlias")
   private String alias;
 
   protected Relation(OpType type, String relationName) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/RelationList.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/RelationList.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/RelationList.java
index 18c4ce9..fdf6c94 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/RelationList.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/RelationList.java
@@ -16,11 +16,14 @@ package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
 import com.google.common.base.Preconditions;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 import java.util.Set;
 
 public class RelationList extends Expr {
+  @Expose @SerializedName("Relations")
   private Expr[] relations;
 
   public RelationList(Expr[] relations) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/ScalarSubQuery.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ScalarSubQuery.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ScalarSubQuery.java
index 425c08f..b37b149 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ScalarSubQuery.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ScalarSubQuery.java
@@ -33,8 +33,4 @@ public class ScalarSubQuery extends UnaryOperator {
   boolean equalsTo(Expr expr) {
     return true;
   }
-
-  public String toJson() {
-    return JsonHelper.toJson(this);
-  }
 }

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Selection.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Selection.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Selection.java
index 364e1b7..9cc245e 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Selection.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Selection.java
@@ -19,9 +19,12 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class Selection extends UnaryOperator implements JsonSerializable {
+  @Expose @SerializedName("SelectCondition")
   private Expr qual;
 
   public Selection(Expr qual) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/SetOperation.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/SetOperation.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/SetOperation.java
index 08ebd6a..c20bf06 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/SetOperation.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/SetOperation.java
@@ -21,8 +21,11 @@ package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
 import com.google.common.base.Preconditions;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class SetOperation extends BinaryOperator {
+  @Expose @SerializedName("IsDistinct")
   private boolean distinct = true;
 
   public SetOperation(OpType type, Expr left, Expr right, boolean distinct) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/SignedExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/SignedExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/SignedExpr.java
index 7b3438c..0c04341 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/SignedExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/SignedExpr.java
@@ -19,8 +19,11 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class SignedExpr extends UnaryOperator {
+  @Expose @SerializedName("IsNegative")
   private boolean negative;
 
   public SignedExpr(boolean negative, Expr operand) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/SimpleTableSubQuery.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/SimpleTableSubQuery.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/SimpleTableSubQuery.java
index 7bd3b78..2332be1 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/SimpleTableSubQuery.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/SimpleTableSubQuery.java
@@ -33,8 +33,4 @@ public class SimpleTableSubQuery extends UnaryOperator {
   boolean equalsTo(Expr expr) {
     return true;
   }
-
-  public String toJson() {
-    return JsonHelper.toJson(this);
-  }
 }

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/Sort.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Sort.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Sort.java
index c047c54..0632b2e 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/Sort.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/Sort.java
@@ -19,9 +19,12 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class Sort extends UnaryOperator {
+  @Expose @SerializedName("SortSpecs")
   private SortSpec [] sortSpecs;
 
   public Sort(final SortSpec [] sortSpecs) {
@@ -54,8 +57,11 @@ public class Sort extends UnaryOperator {
   }
 
   public static class SortSpec {
+    @Expose @SerializedName("SortKey")
     private Expr key;
+    @Expose @SerializedName("IsAsc")
     private boolean asc = true;
+    @Expose @SerializedName("IsNullFirst")
     private boolean nullFirst = false;
 
     public SortSpec(final Expr key) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/TablePrimarySubQuery.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TablePrimarySubQuery.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TablePrimarySubQuery.java
index 953c080..5c55164 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TablePrimarySubQuery.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TablePrimarySubQuery.java
@@ -19,10 +19,14 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class TablePrimarySubQuery extends Relation {
+  @Expose @SerializedName("SubPlan")
   private Expr subquery;
+  @Expose @SerializedName("ColumnNames")
   private String [] columnNames;
 
   public TablePrimarySubQuery(String relName, Expr subquery) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeLiteral.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeLiteral.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeLiteral.java
index e939128..7baccd8 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeLiteral.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeLiteral.java
@@ -19,8 +19,11 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class TimeLiteral extends Expr {
+  @Expose @SerializedName("Time")
   private TimeValue time;
 
   public TimeLiteral(TimeValue time) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeValue.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeValue.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeValue.java
index b41b644..6ad75bc 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeValue.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimeValue.java
@@ -19,12 +19,18 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.commons.lang.StringUtils;
 
 public class TimeValue {
+  @Expose @SerializedName("Hour")
   private String hours;
+  @Expose @SerializedName("Minute")
   private String minutes;
+  @Expose @SerializedName("Second")
   private String seconds;
+  @Expose @SerializedName("SecondFrac")
   private String secondsFraction; // optional
 
   public TimeValue(String hours, String minutes, String seconds) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimestampLiteral.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimestampLiteral.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimestampLiteral.java
index cb6f5a1..5ee20d3 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimestampLiteral.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/TimestampLiteral.java
@@ -19,9 +19,13 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public class TimestampLiteral extends Expr {
+  @Expose @SerializedName("Date")
   private DateValue date;
+  @Expose @SerializedName("Time")
   private TimeValue time;
 
   public TimestampLiteral(DateValue date, TimeValue time) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/UnaryOperator.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/UnaryOperator.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/UnaryOperator.java
index 2a1e730..e266393 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/UnaryOperator.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/UnaryOperator.java
@@ -19,8 +19,11 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 
 public abstract class UnaryOperator extends Expr {
+  @Expose @SerializedName("Expr")
   private Expr child;
 
   public UnaryOperator(OpType type) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/main/java/org/apache/tajo/algebra/ValueListExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ValueListExpr.java b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ValueListExpr.java
index 8d51a95..c5eafb6 100644
--- a/tajo-algebra/src/main/java/org/apache/tajo/algebra/ValueListExpr.java
+++ b/tajo-algebra/src/main/java/org/apache/tajo/algebra/ValueListExpr.java
@@ -19,9 +19,12 @@
 package org.apache.tajo.algebra;
 
 import com.google.common.base.Objects;
+import com.google.gson.annotations.Expose;
+import com.google.gson.annotations.SerializedName;
 import org.apache.tajo.util.TUtil;
 
 public class ValueListExpr extends Expr {
+  @Expose @SerializedName("Values")
   private Expr[] values;
 
   public ValueListExpr(Expr[] values) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-algebra/src/test/java/org/apache/tajo/algebra/TestExpr.java
----------------------------------------------------------------------
diff --git a/tajo-algebra/src/test/java/org/apache/tajo/algebra/TestExpr.java b/tajo-algebra/src/test/java/org/apache/tajo/algebra/TestExpr.java
index f327739..513b66a 100644
--- a/tajo-algebra/src/test/java/org/apache/tajo/algebra/TestExpr.java
+++ b/tajo-algebra/src/test/java/org/apache/tajo/algebra/TestExpr.java
@@ -142,4 +142,47 @@ public class TestExpr {
 
     return sort;
   }
+
+  @Test
+  public void testJson() {
+    Expr left1 = new BinaryOperator(OpType.Plus,
+        new LiteralValue("1", LiteralType.Unsigned_Integer),
+        new LiteralValue("2", LiteralType.Unsigned_Integer));
+
+    Expr right1 = new BinaryOperator(OpType.Multiply,
+        new LiteralValue("2", LiteralType.Unsigned_Integer),
+        new LiteralValue("3", LiteralType.Unsigned_Integer));
+
+    Expr origin = new BinaryOperator(OpType.Plus, left1, right1);
+    String json = origin.toJson();
+    Expr fromJson = JsonHelper.fromJson(json, Expr.class);
+    assertEquals(origin, fromJson);
+  }
+
+  @Test
+  public void testJson2() {
+    Expr expr = new BinaryOperator(OpType.LessThan,
+        new LiteralValue("1", LiteralType.Unsigned_Integer),
+        new LiteralValue("2", LiteralType.Unsigned_Integer));
+
+    Relation relation = new Relation("employee");
+    Selection selection = new Selection(expr);
+    selection.setChild(relation);
+
+    Aggregation aggregation = new Aggregation();
+    aggregation.setTargets(new NamedExpr[]{
+            new NamedExpr(new ColumnReferenceExpr("col1"))
+        }
+    );
+
+    aggregation.setChild(selection);
+
+    Sort.SortSpec spec = new Sort.SortSpec(new ColumnReferenceExpr("col2"));
+    Sort sort = new Sort(new Sort.SortSpec[]{spec});
+    sort.setChild(aggregation);
+
+    String json = sort.toJson();
+    Expr fromJson = JsonHelper.fromJson(json, Expr.class);
+    assertEquals(sort, fromJson);
+  }
 }

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-client/src/main/java/org/apache/tajo/cli/TajoCli.java
----------------------------------------------------------------------
diff --git a/tajo-client/src/main/java/org/apache/tajo/cli/TajoCli.java b/tajo-client/src/main/java/org/apache/tajo/cli/TajoCli.java
index 7489351..c7368c9 100644
--- a/tajo-client/src/main/java/org/apache/tajo/cli/TajoCli.java
+++ b/tajo-client/src/main/java/org/apache/tajo/cli/TajoCli.java
@@ -301,15 +301,19 @@ public class TajoCli {
         continue;
       }
 
-      List<ParsedResult> parsedResults = parser.parseLines(line);
+      if (line.startsWith("{")) {
+        executeJsonQuery(line);
+      } else {
+        List<ParsedResult> parsedResults = parser.parseLines(line);
 
-      if (parsedResults.size() > 0) {
-        for (ParsedResult parsed : parsedResults) {
-          history.addStatement(parsed.getHistoryStatement() + (parsed.getType() == STATEMENT ? ";":""));
+        if (parsedResults.size() > 0) {
+          for (ParsedResult parsed : parsedResults) {
+            history.addStatement(parsed.getHistoryStatement() + (parsed.getType() == STATEMENT ? ";" : ""));
+          }
+          executeParsedResults(parsedResults);
+          currentPrompt = updatePrompt(parser.getState());
         }
       }
-      executeParsedResults(parsedResults);
-      currentPrompt = updatePrompt(parser.getState());
     }
     return code;
   }
@@ -351,6 +355,29 @@ public class TajoCli {
     return 0;
   }
 
+  private void executeJsonQuery(String json) throws ServiceException {
+    long startTime = System.currentTimeMillis();
+    ClientProtos.SubmitQueryResponse response = client.executeQueryWithJson(json);
+    if (response == null) {
+      outputFormatter.printErrorMessage(sout, "response is null");
+    } else if (response.getResultCode() == ClientProtos.ResultCode.OK) {
+      if (response.getIsForwarded()) {
+        QueryId queryId = new QueryId(response.getQueryId());
+        waitForQueryCompleted(queryId);
+      } else {
+        if (!response.hasTableDesc() && !response.hasResultSet()) {
+          outputFormatter.printMessage(sout, "OK");
+        } else {
+          localQueryCompleted(response, startTime);
+        }
+      }
+    } else {
+      if (response.hasErrorMessage()) {
+        outputFormatter.printErrorMessage(sout, response.getErrorMessage());
+      }
+    }
+  }
+
   private void executeQuery(String statement) throws ServiceException {
     long startTime = System.currentTimeMillis();
     ClientProtos.SubmitQueryResponse response = client.executeQuery(statement);

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-client/src/main/java/org/apache/tajo/client/TajoClient.java
----------------------------------------------------------------------
diff --git a/tajo-client/src/main/java/org/apache/tajo/client/TajoClient.java b/tajo-client/src/main/java/org/apache/tajo/client/TajoClient.java
index d981917..9e45bf0 100644
--- a/tajo-client/src/main/java/org/apache/tajo/client/TajoClient.java
+++ b/tajo-client/src/main/java/org/apache/tajo/client/TajoClient.java
@@ -311,6 +311,23 @@ public class TajoClient implements Closeable {
         final QueryRequest.Builder builder = QueryRequest.newBuilder();
         builder.setSessionId(sessionId);
         builder.setQuery(sql);
+        builder.setIsJson(false);
+        TajoMasterClientProtocolService.BlockingInterface tajoMasterService = client.getStub();
+        return tajoMasterService.submitQuery(null, builder.build());
+      }
+    }.withRetries();
+  }
+
+  public SubmitQueryResponse executeQueryWithJson(final String json) throws ServiceException {
+    return new ServerCallable<SubmitQueryResponse>(connPool, tajoMasterAddr,
+        TajoMasterClientProtocol.class, false, true) {
+      public SubmitQueryResponse call(NettyClientBase client) throws ServiceException {
+        checkSessionAndGet(client);
+
+        final QueryRequest.Builder builder = QueryRequest.newBuilder();
+        builder.setSessionId(sessionId);
+        builder.setQuery(json);
+        builder.setIsJson(true);
         TajoMasterClientProtocolService.BlockingInterface tajoMasterService = client.getStub();
         return tajoMasterService.submitQuery(null, builder.build());
       }
@@ -327,18 +344,26 @@ public class TajoClient implements Closeable {
    */
   public ResultSet executeQueryAndGetResult(final String sql)
       throws ServiceException, IOException {
-    SubmitQueryResponse response = new ServerCallable<SubmitQueryResponse>(connPool, tajoMasterAddr,
-        TajoMasterClientProtocol.class, false, true) {
-      public SubmitQueryResponse call(NettyClientBase client) throws ServiceException {
-        checkSessionAndGet(client);
+    SubmitQueryResponse response = executeQuery(sql);
 
-        final QueryRequest.Builder builder = QueryRequest.newBuilder();
-        builder.setSessionId(sessionId);
-        builder.setQuery(sql);
-        TajoMasterClientProtocolService.BlockingInterface tajoMasterService = client.getStub();
-        return tajoMasterService.submitQuery(null, builder.build());
+    QueryId queryId = new QueryId(response.getQueryId());
+    if (response.getIsForwarded()) {
+      if (queryId.equals(QueryIdFactory.NULL_QUERY_ID)) {
+        return this.createNullResultSet(queryId);
+      } else {
+        return this.getQueryResultAndWait(queryId);
       }
-    }.withRetries();
+    } else {
+      if (response.hasResultSet() || response.hasTableDesc()) {
+        return createResultSet(this, response);
+      } else {
+        return this.createNullResultSet(queryId);
+      }
+    }
+  }
+
+  public ResultSet executeJsonQueryAndGetResult(final String json) throws ServiceException, IOException {
+    SubmitQueryResponse response = executeQueryWithJson(json);
 
     QueryId queryId = new QueryId(response.getQueryId());
     if (response.getIsForwarded()) {
@@ -536,6 +561,31 @@ public class TajoClient implements Closeable {
         QueryRequest.Builder builder = QueryRequest.newBuilder();
         builder.setSessionId(sessionId);
         builder.setQuery(sql);
+        builder.setIsJson(false);
+        TajoMasterClientProtocolService.BlockingInterface tajoMasterService = client.getStub();
+        UpdateQueryResponse response = tajoMasterService.updateQuery(null, builder.build());
+        if (response.getResultCode() == ResultCode.OK) {
+          return true;
+        } else {
+          if (response.hasErrorMessage()) {
+            System.err.println("ERROR: " + response.getErrorMessage());
+          }
+          return false;
+        }
+      }
+    }.withRetries();
+  }
+
+  public boolean updateQueryWithJson(final String json) throws ServiceException {
+    return new ServerCallable<Boolean>(connPool, tajoMasterAddr,
+        TajoMasterClientProtocol.class, false, true) {
+      public Boolean call(NettyClientBase client) throws ServiceException {
+        checkSessionAndGet(client);
+
+        QueryRequest.Builder builder = QueryRequest.newBuilder();
+        builder.setSessionId(sessionId);
+        builder.setQuery(json);
+        builder.setIsJson(true);
         TajoMasterClientProtocolService.BlockingInterface tajoMasterService = client.getStub();
         UpdateQueryResponse response = tajoMasterService.updateQuery(null, builder.build());
         if (response.getResultCode() == ResultCode.OK) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-client/src/main/proto/ClientProtos.proto
----------------------------------------------------------------------
diff --git a/tajo-client/src/main/proto/ClientProtos.proto b/tajo-client/src/main/proto/ClientProtos.proto
index bdc271e..c66b228 100644
--- a/tajo-client/src/main/proto/ClientProtos.proto
+++ b/tajo-client/src/main/proto/ClientProtos.proto
@@ -67,6 +67,7 @@ message QueryRequest {
   optional SessionIdProto sessionId = 1;
   required string query = 2;
   repeated KeyValueProto setVariables = 3;
+  required bool isJson = 4;
 }
 
 message UpdateQueryResponse {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-core/src/main/java/org/apache/tajo/master/GlobalEngine.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/GlobalEngine.java b/tajo-core/src/main/java/org/apache/tajo/master/GlobalEngine.java
index 4155609..6caf031 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/GlobalEngine.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/GlobalEngine.java
@@ -30,6 +30,7 @@ import org.apache.tajo.QueryId;
 import org.apache.tajo.QueryIdFactory;
 import org.apache.tajo.algebra.AlterTablespaceSetType;
 import org.apache.tajo.algebra.Expr;
+import org.apache.tajo.algebra.JsonHelper;
 import org.apache.tajo.annotation.Nullable;
 import org.apache.tajo.catalog.*;
 import org.apache.tajo.catalog.exception.*;
@@ -109,16 +110,18 @@ public class GlobalEngine extends AbstractService {
     super.stop();
   }
 
-  public SubmitQueryResponse executeQuery(Session session, String sql)
-      throws InterruptedException, IOException, IllegalQueryStatusException {
-
-    LOG.info("SQL: " + sql);
+  public SubmitQueryResponse executeQuery(Session session, String query, boolean isJson) {
+    LOG.info("Query: " + query);
     QueryContext queryContext = new QueryContext();
+    Expr planningContext;
 
     try {
-      // setting environment variables
-      String [] cmds = sql.split(" ");
-      if(cmds != null) {
+      if (isJson) {
+        planningContext = buildExpressionFromJson(query);
+      } else {
+        // setting environment variables
+        String [] cmds = query.split(" ");
+        if(cmds != null) {
           if(cmds[0].equalsIgnoreCase("set")) {
             String[] params = cmds[1].split("=");
             context.getConf().set(params[0], params[1]);
@@ -128,21 +131,14 @@ public class GlobalEngine extends AbstractService {
             responseBuilder.setResultCode(ClientProtos.ResultCode.OK);
             return responseBuilder.build();
           }
-      }
-
-      final boolean hiveQueryMode = context.getConf().getBoolVar(TajoConf.ConfVars.HIVE_QUERY_MODE);
-      LOG.info("hive.query.mode:" + hiveQueryMode);
+        }
 
-      if (hiveQueryMode) {
-        context.getSystemMetrics().counter("Query", "numHiveMode").inc();
-        queryContext.setHiveQueryMode();
+        planningContext = buildExpressionFromSql(queryContext, query);
       }
 
-      context.getSystemMetrics().counter("Query", "totalQuery").inc();
-
-      Expr planningContext = hiveQueryMode ? converter.parse(sql) : analyzer.parse(sql);
+      String jsonExpr = planningContext.toJson();
       LogicalPlan plan = createLogicalPlan(session, planningContext);
-      SubmitQueryResponse response = executeQueryInternal(queryContext, session, plan, sql);
+      SubmitQueryResponse response = executeQueryInternal(queryContext, session, plan, query, jsonExpr);
       return response;
     } catch (Throwable t) {
       context.getSystemMetrics().counter("Query", "errorQuery").inc();
@@ -162,10 +158,30 @@ public class GlobalEngine extends AbstractService {
     }
   }
 
+  public Expr buildExpressionFromJson(String json) {
+    return JsonHelper.fromJson(json, Expr.class);
+  }
+
+  public Expr buildExpressionFromSql(QueryContext queryContext, String sql)
+      throws InterruptedException, IOException, IllegalQueryStatusException {
+    final boolean hiveQueryMode = context.getConf().getBoolVar(TajoConf.ConfVars.HIVE_QUERY_MODE);
+    LOG.info("hive.query.mode:" + hiveQueryMode);
+
+    if (hiveQueryMode) {
+      context.getSystemMetrics().counter("Query", "numHiveMode").inc();
+      queryContext.setHiveQueryMode();
+    }
+
+    context.getSystemMetrics().counter("Query", "totalQuery").inc();
+
+    return hiveQueryMode ? converter.parse(sql) : analyzer.parse(sql);
+  }
+
   private SubmitQueryResponse executeQueryInternal(QueryContext queryContext,
                                                       Session session,
                                                       LogicalPlan plan,
-                                                      String sql) throws Exception {
+                                                      String sql,
+                                                      String jsonExpr) throws Exception {
 
     LogicalRootNode rootNode = plan.getRootBlock().getRoot();
 
@@ -252,7 +268,7 @@ public class GlobalEngine extends AbstractService {
       QueryJobManager queryJobManager = this.context.getQueryJobManager();
       QueryInfo queryInfo;
 
-      queryInfo = queryJobManager.createNewQueryJob(session, queryContext, sql, rootNode);
+      queryInfo = queryJobManager.createNewQueryJob(session, queryContext, sql, jsonExpr, rootNode);
 
       if(queryInfo == null) {
         responseBuilder.setQueryId(QueryIdFactory.NULL_QUERY_ID.getProto());
@@ -273,11 +289,17 @@ public class GlobalEngine extends AbstractService {
     return response;
   }
 
-  public QueryId updateQuery(Session session, String sql) throws IOException, SQLException, PlanningException {
+  public QueryId updateQuery(Session session, String sql, boolean isJson) throws IOException, SQLException, PlanningException {
     try {
       LOG.info("SQL: " + sql);
-      // parse the query
-      Expr expr = analyzer.parse(sql);
+
+      Expr expr;
+      if (isJson) {
+        expr = JsonHelper.fromJson(sql, Expr.class);
+      } else {
+        // parse the query
+        expr = analyzer.parse(sql);
+      }
 
       LogicalPlan plan = createLogicalPlan(session, expr);
       LogicalRootNode rootNode = plan.getRootBlock().getRoot();

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-core/src/main/java/org/apache/tajo/master/TajoMasterClientService.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/TajoMasterClientService.java b/tajo-core/src/main/java/org/apache/tajo/master/TajoMasterClientService.java
index 8c16879..f6ad085 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/TajoMasterClientService.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/TajoMasterClientService.java
@@ -252,15 +252,13 @@ public class TajoMasterClientService extends AbstractService {
 
     @Override
     public SubmitQueryResponse submitQuery(RpcController controller, QueryRequest request) throws ServiceException {
-
-
       try {
         Session session = context.getSessionManager().getSession(request.getSessionId().getId());
 
         if(LOG.isDebugEnabled()) {
           LOG.debug("Query [" + request.getQuery() + "] is submitted");
         }
-        return context.getGlobalEngine().executeQuery(session, request.getQuery());
+        return context.getGlobalEngine().executeQuery(session, request.getQuery(), request.getIsJson());
       } catch (Exception e) {
         LOG.error(e.getMessage(), e);
         SubmitQueryResponse.Builder responseBuilder = ClientProtos.SubmitQueryResponse.newBuilder();
@@ -282,7 +280,7 @@ public class TajoMasterClientService extends AbstractService {
         Session session = context.getSessionManager().getSession(request.getSessionId().getId());
         UpdateQueryResponse.Builder builder = UpdateQueryResponse.newBuilder();
         try {
-          context.getGlobalEngine().updateQuery(session, request.getQuery());
+          context.getGlobalEngine().updateQuery(session, request.getQuery(), request.getIsJson());
           builder.setResultCode(ResultCode.OK);
           return builder.build();
         } catch (Exception e) {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-core/src/main/java/org/apache/tajo/master/event/QueryStartEvent.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/event/QueryStartEvent.java b/tajo-core/src/main/java/org/apache/tajo/master/event/QueryStartEvent.java
index dd996e6..623576a 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/event/QueryStartEvent.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/event/QueryStartEvent.java
@@ -34,16 +34,16 @@ public class QueryStartEvent extends AbstractEvent {
   private final QueryId queryId;
   private final Session session;
   private final QueryContext queryContext;
-  private final String sql;
+  private final String jsonExpr;
   private final String logicalPlanJson;
 
-  public QueryStartEvent(QueryId queryId, Session session, QueryContext queryContext, String sql,
+  public QueryStartEvent(QueryId queryId, Session session, QueryContext queryContext, String jsonExpr,
                          String logicalPlanJson) {
     super(EventType.QUERY_START);
     this.queryId = queryId;
     this.session = session;
     this.queryContext = queryContext;
-    this.sql = sql;
+    this.jsonExpr = jsonExpr;
     this.logicalPlanJson = logicalPlanJson;
   }
 
@@ -59,8 +59,8 @@ public class QueryStartEvent extends AbstractEvent {
     return this.queryContext;
   }
 
-  public String getSql() {
-    return this.sql;
+  public String getJsonExpr() {
+    return this.jsonExpr;
   }
 
   public String getLogicalPlanJson() {

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInProgress.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInProgress.java b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInProgress.java
index de323cd..dac2d4c 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInProgress.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInProgress.java
@@ -34,6 +34,7 @@ import org.apache.tajo.engine.query.QueryContext;
 import org.apache.tajo.ipc.QueryMasterProtocol;
 import org.apache.tajo.ipc.QueryMasterProtocol.QueryMasterProtocolService;
 import org.apache.tajo.ipc.TajoWorkerProtocol;
+import org.apache.tajo.ipc.TajoWorkerProtocol.QueryExecutionRequestProto;
 import org.apache.tajo.master.TajoAsyncDispatcher;
 import org.apache.tajo.master.TajoMaster;
 import org.apache.tajo.master.rm.WorkerResourceManager;
@@ -79,7 +80,7 @@ public class QueryInProgress extends CompositeService {
       TajoMaster.MasterContext masterContext,
       Session session,
       QueryContext queryContext,
-      QueryId queryId, String sql, LogicalRootNode plan) {
+      QueryId queryId, String sql, String jsonExpr, LogicalRootNode plan) {
     super(QueryInProgress.class.getName());
     this.masterContext = masterContext;
     this.session = session;
@@ -87,7 +88,7 @@ public class QueryInProgress extends CompositeService {
     this.queryId = queryId;
     this.plan = plan;
 
-    queryInfo = new QueryInfo(queryId, sql);
+    queryInfo = new QueryInfo(queryId, sql, jsonExpr);
     queryInfo.setStartTime(System.currentTimeMillis());
   }
 
@@ -230,15 +231,15 @@ public class QueryInProgress extends CompositeService {
       }
       LOG.info("Call executeQuery to :" +
           queryInfo.getQueryMasterHost() + ":" + queryInfo.getQueryMasterPort() + "," + queryId);
-      queryMasterRpcClient.executeQuery(
-          null,
-          TajoWorkerProtocol.QueryExecutionRequestProto.newBuilder()
-              .setQueryId(queryId.getProto())
-              .setSession(session.getProto())
-              .setQueryContext(queryContext.getProto())
-              .setSql(PrimitiveProtos.StringProto.newBuilder().setValue(queryInfo.getSql()))
-              .setLogicalPlanJson(PrimitiveProtos.StringProto.newBuilder().setValue(plan.toJson()).build())
-              .build(), NullCallback.get());
+
+      QueryExecutionRequestProto.Builder builder = TajoWorkerProtocol.QueryExecutionRequestProto.newBuilder();
+      builder.setQueryId(queryId.getProto())
+          .setSession(session.getProto())
+          .setQueryContext(queryContext.getProto())
+          .setExprInJson(PrimitiveProtos.StringProto.newBuilder().setValue(queryInfo.getJsonExpr()))
+          .setLogicalPlanJson(PrimitiveProtos.StringProto.newBuilder().setValue(plan.toJson()).build());
+
+      queryMasterRpcClient.executeQuery(null, builder.build(), NullCallback.get());
       querySubmitted.set(true);
     } catch (Exception e) {
       LOG.error(e.getMessage(), e);

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInfo.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInfo.java b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInfo.java
index 9e455ae..955c5b3 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInfo.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryInfo.java
@@ -25,6 +25,7 @@ import org.apache.tajo.TajoProtos;
 public class QueryInfo {
   private QueryId queryId;
   private String sql;
+  private String jsonExpr;
   private TajoProtos.QueryState queryState;
   private float progress;
   private long startTime;
@@ -35,12 +36,13 @@ public class QueryInfo {
   private int queryMasterClientPort;
 
   public QueryInfo(QueryId queryId) {
-    this(queryId, null);
+    this(queryId, null, null);
   }
 
-  public QueryInfo(QueryId queryId, String sql) {
+  public QueryInfo(QueryId queryId, String sql, String jsonExpr) {
     this.queryId = queryId;
     this.sql = sql;
+    this.jsonExpr = jsonExpr;
     this.queryState = TajoProtos.QueryState.QUERY_MASTER_INIT;
   }
 
@@ -122,4 +124,8 @@ public class QueryInfo {
     return queryId.toString() + ",state=" + queryState +",progress=" + progress + ", queryMaster="
         + getQueryMasterHost();
   }
+
+  public String getJsonExpr() {
+    return jsonExpr;
+  }
 }

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryJobManager.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryJobManager.java b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryJobManager.java
index ca45534..bc5fcad 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryJobManager.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryJobManager.java
@@ -95,10 +95,12 @@ public class QueryJobManager extends CompositeService {
     return Collections.unmodifiableCollection(finishedQueries.values());
   }
 
-  public QueryInfo createNewQueryJob(Session session, QueryContext queryContext, String sql, LogicalRootNode plan)
+  public QueryInfo createNewQueryJob(Session session, QueryContext queryContext, String sql,
+                                     String jsonExpr, LogicalRootNode plan)
       throws Exception {
     QueryId queryId = QueryIdFactory.newQueryId(masterContext.getResourceManager().getSeedQueryId());
-    QueryInProgress queryInProgress = new QueryInProgress(masterContext, session, queryContext, queryId, sql, plan);
+    QueryInProgress queryInProgress = new QueryInProgress(masterContext, session, queryContext, queryId, sql,
+        jsonExpr, plan);
 
     synchronized(runningQueries) {
       runningQueries.put(queryId, queryInProgress);

http://git-wip-us.apache.org/repos/asf/tajo/blob/9bbf87e3/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryMaster.java
----------------------------------------------------------------------
diff --git a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryMaster.java b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryMaster.java
index 523f5ba..a8c6014 100644
--- a/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryMaster.java
+++ b/tajo-core/src/main/java/org/apache/tajo/master/querymaster/QueryMaster.java
@@ -374,7 +374,7 @@ public class QueryMaster extends CompositeService implements EventHandler {
     public void handle(QueryStartEvent event) {
       LOG.info("Start QueryStartEventHandler:" + event.getQueryId());
       QueryMasterTask queryMasterTask = new QueryMasterTask(queryMasterContext,
-          event.getQueryId(), event.getSession(), event.getQueryContext(), event.getSql(), event.getLogicalPlanJson());
+          event.getQueryId(), event.getSession(), event.getQueryContext(), event.getJsonExpr(), event.getLogicalPlanJson());
 
       queryMasterTask.init(systemConf);
       if (!queryMasterTask.isInitError()) {


Mime
View raw message