You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@quickstep.apache.org by hb...@apache.org on 2016/09/06 20:16:49 UTC

[72/73] [abbrv] incubator-quickstep git commit: Added new workorder to WorkOrderFactory classes.

Added new workorder to WorkOrderFactory classes.


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

Branch: refs/heads/partitioned-aggregation
Commit: ef665e4095f567d704d79bb855e00d36db241269
Parents: 2e8e1c3
Author: Harshad Deshmukh <hb...@apache.org>
Authored: Sun Aug 21 11:02:49 2016 -0500
Committer: Harshad Deshmukh <hb...@apache.org>
Committed: Tue Sep 6 15:01:34 2016 -0500

----------------------------------------------------------------------
 relational_operators/CMakeLists.txt       |  1 +
 relational_operators/WorkOrderFactory.cpp | 14 ++++++++++++++
 2 files changed, 15 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/ef665e40/relational_operators/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/relational_operators/CMakeLists.txt b/relational_operators/CMakeLists.txt
index 369deba..5064999 100644
--- a/relational_operators/CMakeLists.txt
+++ b/relational_operators/CMakeLists.txt
@@ -462,6 +462,7 @@ target_link_libraries(quickstep_relationaloperators_WorkOrderFactory
                       quickstep_relationaloperators_AggregationOperator
                       quickstep_relationaloperators_BuildHashOperator
                       quickstep_relationaloperators_DeleteOperator
+                      quickstep_relationaloperators_DestroyAggregationStateOperator
                       quickstep_relationaloperators_DestroyHashOperator
                       quickstep_relationaloperators_DropTableOperator
                       quickstep_relationaloperators_FinalizeAggregationOperator

http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/ef665e40/relational_operators/WorkOrderFactory.cpp
----------------------------------------------------------------------
diff --git a/relational_operators/WorkOrderFactory.cpp b/relational_operators/WorkOrderFactory.cpp
index 6970486..6b9ab42 100644
--- a/relational_operators/WorkOrderFactory.cpp
+++ b/relational_operators/WorkOrderFactory.cpp
@@ -30,6 +30,7 @@
 #include "relational_operators/AggregationOperator.hpp"
 #include "relational_operators/BuildHashOperator.hpp"
 #include "relational_operators/DeleteOperator.hpp"
+#include "relational_operators/DestroyAggregationStateOperator.hpp"
 #include "relational_operators/DestroyHashOperator.hpp"
 #include "relational_operators/DropTableOperator.hpp"
 #include "relational_operators/FinalizeAggregationOperator.hpp"
@@ -116,6 +117,14 @@ WorkOrder* WorkOrderFactory::ReconstructFromProto(const serialization::WorkOrder
           shiftboss_client_id,
           bus);
     }
+    case serialization::DESTROY_AGGREGATION_STATE: {
+      LOG(INFO) << "Creating DestroyAggregationStateWorkOrder";
+      return new DestroyAggregationStateWorkOrder(
+          proto.query_id(),
+          proto.GetExtension(
+              serialization::DestroyAggregationStateWorkOrder::aggr_state_index),
+          query_context);
+    }
     case serialization::DESTROY_HASH: {
       LOG(INFO) << "Creating DestroyHashWorkOrder";
       return new DestroyHashWorkOrder(
@@ -489,6 +498,11 @@ bool WorkOrderFactory::ProtoIsValid(const serialization::WorkOrder &proto,
              proto.HasExtension(serialization::DeleteWorkOrder::block_id) &&
              proto.HasExtension(serialization::DeleteWorkOrder::operator_index);
     }
+    case serialization::DESTROY_AGGREGATION_STATE: {
+      return proto.HasExtension(serialization::DestroyAggregationStateWorkOrder::aggr_state_index) &&
+             query_context.isValidAggregationStateId(
+                 proto.GetExtension(serialization::DestroyAggregationStateWorkOrder::aggr_state_index));
+    }
     case serialization::DESTROY_HASH: {
       return proto.HasExtension(serialization::DestroyHashWorkOrder::join_hash_table_index) &&
              query_context.isValidJoinHashTableId(