flink-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From se...@apache.org
Subject [12/14] flink git commit: [FLINK-3131] [runtime-web] Add checkpoint statistics to web frontend
Date Thu, 31 Dec 2015 14:33:35 GMT
http://git-wip-us.apache.org/repos/asf/flink/blob/73e8586c/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.html
----------------------------------------------------------------------
diff --git a/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.html b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.html
index f2c4143..cc60c9e 100644
--- a/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.html
+++ b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.html
@@ -25,6 +25,7 @@ limitations under the License.
     <ul class="nav nav-tabs">
       <li ui-sref-active="active"><a ui-sref=".overview({nodeid: nodeid})">Overview</a></li>
       <li ui-sref-active="active"><a ui-sref=".accumulators({nodeid: nodeid})">Accumulators</a></li>
+      <li ui-sref-active="active"><a ui-sref=".checkpoints({nodeid: nodeid})">Checkpoints</a></li>
     </ul>
   </nav>
   <div ui-view="node-details" class="panel-body clean"></div>

http://git-wip-us.apache.org/repos/asf/flink/blob/73e8586c/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node-list.checkpoints.html
----------------------------------------------------------------------
diff --git a/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node-list.checkpoints.html
b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node-list.checkpoints.html
new file mode 100644
index 0000000..dd4a40d
--- /dev/null
+++ b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node-list.checkpoints.html
@@ -0,0 +1,48 @@
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+-->
+<div ng-if="!operatorCheckpointStats">
+  <p><em>No checkpoints</em></p>
+</div>
+<div ng-if="operatorCheckpointStats">
+  <h2>Overview</h2>
+  <div ng-include=" 'partials/jobs/job.plan.node.checkpoints.job.html' "></div>
+  <h2>Operators</h2>
+  <table class="table table-body-hover table-clickable table-activable">
+    <thead>
+      <tr>
+        <th>Name</th>
+        <th>Status</th>
+      </tr>
+    </thead>
+    <tbody ng-repeat="v in job.vertices" ng-class="{ active: v.id == nodeid }" ng-click="v.id
== nodeid || changeNode(v.id)">
+      <tr ng-if="v.type == 'regular'">
+        <td>{{ v.name | humanizeText }}</td>
+        <td>
+          <bs-label status="{{v.status}}">{{v.status}}</bs-label>
+        </td>
+      </tr>
+      <tr ng-if="nodeid &amp;&amp; v.id == nodeid">
+        <td colspan="10">
+          <div ng-include=" 'partials/jobs/job.plan.node.checkpoints.operator.html' "></div>
+        </td>
+      </tr>
+    </tbody>
+  </table>
+</div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flink/blob/73e8586c/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.job.html
----------------------------------------------------------------------
diff --git a/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.job.html
b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.job.html
new file mode 100644
index 0000000..83f3ece
--- /dev/null
+++ b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.job.html
@@ -0,0 +1,80 @@
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+-->
+<div ng-if="!jobCheckpointStats">
+  <p><em>No checkpoints</em></p>
+</div>
+<table ng-if="jobCheckpointStats" class="table table-hover table-inner">
+  <thead>
+    <tr>
+      <td colspan="3"><strong>Overview</strong></td>
+    </tr>
+  </thead>
+  <tbody>
+    <tr>
+      <td><strong>Count</strong></td>
+      <td colspan="3"><span>{{ jobCheckpointStats['count'] }}</span></td>
+    </tr>
+    <tr>
+      <td><strong>Duration</strong></td>
+      <td>
+        <p><strong>Minimum:</strong><span> {{ jobCheckpointStats['duration']['min']
| humanizeDuration }}</span></p>
+      </td>
+      <td>
+        <p><strong>Maximum:</strong><span> {{ jobCheckpointStats['duration']['max']
| humanizeDuration }}</span></p>
+      </td>
+      <td>
+        <p><strong>Average:</strong><span> {{ jobCheckpointStats['duration']['avg']
| humanizeDuration }}</span></p>
+      </td>
+    </tr>
+    <tr>
+      <td><strong>State Size</strong></td>
+      <td>
+        <p><strong>Minimum:</strong><span> {{ jobCheckpointStats['size']['min']
| humanizeBytes }}</span></p>
+      </td>
+      <td>
+        <p><strong>Maximum:</strong><span> {{ jobCheckpointStats['size']['max']
| humanizeBytes }}</span></p>
+      </td>
+      <td>
+        <p><strong>Average:</strong><span> {{ jobCheckpointStats['size']['avg']
| humanizeBytes }}</span></p>
+      </td>
+    </tr>
+  </tbody>
+</table>
+<div ng-if="!showHistory &amp;&amp; jobCheckpointStats &amp;&amp; jobCheckpointStats['history'].length
&gt; 0"><a ng-click="toggleHistory()" class="btn btn-default"><strong>Show
history</strong> ({{ jobCheckpointStats['history'].length }}) <i class="fa fa-chevron-down"></i></a></div>
+<div ng-if="showHistory &amp;&amp; jobCheckpointStats &amp;&amp; jobCheckpointStats['history'].length
&gt; 0"><a ng-click="toggleHistory()" class="btn btn-default">Hide history ({{
jobCheckpointStats['history'].length }}) <i class="fa fa-chevron-up"></i></a>
+  <table class="table table-hover table-inner">
+    <thead>
+      <tr>
+        <td><strong>ID</strong></td>
+        <td><strong>Trigger Time</strong></td>
+        <td><strong>Duration</strong></td>
+        <td><strong>State Size</strong></td>
+      </tr>
+    </thead>
+    <tbody ng-if="jobCheckpointStats['history'] &amp;&amp; jobCheckpointStats['history'].length
&gt; 0" ng-repeat="historic in jobCheckpointStats['history']">
+      <tr>
+        <td>{{ historic['id'] }}</td>
+        <td>{{ historic['timestamp'] | amDateFormat:'H:mm:ss' }}</td>
+        <td>{{ historic['duration'] | humanizeDuration }}</td>
+        <td>{{ historic['size'] | humanizeBytes }}</td>
+      </tr>
+    </tbody>
+  </table>
+</div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flink/blob/73e8586c/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.operator.html
----------------------------------------------------------------------
diff --git a/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.operator.html
b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.operator.html
new file mode 100644
index 0000000..d390fb4
--- /dev/null
+++ b/flink-runtime-web/web-dashboard/web/partials/jobs/job.plan.node.checkpoints.operator.html
@@ -0,0 +1,61 @@
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+-->
+<div ng-if="!operatorCheckpointStats">
+  <p><em>No checkpoints</em></p>
+</div>
+<div ng-if="operatorCheckpointStats">
+  <table class="table table-hover table-clickable table-activable table-inner">
+    <thead>
+      <tr>
+        <th>ID</th>
+        <th>Trigger Timestamp</th>
+        <th>Duration</th>
+        <th>State Size</th>
+      </tr>
+    </thead>
+    <tbody>
+      <tr>
+        <td width="22%">{{ operatorCheckpointStats['id'] }}</td>
+        <td width="22%">{{ operatorCheckpointStats['timestamp'] | amDateFormat:'H:mm:ss'
}}</td>
+        <td width="22%">{{ operatorCheckpointStats['duration'] | humanizeDuration }}</td>
+        <td width="22%">{{ operatorCheckpointStats['size'] | humanizeBytes }}</td>
+      </tr>
+    </tbody>
+  </table>
+  <div ng-if="!nodeUnfolded &amp;&amp; subtasksCheckpointStats &amp;&amp;
subtasksCheckpointStats.length &gt; 0"><a ng-click="toggleFold()" class="btn btn-default">Show
subtasks <i class="fa fa-chevron-down"></i></a><a ng-click="deactivateNode();
$event.stopPropagation()" title="Fold" class="btn btn-default pull-right"><i class="fa
fa-chevron-up"></i></a></div>
+  <div ng-if="nodeUnfolded &amp;&amp; subtasksCheckpointStats &amp;&amp;
subtasksCheckpointStats.length &gt; 0"><a ng-click="toggleFold()" class="btn btn-default">Hide
subtasks <i class="fa fa-chevron-up"></i></a>
+    <table class="table table-hover table-clickable table-activable table-inner">
+      <thead>
+        <tr>
+          <th>Subtask</th>
+          <th>Duration</th>
+          <th>Type</th>
+        </tr>
+      </thead>
+      <tbody ng-repeat="subtask in subtasksCheckpointStats">
+        <tr>
+          <td>{{ subtask['subtask'] + 1 }}</td>
+          <td>{{ subtask['duration'] | humanizeDuration }}</td>
+          <td>{{ subtask['size'] | humanizeBytes }}</td>
+        </tr>
+      </tbody>
+    </table>
+  </div>
+</div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/flink/blob/73e8586c/flink-runtime/src/main/java/org/apache/flink/runtime/state/StateHandle.java
----------------------------------------------------------------------
diff --git a/flink-runtime/src/main/java/org/apache/flink/runtime/state/StateHandle.java b/flink-runtime/src/main/java/org/apache/flink/runtime/state/StateHandle.java
index b5d34b0..78bf3cf 100644
--- a/flink-runtime/src/main/java/org/apache/flink/runtime/state/StateHandle.java
+++ b/flink-runtime/src/main/java/org/apache/flink/runtime/state/StateHandle.java
@@ -50,7 +50,6 @@ public interface StateHandle<T> extends Serializable {
 	 * <p>If the the size is not known, return <code>0</code>.
 	 *
 	 * @return Size of the state in bytes.
-	 *
 	 * @throws Exception If the operation fails during size retrieval.
 	 */
 	long getStateSize() throws Exception;


Mime
View raw message