quickstep-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jianq...@apache.org
Subject [4/6] incubator-quickstep git commit: Initial commit
Date Mon, 21 Nov 2016 05:18:05 GMT
Initial commit


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

Branch: refs/heads/viz
Commit: b060eb24cf0548d0744da4b47175108824117c67
Parents: 178ed4b
Author: Jianqiao Zhu <jianqiao@cs.wisc.edu>
Authored: Tue Nov 15 22:43:27 2016 -0600
Committer: Jianqiao Zhu <jianqiao@cs.wisc.edu>
Committed: Fri Nov 18 23:06:03 2016 -0600

----------------------------------------------------------------------
 CMakeLists.txt                       |     7 +-
 cli/QuickstepCli.cpp                 |    14 +-
 third_party/json/json.hpp            | 10794 ++++++++++++++++++++++++++++
 viz/CMakeLists.txt                   |    66 +
 viz/VizAnalyzer.cpp                  |    97 +
 viz/VizAnalyzer.hpp                  |   116 +
 viz/VizContext.cpp                   |    51 +
 viz/VizContext.hpp                   |   133 +
 viz/VizEngine.cpp                    |    74 +
 viz/VizEngine.hpp                    |    60 +
 viz/VizHelper.cpp                    |    76 +
 viz/VizHelper.hpp                    |    62 +
 viz/VizObject.cpp                    |    64 +
 viz/VizObject.hpp                    |   120 +
 viz/configs/BarChart.hpp             |    78 +
 viz/configs/CMakeLists.txt           |    48 +
 viz/configs/DumpRelation.hpp         |    79 +
 viz/configs/VizConfig.cpp            |    91 +
 viz/configs/VizConfig.hpp            |    68 +
 viz/rules/CMakeLists.txt             |    43 +
 viz/rules/Grouping.hpp               |   100 +
 viz/rules/OneDimensionOneMeasure.hpp |    73 +
 viz/rules/VizRule.hpp                |    68 +
 23 files changed, 12379 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/b060eb24/CMakeLists.txt
----------------------------------------------------------------------
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6191de0..bb069a2 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -725,6 +725,9 @@ if (ENABLE_DISTRIBUTED)
   include_directories(${CMAKE_CURRENT_BINARY_DIR}/third_party/tmb/include)
 endif()
 
+# Add third_party json (temporary).
+include_directories("${THIRD_PARTY_SOURCE_DIR}/json")
+
 # Add all of the module subdirectories. CMakeLists.txt in each of the subdirectories
 # defines how to build that module's libraries.
 add_subdirectory(catalog)
@@ -740,6 +743,7 @@ add_subdirectory(threading)
 add_subdirectory(transaction)
 add_subdirectory(types)
 add_subdirectory(utility)
+add_subdirectory(viz)
 add_subdirectory(yarn)
 
 # Build the quickstep_cli_shell executable.
@@ -775,7 +779,8 @@ target_link_libraries(quickstep_cli_shell
                       quickstep_utility_Macros
                       quickstep_utility_PtrVector
                       quickstep_utility_SqlError
-                      quickstep_utility_StringUtil)
+                      quickstep_utility_StringUtil
+                      quickstep_viz_VizHelper)
 if (ENABLE_HDFS)
   target_link_libraries(quickstep_cli_shell
                         quickstep_storage_FileManagerHdfs)

http://git-wip-us.apache.org/repos/asf/incubator-quickstep/blob/b060eb24/cli/QuickstepCli.cpp
----------------------------------------------------------------------
diff --git a/cli/QuickstepCli.cpp b/cli/QuickstepCli.cpp
index 31215f6..a506cd6 100644
--- a/cli/QuickstepCli.cpp
+++ b/cli/QuickstepCli.cpp
@@ -82,6 +82,7 @@ typedef quickstep::LineReaderDumb LineReaderImpl;
 #include "utility/PtrVector.hpp"
 #include "utility/SqlError.hpp"
 #include "utility/StringUtil.hpp"
+#include "viz/VizHelper.hpp"
 
 #include "gflags/gflags.h"
 
@@ -361,7 +362,7 @@ int main(int argc, char* argv[]) {
       &storage_manager,
       -1,  // Don't pin the Foreman thread.
       num_numa_nodes_system,
-      quickstep::FLAGS_profile_and_report_workorder_perf || quickstep::FLAGS_visualize_execution_dag);
+      true /* profile_individual_workorders */);
 
   // Start the worker threads.
   for (Worker &worker : workers) {
@@ -456,7 +457,16 @@ int main(int argc, char* argv[]) {
               main_thread_client_id, &bus);
           end = std::chrono::steady_clock::now();
 
-          const CatalogRelation *query_result_relation = query_handle->getQueryResultRelation();
+          const CatalogRelation *query_result_relation =
+              query_handle->getQueryResultRelation();
+
+          quickstep::viz::VizHelper::Visualize(statement,
+                                               query_handle->getQueryPlanMutable(),
+                                               &foreman.getWorkOrderProfilingResults(query_handle->query_id()),
+                                               query_result_relation,
+                                               query_processor->getDefaultDatabase(),
+                                               query_processor->getStorageManager());
+
           if (query_result_relation) {
             PrintToScreen::PrintRelation(*query_result_relation,
                                          &storage_manager,


Mime
View raw message