From 88cc4e26edc158b95f5aa2d54d59e3ffff1a2fc0 Mon Sep 17 00:00:00 2001
From: Jan Tattermusch <jtattermusch@google.com>
Date: Thu, 14 Apr 2016 16:58:50 -0700
Subject: [PATCH] minor changes to schema

---
 tools/run_tests/performance/export_utils.py   |   1 +
 .../performance/scenario_result_schema.json   | 103 +++++++++++++++++-
 2 files changed, 102 insertions(+), 2 deletions(-)

diff --git a/tools/run_tests/performance/export_utils.py b/tools/run_tests/performance/export_utils.py
index bdb36a5e82..6df64cca1f 100644
--- a/tools/run_tests/performance/export_utils.py
+++ b/tools/run_tests/performance/export_utils.py
@@ -86,3 +86,4 @@ def _flatten_result_inplace(scenario_result):
   scenario_result['latencies'] = json.dumps(scenario_result['latencies'])
   for stats in scenario_result['clientStats']:
     stats['latencies'] = json.dumps(stats['latencies'])
+  scenario_result['serverCores'] = json.dumps(scenario_result['serverCores'])
diff --git a/tools/run_tests/performance/scenario_result_schema.json b/tools/run_tests/performance/scenario_result_schema.json
index 39aba21b0c..10d24a2517 100644
--- a/tools/run_tests/performance/scenario_result_schema.json
+++ b/tools/run_tests/performance/scenario_result_schema.json
@@ -1,4 +1,41 @@
 [
+  {
+    "name": "metadata",
+    "type": "RECORD",
+    "mode": "NULLABLE",
+    "fields": [
+      {
+        "name": "buildNumber",
+        "type": "INTEGER",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "buildUrl",
+        "type": "STRING",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "jobName",
+        "type": "STRING",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "gitCommit",
+        "type": "STRING",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "gitActualCommit",
+        "type": "STRING",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "created",
+        "type": "TIMESTAMP",
+        "mode": "NULLABLE"
+      }
+    ]
+  },
   {
     "name": "scenario",
     "type": "RECORD",
@@ -97,7 +134,69 @@
   },
   {
     "name": "serverCores",
-    "type": "INTEGER",
-    "mode": "REPEATED"
+    "type": "STRING",
+    "mode": "NULLABLE"
+  },
+  {
+    "name": "summary",
+    "type": "RECORD",
+    "mode": "NULLABLE",
+    "fields": [
+      {
+        "name": "qps",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "qps_per_server_core",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "server_system_time",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "server_user_time",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "client_system_time",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "client_user_time",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "latency_50",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "latency_90",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "latency_95",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "latency_99",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      },
+      {
+        "name": "latency_999",
+        "type": "FLOAT",
+        "mode": "NULLABLE"
+      }
+    ]
   }
 ]
-- 
GitLab