aurora-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wfar...@apache.org
Subject [02/51] [partial] Rename twitter* and com.twitter to apache and org.apache directories to preserve all file history before the refactor.
Date Tue, 31 Dec 2013 21:19:55 GMT
http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/com/twitter/aurora/scheduler/http/assets/util.js
----------------------------------------------------------------------
diff --git a/src/main/resources/com/twitter/aurora/scheduler/http/assets/util.js b/src/main/resources/com/twitter/aurora/scheduler/http/assets/util.js
deleted file mode 100644
index 5dd0d17..0000000
--- a/src/main/resources/com/twitter/aurora/scheduler/http/assets/util.js
+++ /dev/null
@@ -1,65 +0,0 @@
-/**
- * Given an epoch milliseconds timestamp, generate a string representation that includes
- * GMT and local time.
- */
-function printDate(timestamp) {
-  function pad(number) {
-    number = '' + number;
-    if (number.length < 2) {
-      return '0' + number;
-    }
-    return number;
-  }
-  var d = new Date(timestamp);
-  return pad(d.getUTCMonth() + 1) + "/"
-      + pad(d.getUTCDate()) + " "
-      + pad(d.getUTCHours()) + ":"
-      + pad(d.getUTCMinutes()) + ":"
-      + pad(d.getUTCSeconds())
-      + ' UTC ('
-      + pad(d.getMonth() + 1) + "/"
-      + pad(d.getDate()) + " "
-      + pad(d.getHours()) + ":"
-      + pad(d.getMinutes()) + ":"
-      + pad(d.getSeconds())
-      + ' local)';
-}
-
-/**
- * Given the current time and an epoch milliseconds timestamp, generate a human-readable
- * representation of how long has elapsed from timestamp to now.
- */
-function printElapsed(newerTimestamp, olderTimestamp) {
-  var elapsed = newerTimestamp - olderTimestamp;
-  if (elapsed <= 0) {
-    return "epsilon";
-  }
-  var SEC = 1000;
-  var MIN = 60 * SEC;
-  var HOUR = 60 * MIN;
-  var DAY = 24 * HOUR;
-  if (elapsed < 2 * SEC) {
-    return Math.floor(elapsed) + " msec";
-  }
-  if (elapsed < 2 * MIN) {
-    return Math.floor(elapsed / SEC) + " secs";
-  }
-  if (elapsed < 2 * HOUR) {
-    return Math.floor(elapsed / MIN) + " mins";
-  }
-  if (elapsed < 2 * DAY) {
-    return Math.floor(elapsed / HOUR) + " hours";
-  }
-  return Math.floor(elapsed / DAY) + " days";
-}
-
-function scaleMb(sizeInMb) {
-  var size = sizeInMb;
-  var SCALE = ["MiB", "GiB", "TiB", "PiB", "EiB"];
-  var unit = 0;
-  while(size >= 1024 && unit < SCALE.length) {
-      size = size / 1024;
-      unit++;
-  }
-  return size.toFixed(2).toString() + " " + SCALE[unit];
-}

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzhome.st
----------------------------------------------------------------------
diff --git a/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzhome.st b/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzhome.st
deleted file mode 100644
index 5e540f3..0000000
--- a/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzhome.st
+++ /dev/null
@@ -1,53 +0,0 @@
-<!DOCTYPE html>
-<html>
-  <head>
-    <meta charset="UTF-8">
-    <meta name="google" value="notranslate">
-    <link rel="icon" href="/images/aurora.png" type="image/png" />
-    <title>Aurora $cluster_name$ scheduler</title>
-    <link href="/css/bootstrap.min.css" rel="stylesheet" />
-    <link href="/css/jquery.dataTables.css" rel="stylesheet" />
-    <script type="text/javascript" src="/js/jquery.min.js"></script>
-    <script type="text/javascript" src="/js/bootstrap.min.js"></script>
-    <script type="text/javascript" src="/js/jquery.dataTables.min.js"></script>
-    <script type="text/javascript" src="/js/dataTables.bootstrap.js"></script>
-    <script type="text/javascript" src="/js/dataTables.localstorage.js"></script>
-  </head>
-  <body>
-    <div class="container-fluid">
-      <div class="row-fluid">
-        <center>
-          <h2>Scheduled Jobs</h2>
-        </center>
-      </div>
-      
-      <table id="jobs-table" class="table table-bordered table-striped table-condensed table-hover">
-        <thead>
-          <th>Role
-          <th>Jobs
-          <th>Cron Jobs
-        </thead>
-        <tbody>
-          $owners:{ owner |
-          <tr>
-            <td><a href="/scheduler/$owner.role$">$owner.role$</a>
-            <td>$owner.jobCount$
-            <td>$owner.cronJobCount$
-          </tr>
-          }$
-        </tbody>
-      </table>
-      $if(exception)$
-        <font color='red'>Exception: $exception$</font>
-      $endif$
-    </div>
-    
-    <script type="text/javascript">
-      jQuery(function(){
-        jQuery('#jobs-table').dataTable({
-          'bStateSave': true
-        });
-      });
-    </script>
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzjob.st
----------------------------------------------------------------------
diff --git a/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzjob.st b/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzjob.st
deleted file mode 100644
index 28b5667..0000000
--- a/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzjob.st
+++ /dev/null
@@ -1,315 +0,0 @@
-<!DOCTYPE html>
-<html>
-  <head>
-    <meta charset="UTF-8">
-    <meta name="google" value="notranslate">
-    <link rel="icon" href="/images/aurora.png" type="image/png" />
-    <title>Aurora $cluster_name$ scheduler - Tasks for $role$/$environment$/$job$</title>
-    <link href="/css/bootstrap.min.css" rel="stylesheet" />
-    <script type="text/javascript" src="/js/jquery.min.js"></script>
-    <script type="text/javascript" src="/js/bootstrap.min.js"></script>
-    <script type="text/javascript" src="/js/util.js"></script>
-    <script type="text/javascript" src="/js/dictionary.js"></script>
-    <style>
-      .expand-btn:hover{
-        text-decoration: none;
-      }
-      .task-status {
-        cursor: help;
-        border-bottom: 1px #aaaaaa dashed;
-      }
-    </style>
-  </head>
-  <body>
-    <div class="container-fluid">
-      <div class="row-fluid">
-        <div style="float:right; position:absolute; right:20px">
-          <a href="$statsUrl$"><img src="/images/viz.png" alt="Container stats on viz" /></a>
-        </div>
-        <center>
-          <h2>Job: $job$</h2>
-          <h5 style='margin-top: -12px;'>Role: $role$ - Environment: $environment$</h5>
-        </center>
-      </div>
-
-      <div class="row-fluid">
-        <ul class="breadcrumb">
-          <li>
-            <a href="/scheduler">Home</a> <span class="divider">></span>
-          </li>
-          <li>
-            <a href="/scheduler/$role$">Role: $role$</a> <span class="divider">></span>
-          </li>
-          <li>
-            <a href="/scheduler/$role$/$environment$">Environment: $environment$</a>
-            <span class="divider">></span>
-          </li>
-          <li class="active">Job: $job$</li>
-        </ul>
-      </div>
-
-      $if(admin)$
-        $if(is_cron)$
-          (<a href="/structdump/cron/$role$/$environment$/$job$">dump</a>)
-        $endif$
-      $endif$
-
-
-      $if(schedulingDetails)$
-        <div class="row-fluid" style="margin-bottom: 20px;">
-          <button id="scheduling-details-toggle-btn" class="btn">
-            <i class="icon-plus" style="margin-right: 3px;"></i>
-            <span class="btn-text">Show Details</span>
-          </button>
-          <div  id="scheduling-details" class="collapse" style="width: 400px; margin-top: 10px;">
-            <table class="table table-condensed" style="margin-bottom: 0px;">
-              <thead>
-                <th>Instances
-                <th>Details
-              </thead>
-              <tbody>
-                $schedulingDetails.keys:{ instances |
-                <tr>
-                  <td style='text-align:center; vertical-align:middle'>$instances$
-                  <td>
-                    <table class="table table-condensed" style="margin-bottom: 0px;">
-                      <tbody>
-                      $schedulingDetails.(instances).details.keys: { name |
-                        <tr>
-                          <td>$name$
-                          <td>$schedulingDetails.(instances).details.(name)$
-                        </tr>
-                      }$
-                      </tbody>
-                    </table>
-                </tr>
-                }$
-              </tbody>
-            </table>
-          </div>
-        </div>
-      $endif$
-
-      <script>
-        // The current Date, used in calls to printElapsed().
-        var nowTimestamp = new Date().getTime();
-      </script>
-
-      $if(activeTasks)$
-        <div style='clear:both'>
-          <h3>Active Tasks</h3>
-          <table class="table table-striped table-condensed table-hover">
-            <thead>
-              <th>Instance
-              <th>Status
-              $if(admin)$
-              <th>Task ID
-              $endif$
-              <th>Host
-            </thead>
-            <tbody>
-              $activeTasks:{ task |
-              <tr>
-                <td style='vertical-align:middle'>
-                  $task.instanceId$ $task.links.keys, task.links.values: { k, v | <a href='$v$'>$k$</a> }$
-                <td style='vertical-align:middle'>
-                  <a href='#accordion-$task.taskId$' class='expand-btn' title='Show details'>
-                    <i class='icon-plus'></i>
-                  </a>
-                  <script>
-                    document.write(printElapsed(nowTimestamp, $task.statusTimestamp$) + ' ago ');
-                  </script>
-                  - <span class='task-status' status='$task.status$'>$task.status$ </span>
-                  $if(task.pendingReason)$ ($task.pendingReason$)$endif$
-                  <div class='collapse' id='accordion-$task.taskId$' style='margin-bottom: 0px'>
-                    <ul>
-                      $task.taskEvents:{ event |
-                      <li>
-                        <script>document.write(printDate($event.timestamp$));</script>
-                        - <span class='task-status' status='$event.status$'>$event.status$</span>
-                        $if(event.message)$: $event.message$$endif$
-                      </li>
-                      }$
-                    </ul>
-                  </div>
-                $if(admin)$
-                <td><a href='/structdump/task/$task.taskId$'>$task.taskId$</a>
-                $endif$
-                <td style='vertical-align:middle'>
-                  $if(task.slaveHost)$ <a href='$task.executorUri$'>$task.slaveHost$</a> $endif$
-              </tr>
-              }$
-            </tbody>
-          </table>
-        </div>
-      $endif$
-
-      <br />
-      <br />
-
-      $if(completedTasks)$
-        <h3>Completed Tasks</h3>
-        <table class="table table-striped table-condensed table-hover">
-          <thead>
-            <th>Instance
-            <th>Status
-            <th>Running duration
-            $if(admin)$
-            <th>Task ID
-            $endif$
-            <th>Host
-          </thead>
-          <tbody>
-          $completedTasks:{ task |
-          <tr>
-            <td>$task.instanceId$
-            <td style='vertical-align:middle'>
-              <a href='#collapse-$task.taskId$' class='expand-btn' title='Show details'>
-                <i class='icon-plus'></i>
-              </a>
-              <script>
-                document.write(printElapsed(nowTimestamp, $task.statusTimestamp$) + ' ago ');
-              </script>
-              - <span class='task-status' status='$task.status$'>$task.status$</span>
-              $last(task.taskEvents):{ event |
-                $if(event.message)$
-                  : $event.message$
-                $endif$
-              }$
-
-              <div id='collapse-$task.taskId$' class='collapse'>
-                <ul>
-                  $task.taskEvents:{ event |
-                  <li>
-                    <script>document.write(printDate($event.timestamp$));</script>
-                    - <span class='task-status' status='$event.status$'>$event.status$</span>
-                    $if(event.message)$: $event.message$$endif$
-                  </li>
-                  }$
-                </ul>
-              </div>
-            <td>
-              <script>
-                var events = [
-                  $task.taskEvents:{ event | [ '$event.status$', $event.timestamp$ ], }$
-                ];
-                var aliveTimestamp = 0;
-                for (var i = events.length - 1; i >= 0; i--) {
-                  if (events[i][0] == 'RUNNING') {
-                    aliveTimestamp = events[i][1];
-                    break;
-                  }
-                }
-                if (aliveTimestamp != 0) {
-                  document.write(printElapsed(events[events.length - 1][1], aliveTimestamp));
-                }
-              </script>
-            $if(admin)$
-            <td><a href='/structdump/task/$task.taskId$'>$task.taskId$</a>
-            $endif$
-            <td>$if(task.slaveHost)$ <a href='$task.executorUri$'>$task.slaveHost$</a> $endif$
-          </tr>
-          }$
-          </tbody>
-        </table>
-      $endif$
-
-      $if(exception)$
-        <font color='red'>Exception: $exception$</font>
-      $endif$
-
-      <div class='pagination' style='text-align: center'>
-        <ul>
-          <li $if(!prevOffset)$ class='disabled' $endif$>
-          $if(prevOffset)$
-            <a href='/scheduler/$role$/$environment$/$job$?$if(status)$status=$status$$endif$&o=$prevOffset$'>&laquo;</a>
-          $else$
-            <span>&laquo;</span>
-          $endif$
-          </li>
-          <li $if(!nextOffset)$ class='disabled' $endif$>
-          $if(nextOffset)$
-            <a href='/scheduler/$role$/$environment$/$job$?$if(status)$status=$status$$endif$&o=$nextOffset$'>&raquo;</a>
-          $else$
-            <span>&raquo;</span>
-          $endif$
-          </li>
-        </ul>
-      </div>
-    </div>
-
-    <script type="text/javascript">
-      jQuery(function(){
-        // Enable tooltips on all expansion buttons
-        jQuery('.expand-btn').tooltip();
-
-        // Bind click event to all expand buttons
-        jQuery('.expand-btn').on('click', function(e){
-          e.stopPropagation();
-          e.preventDefault();
-
-          jQuery(jQuery(this).attr('href')).collapse('toggle');
-        });
-
-        // Switch between + and - icons based on button state
-        jQuery('div.collapse').on('show', function(){
-          var parent = jQuery(this).parent();
-          var icon = parent.find('i');
-          var button = parent.find('.expand-btn');
-
-          icon.addClass('icon-minus').removeClass('icon-plus');
-          button.attr('data-original-title', 'Hide details').tooltip('hide');
-        });
-
-        jQuery('div.collapse').on('hide', function(){
-          var parent = jQuery(this).parent();
-          var icon = parent.find('i');
-          var button = parent.find('.expand-btn');
-
-          icon.addClass('icon-plus').removeClass('icon-minus');
-          button.attr('data-original-title', 'View details');
-        });
-
-        // Attach tooltips to task states
-        jQuery('.task-status').each(function() {
-          jQuery(this).popover({
-            placement: 'right',
-            trigger: 'hover',
-            title: jQuery(this).attr('status'),
-            content: dictionary.states[jQuery(this).attr('status')]
-          });
-        });
-      });
-
-      // Bind click event to button
-      jQuery('#scheduling-details-toggle-btn').on('click', function(e){
-        e.stopPropagation();
-        e.preventDefault();
-        jQuery('#scheduling-details').collapse('toggle');
-      });
-
-      // Switch between + and - icons based on button state
-      jQuery('#scheduling-details').on('show', function(){
-        var parent = jQuery(this).parent();
-        var icon = parent.find('i');
-        var buttonText = parent.find('.btn-text');
-
-        icon.addClass('icon-minus').removeClass('icon-plus');
-        buttonText.html('Hide Details');
-      });
-
-      jQuery('#scheduling-details').on('hide', function(){
-        var parent = jQuery(this).parent();
-        var icon = parent.find('i');
-        var buttonText = parent.find('.btn-text');
-
-        icon.addClass('icon-plus').removeClass('icon-minus');
-        buttonText.html('Show Details');
-      });
-    </script>
-  </body>
-  <div style='bottom: 10px; right: 10px; position: fixed;'>
-    <a href='/scheduler/$role$/$environment$/$job$?admin$if(status)$&status=$status$$endif$&o=$offset$'>&pi;</a>
-  </div>
-</html>
-

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzrole.st
----------------------------------------------------------------------
diff --git a/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzrole.st b/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzrole.st
deleted file mode 100644
index d568a7e..0000000
--- a/src/main/resources/com/twitter/aurora/scheduler/http/schedulerzrole.st
+++ /dev/null
@@ -1,265 +0,0 @@
-<!DOCTYPE html>
-<html>
-  <head>
-    <meta charset="UTF-8">
-    <meta name="google" value="notranslate">
-    <link rel="icon" href="/images/aurora.png" type="image/png" />
-    <title>Aurora $cluster_name$ scheduler - Jobs for $role$</title>
-    <link href="/css/bootstrap.min.css" rel="stylesheet" />
-    <link href="/css/jquery.dataTables.css" rel="stylesheet" />
-    <script type="text/javascript" src="/js/jquery.min.js"></script>
-    <script type="text/javascript" src="/js/bootstrap.min.js"></script>
-    <script type="text/javascript" src="/js/util.js"></script>
-    <script type="text/javascript" src="/js/jquery.dataTables.min.js"></script>
-    <script type="text/javascript" src="/js/dataTables.bootstrap.js"></script>
-    <script type="text/javascript" src="/js/dataTables.localstorage.js"></script>
-    <script type="text/javascript" src="/js/dataTables.htmlNumberType.js"></script>
-  </head>
-  <body>
-    <div class="container-fluid">
-      <div class="row-fluid">
-        <center>
-          <h2>Jobs for role $role$ $if(environment)$ and environment $environment$ $endif$ </h2>
-        </center>
-      </div>
-
-      <div class="row-fluid">
-        <ul class="breadcrumb">
-          <li>
-            <a href="/scheduler">Home</a> <span class="divider">></span>
-          </li>
-          $if(environment)$
-           <li><a href="/scheduler/$role$">Role : $role$</a> <span class="divider">></span></li>
-           <li>Environment: $environment$</li>
-          $else$
-            <li class="active">Role: $role$</li>
-          $endif$
-        </ul>
-      </div>
-
-      $if(jobs)$
-        $if(environment)$
-          <span/>
-        $else$
-          <div class="row-fluid" style="margin-bottom: 20px;">
-            <button id="prod-resources-toggle-btn" class="btn">
-              <i class="icon-plus" style="margin-right: 3px;"></i><span class="btn-text">Show Resource Consumption</span>
-            </button>
-            <div id="prod-resources" class="collapse" style="width: 600px; margin-top: 10px;">
-              <table class="table table-striped table-condensed table-hover">
-                <thead>
-                  <th>Resource
-                  <th><span class="label" title="Resources used by production jobs(counted against quota)">Production consumption</span>
-                  <th><span class="label" title="Quota allocated in production">Quota</span>
-                  <th><span class="label" title="Resources used by non-production jobs (not counted against your quota)">Non-Production consumption</span>
-                </thead>
-                <tbody>
-                  <tr>
-                    <td>CPU
-                    <td>$prodResourcesUsed.numCpus$ cores
-                    <td>$resourceQuota.numCpus$ cores
-                    <td>$nonProdResourcesUsed.numCpus$ cores
-                  </tr>
-                  <tr>
-                    <td>RAM
-                    <td><script>document.write(scaleMb($prodResourcesUsed.ramMb$));</script>
-                    <td><script>document.write(scaleMb($resourceQuota.ramMb$));</script>
-                    <td><script>document.write(scaleMb($nonProdResourcesUsed.ramMb$));</script>
-                  </tr>
-                  <tr>
-                    <td>Disk
-                    <td><script>document.write(scaleMb($prodResourcesUsed.diskMb$));</script>
-                    <td><script>document.write(scaleMb($resourceQuota.diskMb$));</script>
-                    <td><script>document.write(scaleMb($nonProdResourcesUsed.diskMb$));</script>
-                  </tr>
-                </tbody>
-              </table>
-            </div>
-          </div>
-         $endif$
-
-        <div class="row-fluid" style="margin-bottom: 20px;">
-          <table id="jobs-table" class="table table-bordered table-striped table-condensed table-hover">
-            <thead>
-              <th>Job Type
-              <th>Environment
-              <th>Job
-              <th>Pending Tasks
-              <th>Active Tasks
-              <th>Finished Tasks
-              <th>Failed Tasks
-            </thead>
-            <tbody>
-              $jobs:{ job |
-              <tr>
-                <td>
-                  <span class="jobType">$job.type$</span>
-                <td>
-                  <a href="/scheduler/$role$/$job.environment$">$job.environment$</a>
-                <td>
-                  <a href="/scheduler/$role$/$job.environment$/$job.name$">$job.name$</a>
-                  <span class="job-status pull-right badge"></span>
-                  <span class="production-badge pull-right badge"></span>
-                  <input type="hidden" class="production" value="$job.production$" />
-                <td>
-                  <a href="/scheduler/$role$/$job.environment$/$job.name$?status=pending">$job.pendingTaskCount$</a>
-                  <input type="hidden" class="pending-tasks" value="$job.pendingTaskCount$" />
-                <td>
-                  <a href="/scheduler/$role$/$job.environment$/$job.name$?status=running">$job.activeTaskCount$</a>
-                  <input type="hidden" class="active-tasks" value="$job.activeTaskCount$" />
-                <td>
-                  <a href="/scheduler/$role$/$job.environment$/$job.name$?status=finished">$job.finishedTaskCount$</a>
-                  <input type="hidden" class="finished-tasks" value="$job.finishedTaskCount$" />
-                <td>
-                  <a href="/scheduler/$role$/$job.environment$/$job.name$?status=failed">$job.failedTaskCount$</a>
-                  <input type="hidden" class="failed-tasks" value="$job.failedTaskCount$" />
-                  <input type="hidden" class="recently-failed-tasks"
-                      value="$job.recentlyFailedTaskCount$" />
-              </tr>
-              }$
-            </tbody>
-          </table>
-        </div>
-      $endif$
-
-      $if(cronJobs)$
-      <div class="row-fluid">
-        <h4>Cron jobs</h4>
-        <div>
-          <table id="cron-jobs-table" class="table table-bordered table-striped table-condensed table-hover">
-            <thead>
-              <th>Environment
-              <th>Name
-              <th>Tasks
-              <th>Schedule
-              <th>Next Run
-              <th>Collision policy
-              <th>Packages
-            </thead>
-            <tbody>
-              $cronJobs:{ job |
-              <tr>
-                <td>$job.environment$
-                <td>$job.name$
-                <td>$job.pendingTaskCount$
-                <td>$job.cronSchedule$
-                <td><script>document.write(printDate($job.nextRun$));</script>
-                <td>$job.cronCollisionPolicy$
-                <td>$job.packages$
-              </tr>
-              }$
-            </tbody>
-          </table>
-        </div>
-      </div>
-      $endif$
-    </div>
-
-    $if(exception)$
-      <font color='red'>Exception: $exception$</font>
-    $endif$
-
-    <script type="text/javascript">
-      jQuery(function(){
-        jQuery('#jobs-table').dataTable({
-          'iDisplayLength': 25,
-          'aLengthMenu': [[10, 25, 50, 100, -1], [10, 25, 50, 100, "All"]],
-          'bStateSave': false,
-          'aoColumns': [
-            {'bSearchable': true},
-            {'bSearchable': false},
-            {'bSearchable': true},
-            {'bSearchable': false, 'sType': 'num-html'},
-            {'bSearchable': false, 'sType': 'num-html'},
-            {'bSearchable': false, 'sType': 'num-html'},
-            {'bSearchable': false, 'sType': 'num-html'}
-          ],
-          'fnDrawCallback': drawBadges
-        });
-        jQuery('#cron-jobs-table').dataTable({
-          'iDisplayLength': 25,
-          'aLengthMenu': [[10, 25, 50, 100, -1], [10, 25, 50, 100, "All"]],
-          'bStateSave': false,
-          'aoColumns': [
-            {'bSearchable': false},
-            {'bSearchable': true},
-            {'bSearchable': false},
-            {'bSearchable': false, 'bSortable': false},
-            {'bSearchable': false},
-            {'bSearchable': true},
-            {'bSearchable': true, 'bSortable': true}
-          ]
-        });
-
-        // Bind click event to button
-        jQuery('#prod-resources-toggle-btn').on('click', function(e){
-          e.stopPropagation();
-          e.preventDefault();
-          jQuery('#prod-resources').collapse('toggle');
-        });
-
-        // Switch between + and - icons based on button state
-        jQuery('#prod-resources').on('show', function(){
-          var parent = jQuery(this).parent();
-          var icon = parent.find('i');
-          var buttonText = parent.find('.btn-text');
-
-          icon.addClass('icon-minus').removeClass('icon-plus');
-          buttonText.html('Hide Resource Consumption');
-        });
-
-        jQuery('#prod-resources').on('hide', function(){
-          var parent = jQuery(this).parent();
-          var icon = parent.find('i');
-          var buttonText = parent.find('.btn-text');
-
-          icon.addClass('icon-plus').removeClass('icon-minus');
-          buttonText.html('Show Resource Consumption');
-        });
-
-        function drawBadges() {
-          jQuery('#jobs-table>tbody').find('tr').each(function(){
-            var tr = jQuery(this);
-            displayHealthBadge(tr);
-            displayProductionBadge(tr);
-          });
-        }
-
-        function displayHealthBadge(tr) {
-          var activeTasks = Number(tr.find('.active-tasks').val());
-          var recentlyFailedTasks = Number(tr.find('.recently-failed-tasks').val());
-          var pendingTasks = Number(tr.find('.pending-tasks').val());
-          var finishedTasks = Number(tr.find('.finished-tasks').val());
-          var totalTasks = pendingTasks + activeTasks + finishedTasks;
-          var jobStatus = tr.find('.job-status');
-
-          if (recentlyFailedTasks >= (totalTasks / 2)) {
-            jobStatus.addClass('label-important').html('Unstable');
-            jobStatus.attr('title', 'More than half of total tasks have failed in last 6 hours');
-          } else if (recentlyFailedTasks > 0) {
-            jobStatus.addClass('label-warning').html('Warning');
-            jobStatus.attr('title', 'One or more tasks have failed in last 6 hours');
-          } else {
-            jobStatus.addClass('label-success').html('Stable');
-            jobStatus.attr('title', 'No failed tasks in last 6 hours');
-          }
-
-          jobStatus.tooltip();
-        }
-
-        function displayProductionBadge(tr) {
-          var productionBadgeElem = tr.find('.production-badge');
-          var production = tr.find('.production').val();
-          if (production == "true") {
-            productionBadgeElem.addClass('badge-important').html('P');
-            productionBadgeElem.attr('title', 'This is a production job. This job gets higher priority over a non-production job.');
-          } else {
-            productionBadgeElem.hide();
-          }
-
-          productionBadgeElem.tooltip();
-        }
-      });
-    </script>
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/com/twitter/aurora/scheduler/http/slaves.st
----------------------------------------------------------------------
diff --git a/src/main/resources/com/twitter/aurora/scheduler/http/slaves.st b/src/main/resources/com/twitter/aurora/scheduler/http/slaves.st
deleted file mode 100644
index 0d28dd9..0000000
--- a/src/main/resources/com/twitter/aurora/scheduler/http/slaves.st
+++ /dev/null
@@ -1,30 +0,0 @@
-<html>
-  <head>
-    <title>Aurora $cluster_name$ slaves</title>
-    <link href="/css/bootstrap.min.css" rel="stylesheet" />
-  </head>
-  <body>
-    <h2>Slave Hosts</h2>
-    <table class="table table-striped table-condensed table-hover">
-      <thead>
-        <th>Host
-        <th>Slave ID
-        <th>Maintenance mode
-        <th>Attributes
-      </thead>
-      <tbody>
-        $slaves:{ slave |
-        <tr>
-          <td><a href="http://$slave.host$:8081">$slave.host$</a>
-          <td>$slave.id$
-          <td>$slave.mode$
-          <td>$slave.attributes$
-        </tr>
-        }$
-      </tbody>
-    </table>
-    $if(exception)$
-      <font color='red'>Exception: $exception$</font>
-    $endif$
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/com/twitter/aurora/scheduler/http/structdump.st
----------------------------------------------------------------------
diff --git a/src/main/resources/com/twitter/aurora/scheduler/http/structdump.st b/src/main/resources/com/twitter/aurora/scheduler/http/structdump.st
deleted file mode 100644
index e440990..0000000
--- a/src/main/resources/com/twitter/aurora/scheduler/http/structdump.st
+++ /dev/null
@@ -1,13 +0,0 @@
-<html>
-  <title>Aurora Struct Dump</title>
-  <head>$id$</head>
-  <body>
-    <pre>
-      $structPretty$
-    </pre>
-
-    $if(exception)$
-      <font color='red'>Exception: $exception$</font>
-    $endif$
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/com/twitter/aurora/scheduler/http/utilization.st
----------------------------------------------------------------------
diff --git a/src/main/resources/com/twitter/aurora/scheduler/http/utilization.st b/src/main/resources/com/twitter/aurora/scheduler/http/utilization.st
deleted file mode 100644
index 1e5c625..0000000
--- a/src/main/resources/com/twitter/aurora/scheduler/http/utilization.st
+++ /dev/null
@@ -1,35 +0,0 @@
-<html>
-  <head>
-    <title>Aurora $cluster_name$ slaves</title>
-    <link href="/css/bootstrap.min.css" rel="stylesheet" />
-  </head>
-  <body>
-    <h2>Cluster utilization</h2>
-    <table class="table table-striped table-condensed table-hover">
-      <thead>
-        <th>Type
-        <th>CPU
-        <th>RAM
-        <th>Disk
-      </thead>
-      <tbody>
-        $metrics:{ metric |
-        <tr>
-          <td>
-          $if(metric.link)$
-            <a href="/utilization/$metric.link$">$metric.title$</a>
-          $else$
-            $metric.title$
-          $endif$
-          <td>$metric.cpu$
-          <td>$metric.ramGb$ GB
-          <td>$metric.diskGb$ GB
-        </tr>
-        }$
-      </tbody>
-    </table>
-    $if(exception)$
-      <font color='red'>Exception: $exception$</font>
-    $endif$
-  </body>
-</html>

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/css/jquery.dataTables.css
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/css/jquery.dataTables.css b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/css/jquery.dataTables.css
new file mode 100644
index 0000000..ee6da23
--- /dev/null
+++ b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/css/jquery.dataTables.css
@@ -0,0 +1,195 @@
+/*
+ * File:        jquery.dataTables.css
+ * Version:     1.9.4
+ * Author:      Allan Jardine (www.sprymedia.co.uk)
+ * Info:        www.datatables.net
+ * 
+ * Copyright 2008-2012 Allan Jardine, all rights reserved.
+ *
+ * This source file is free software, under either the GPL v2 license or a
+ * BSD style license, available at:
+ *   http://datatables.net/license_gpl2
+ *   http://datatables.net/license_bsd
+ * 
+ * This source file is distributed in the hope that it will be useful, but 
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
+ */
+
+div.dataTables_length label {
+	float: left;
+	text-align: left;
+}
+
+div.dataTables_length select {
+	width: 75px;
+}
+
+div.dataTables_filter label {
+	float: right;
+}
+
+div.dataTables_info {
+	padding-top: 8px;
+}
+
+div.dataTables_paginate {
+	float: right;
+	margin: 0;
+}
+
+table.table {
+	clear: both;
+	margin-bottom: 6px !important;
+	max-width: none !important;
+}
+
+table.table thead .sorting,
+table.table thead .sorting_asc,
+table.table thead .sorting_desc,
+table.table thead .sorting_asc_disabled,
+table.table thead .sorting_desc_disabled {
+	cursor: pointer;
+	*cursor: hand;
+}
+
+table.table thead .sorting { background: url('/images/sort_both.png') no-repeat center right; }
+table.table thead .sorting_asc { background: url('/images/sort_asc.png') no-repeat center right; }
+table.table thead .sorting_desc { background: url('/images/sort_desc.png') no-repeat center right; }
+
+table.table thead .sorting_asc_disabled { background: url('/images/sort_asc_disabled.png') no-repeat center right; }
+table.table thead .sorting_desc_disabled { background: url('/images/sort_desc_disabled.png') no-repeat center right; }
+
+table.dataTable th:active {
+	outline: none;
+}
+
+/* Scrolling */
+div.dataTables_scrollHead table {
+	margin-bottom: 0 !important;
+	border-bottom-left-radius: 0;
+	border-bottom-right-radius: 0;
+}
+
+div.dataTables_scrollHead table thead tr:last-child th:first-child,
+div.dataTables_scrollHead table thead tr:last-child td:first-child {
+	border-bottom-left-radius: 0 !important;
+	border-bottom-right-radius: 0 !important;
+}
+
+div.dataTables_scrollBody table {
+	border-top: none;
+	margin-bottom: 0 !important;
+}
+
+div.dataTables_scrollBody tbody tr:first-child th,
+div.dataTables_scrollBody tbody tr:first-child td {
+	border-top: none;
+}
+
+div.dataTables_scrollFoot table {
+	border-top: none;
+}
+
+
+
+
+/*
+ * TableTools styles
+ */
+.table tbody tr.active td,
+.table tbody tr.active th {
+	background-color: #08C;
+	color: white;
+}
+
+.table tbody tr.active:hover td,
+.table tbody tr.active:hover th {
+	background-color: #0075b0 !important;
+}
+
+.table-striped tbody tr.active:nth-child(odd) td,
+.table-striped tbody tr.active:nth-child(odd) th {
+	background-color: #017ebc;
+}
+
+table.DTTT_selectable tbody tr {
+	cursor: pointer;
+	*cursor: hand;
+}
+
+div.DTTT .btn {
+	color: #333 !important;
+	font-size: 12px;
+}
+
+div.DTTT .btn:hover {
+	text-decoration: none !important;
+}
+
+
+ul.DTTT_dropdown.dropdown-menu a {
+	color: #333 !important; /* needed only when demo_page.css is included */
+}
+
+ul.DTTT_dropdown.dropdown-menu li:hover a {
+	background-color: #0088cc;
+	color: white !important;
+}
+
+/* TableTools information display */
+div.DTTT_print_info.modal {
+	height: 150px;
+	margin-top: -75px;
+	text-align: center;
+}
+
+div.DTTT_print_info h6 {
+	font-weight: normal;
+	font-size: 28px;
+	line-height: 28px;
+	margin: 1em;
+}
+
+div.DTTT_print_info p {
+	font-size: 14px;
+	line-height: 20px;
+}
+
+
+
+/*
+ * FixedColumns styles
+ */
+div.DTFC_LeftHeadWrapper table,
+div.DTFC_LeftFootWrapper table,
+table.DTFC_Cloned tr.even {
+	background-color: white;
+}
+
+div.DTFC_LeftHeadWrapper table {
+	margin-bottom: 0 !important;
+	border-top-right-radius: 0 !important;
+	border-bottom-left-radius: 0 !important;
+	border-bottom-right-radius: 0 !important;
+}
+
+div.DTFC_LeftHeadWrapper table thead tr:last-child th:first-child,
+div.DTFC_LeftHeadWrapper table thead tr:last-child td:first-child {
+	border-bottom-left-radius: 0 !important;
+	border-bottom-right-radius: 0 !important;
+}
+
+div.DTFC_LeftBodyWrapper table {
+	border-top: none;
+	margin-bottom: 0 !important;
+}
+
+div.DTFC_LeftBodyWrapper tbody tr:first-child th,
+div.DTFC_LeftBodyWrapper tbody tr:first-child td {
+	border-top: none;
+}
+
+div.DTFC_LeftFootWrapper table {
+	border-top: none;
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_disabled.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_disabled.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_disabled.png
new file mode 100644
index 0000000..881de79
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_disabled.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled.png
new file mode 100644
index 0000000..c608682
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled_hover.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled_hover.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled_hover.png
new file mode 100644
index 0000000..d300f10
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/back_enabled_hover.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_disabled.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_disabled.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_disabled.png
new file mode 100644
index 0000000..6a6ded7
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_disabled.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled.png
new file mode 100644
index 0000000..a4e6b53
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled_hover.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled_hover.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled_hover.png
new file mode 100644
index 0000000..fc46c5e
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/forward_enabled_hover.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc.png
new file mode 100644
index 0000000..a88d797
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc_disabled.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc_disabled.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc_disabled.png
new file mode 100644
index 0000000..4e144cf
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_asc_disabled.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_both.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_both.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_both.png
new file mode 100644
index 0000000..1867040
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_both.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc.png
new file mode 100644
index 0000000..def071e
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc_disabled.png
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc_disabled.png b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc_disabled.png
new file mode 100644
index 0000000..7824973
Binary files /dev/null and b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/images/sort_desc_disabled.png differ

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.bootstrap.js
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.bootstrap.js b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.bootstrap.js
new file mode 100644
index 0000000..420e507
--- /dev/null
+++ b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.bootstrap.js
@@ -0,0 +1,165 @@
+/*
+ * File:        dataTables.bootstrap.js
+ * Version:     1.9.4
+ * Author:      Allan Jardine (www.sprymedia.co.uk)
+ * Info:        www.datatables.net
+ * 
+ * Copyright 2008-2012 Allan Jardine, all rights reserved.
+ *
+ * This source file is free software, under either the GPL v2 license or a
+ * BSD style license, available at:
+ *   http://datatables.net/license_gpl2
+ *   http://datatables.net/license_bsd
+ * 
+ * This source file is distributed in the hope that it will be useful, but 
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the license files for details.
+ */
+
+/* Set the defaults for DataTables initialisation */
+$.extend( true, $.fn.dataTable.defaults, {
+  "sDom": "<'row-fluid'<'span4'l><'span2'r><'span6'f>>t<'row-fluid'<'span6'i><'span6'p>>",
+  "sPaginationType": "bootstrap",
+  "oLanguage": {
+    "sLengthMenu": "_MENU_ records per page"
+  }
+} );
+
+
+/* Default class modification */
+$.extend( $.fn.dataTableExt.oStdClasses, {
+  "sWrapper": "dataTables_wrapper form-inline"
+} );
+
+
+/* API method to get paging information */
+$.fn.dataTableExt.oApi.fnPagingInfo = function ( oSettings )
+{
+  return {
+    "iStart":         oSettings._iDisplayStart,
+    "iEnd":           oSettings.fnDisplayEnd(),
+    "iLength":        oSettings._iDisplayLength,
+    "iTotal":         oSettings.fnRecordsTotal(),
+    "iFilteredTotal": oSettings.fnRecordsDisplay(),
+    "iPage":          oSettings._iDisplayLength === -1 ?
+      0 : Math.ceil( oSettings._iDisplayStart / oSettings._iDisplayLength ),
+    "iTotalPages":    oSettings._iDisplayLength === -1 ?
+      0 : Math.ceil( oSettings.fnRecordsDisplay() / oSettings._iDisplayLength )
+  };
+};
+
+
+/* Bootstrap style pagination control */
+$.extend( $.fn.dataTableExt.oPagination, {
+  "bootstrap": {
+    "fnInit": function( oSettings, nPaging, fnDraw ) {
+      var oLang = oSettings.oLanguage.oPaginate;
+      var fnClickHandler = function ( e ) {
+        e.preventDefault();
+        if ( oSettings.oApi._fnPageChange(oSettings, e.data.action) ) {
+          fnDraw( oSettings );
+        }
+      };
+
+      $(nPaging).addClass('pagination').append(
+        '<ul>'+
+          '<li class="prev disabled"><a href="#">&larr; '+oLang.sPrevious+'</a></li>'+
+          '<li class="next disabled"><a href="#">'+oLang.sNext+' &rarr; </a></li>'+
+        '</ul>'
+      );
+      var els = $('a', nPaging);
+      $(els[0]).bind( 'click.DT', { action: "previous" }, fnClickHandler );
+      $(els[1]).bind( 'click.DT', { action: "next" }, fnClickHandler );
+    },
+
+    "fnUpdate": function ( oSettings, fnDraw ) {
+      var iListLength = 5;
+      var oPaging = oSettings.oInstance.fnPagingInfo();
+      var an = oSettings.aanFeatures.p;
+      var i, ien, j, sClass, iStart, iEnd, iHalf=Math.floor(iListLength/2);
+
+      if ( oPaging.iTotalPages < iListLength) {
+        iStart = 1;
+        iEnd = oPaging.iTotalPages;
+      }
+      else if ( oPaging.iPage <= iHalf ) {
+        iStart = 1;
+        iEnd = iListLength;
+      } else if ( oPaging.iPage >= (oPaging.iTotalPages-iHalf) ) {
+        iStart = oPaging.iTotalPages - iListLength + 1;
+        iEnd = oPaging.iTotalPages;
+      } else {
+        iStart = oPaging.iPage - iHalf + 1;
+        iEnd = iStart + iListLength - 1;
+      }
+
+      for ( i=0, ien=an.length ; i<ien ; i++ ) {
+        // Remove the middle elements
+        $('li:gt(0)', an[i]).filter(':not(:last)').remove();
+
+        // Add the new list items and their event handlers
+        for ( j=iStart ; j<=iEnd ; j++ ) {
+          sClass = (j==oPaging.iPage+1) ? 'class="active"' : '';
+          $('<li '+sClass+'><a href="#">'+j+'</a></li>')
+            .insertBefore( $('li:last', an[i])[0] )
+            .bind('click', function (e) {
+              e.preventDefault();
+              oSettings._iDisplayStart = (parseInt($('a', this).text(),10)-1) * oPaging.iLength;
+              fnDraw( oSettings );
+            } );
+        }
+
+        // Add / remove disabled classes from the static elements
+        if ( oPaging.iPage === 0 ) {
+          $('li:first', an[i]).addClass('disabled');
+        } else {
+          $('li:first', an[i]).removeClass('disabled');
+        }
+
+        if ( oPaging.iPage === oPaging.iTotalPages-1 || oPaging.iTotalPages === 0 ) {
+          $('li:last', an[i]).addClass('disabled');
+        } else {
+          $('li:last', an[i]).removeClass('disabled');
+        }
+      }
+    }
+  }
+} );
+
+
+/*
+ * TableTools Bootstrap compatibility
+ * Required TableTools 2.1+
+ */
+if ( $.fn.DataTable.TableTools ) {
+  // Set the classes that TableTools uses to something suitable for Bootstrap
+  $.extend( true, $.fn.DataTable.TableTools.classes, {
+    "container": "DTTT btn-group",
+    "buttons": {
+      "normal": "btn",
+      "disabled": "disabled"
+    },
+    "collection": {
+      "container": "DTTT_dropdown dropdown-menu",
+      "buttons": {
+        "normal": "",
+        "disabled": "disabled"
+      }
+    },
+    "print": {
+      "info": "DTTT_print_info modal"
+    },
+    "select": {
+      "row": "active"
+    }
+  } );
+
+  // Have the collection use a bootstrap compatible dropdown
+  $.extend( true, $.fn.DataTable.TableTools.DEFAULTS.oTags, {
+    "collection": {
+      "container": "ul",
+      "button": "li",
+      "liner": "a"
+    }
+  } );
+};
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.htmlNumberType.js
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.htmlNumberType.js b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.htmlNumberType.js
new file mode 100644
index 0000000..885ad34
--- /dev/null
+++ b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.htmlNumberType.js
@@ -0,0 +1,67 @@
+/**
+ * DataTables custom plugin to extract numbers from HTML tags
+ * for sorting rows in numeric order.
+ *
+ * Ref: http://www.datatables.net/plug-ins/sorting
+ *
+ * Compatible with DataTables v1.9.4
+ *
+ */
+
+jQuery.extend(jQuery.fn.dataTableExt.oSort, {
+  "num-html-pre": function (a) {
+    // Extract the numeric value from the html by removing all tags.
+    var x = String(a).replace(/<[\s\S]*?>/g, "");
+    return parseFloat(x);
+  },
+ 
+  "num-html-asc": function (a, b) {
+    // Compare the extracted numeric values for asc sort.
+    return ((a < b) ? -1 : ((a > b) ? 1 : 0));
+  },
+ 
+  "num-html-desc": function (a, b) {
+    // Compare the extracted numeric values for desc sort.
+    return ((a < b) ? 1 : ((a > b) ? -1 : 0));
+  }
+});
+
+/*
+ * Type detection function for custom type "num-html".
+ *
+ * Ref: http://www.datatables.net/plug-ins/type-detection#how_to
+ */
+jQuery.fn.dataTableExt.aTypes.unshift(function (sData) {
+  sData = typeof sData.replace == "function" ?
+    sData.replace( /<[\s\S]*?>/g, "" ) : sData;
+  sData = $.trim(sData);
+    
+  var sValidFirstChars = "0123456789-";
+  var sValidChars = "0123456789.";
+  var Char;
+  var bDecimal = false;
+    
+  // Check for a valid first char (no period and allow negatives).
+  Char = sData.charAt(0); 
+  if (sValidFirstChars.indexOf(Char) == -1) {
+    return null;
+  }
+    
+  // Check all the other characters are valid.
+  for ( var i=1 ; i<sData.length ; i++ ) {
+    Char = sData.charAt(i); 
+    if (sValidChars.indexOf(Char) == -1) {
+      return null;
+    }
+      
+    // Only one decimal place allowed.
+    if (Char == ".") {
+      if (bDecimal) {
+        return null;
+      }
+      bDecimal = true;
+    }
+  }
+    
+  return "num-html";
+});
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/bc1635df/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.localstorage.js
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.localstorage.js b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.localstorage.js
new file mode 100644
index 0000000..3c0b39a
--- /dev/null
+++ b/src/main/resources/org/apache/aurora/scheduler/http/assets/datatables/js/dataTables.localstorage.js
@@ -0,0 +1,18 @@
+/**
+ * Make browser's local storage as the default storage for Datatables plugin.
+ * Compatible with Datatables v1.9.4
+ *
+ * http://www.datatables.net/beta/1.9/examples/advanced_init/localstorage.html
+ *
+ * Always link this file after linking jquery.dataTables.min.js
+ */
+$.extend(true, $.fn.dataTable.defaults, {    
+  "fnStateSave": function (oSettings, oData) {
+  localStorage.setItem("DataTables_" + window.location.pathname + "_" + oSettings.sTableId, 
+                       JSON.stringify(oData));
+  },
+  "fnStateLoad": function (oSettings) {
+    return JSON.parse(localStorage
+        .getItem("DataTables_" + window.location.pathname + "_" + oSettings.sTableId));
+  }
+});
\ No newline at end of file


Mime
View raw message