Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7,953 changes: 7,910 additions & 43 deletions presto-router/src/main/resources/router_ui/dist/index.js

Large diffs are not rendered by default.

18 changes: 8 additions & 10 deletions presto-router/src/main/resources/router_ui/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@

<link rel="icon" href="assets/favicon.ico">

<!-- Link for btn checkmark-->
<link rel="stylesheet" href="vendor/bootstrap/css/bootstrap-icons.min.css">

<!-- Bootstrap core -->
<link href="vendor/bootstrap/css/bootstrap.css" rel="stylesheet">

Expand All @@ -19,25 +22,20 @@
<![endif]-->

<!-- jQuery -->
<script type="text/javascript" src="vendor/jquery/jquery-2.2.3.min.js"></script>

<!-- Bootstrap JS -->
<script type="text/javascript" src="vendor/bootstrap/js/bootstrap.js"></script>
<script type="text/javascript" src="vendor/jquery/jquery-3.7.1.min.js"></script>

<!-- Sparkline -->
<script type="text/javascript" src="vendor/jquery.sparkline/jquery.sparkline.min.js"></script>

<script type="text/javascript" >
jQuery.htmlPrefilter = function( html ) {
return html;
};
</script>

<!-- CSS loader -->
<link href="vendor/css-loaders/loader.css" rel="stylesheet">

<!-- Custom CSS -->
<link href="assets/presto.css" rel="stylesheet">

<!-- Bootstrap JS 5.3.3 -->
<script src="vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its a little non-obvious that we went from bootstrap 3.3.5 to 5.3.3. Can we add the version number we use in the comment on L42 ?


</head>

<body>
Expand Down
45 changes: 0 additions & 45 deletions presto-router/src/main/resources/router_ui/src/.yarnclean

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ export class ClusterHUD extends React.Component {
});
this.resetTimer();
}.bind(this))
.error(function () {
.fail(function () {
this.resetTimer();
}.bind(this));
}
Expand Down Expand Up @@ -145,38 +145,38 @@ export class ClusterHUD extends React.Component {
});
}

$('[data-toggle="tooltip"]').tooltip();
$('[data-bs-toggle="tooltip"]').tooltip();
}

render() {
return (<div className="row">
<div className="col-xs-12">
<div className="col-12">
<div className="row">
<div className="col-xs-6">
<div className="col-6">
<div className="stat-title">
<span className="text" data-toggle="tooltip" data-placement="right" title="Total number of queries currently running">
<span className="text" data-bs-toggle="tooltip" data-placement="right" title="Total number of queries currently running">
Running queries
</span>
</div>
</div>
<div className="col-xs-6">
<div className="col-6">
<div className="stat-title">
<span className="text" data-toggle="tooltip" data-placement="right" title="Total number of active cluster">
<span className="text" data-bs-toggle="tooltip" data-placement="right" title="Total number of active cluster">
Cluster Count
</span>
</div>
</div>
</div>
<div className="row stat-line-end">
<div className="col-xs-6">
<div className="col-6">
<div className="stat stat-large">
<span className="stat-text">
{this.state.runningQueries[this.state.runningQueries.length - 1]}
</span>
<span className="sparkline" id="running-queries-sparkline"><div className="loader">Loading ...</div></span>
</div>
</div>
<div className="col-xs-6">
<div className="col-6">
<div className="stat stat-large">
<span className="stat-text">
{this.state.clusterCount[this.state.clusterCount.length - 1]}
Expand All @@ -186,31 +186,31 @@ export class ClusterHUD extends React.Component {
</div>
</div>
<div className="row">
<div className="col-xs-6">
<div className="col-6">
<div className="stat-title">
<span className="text" data-toggle="tooltip" data-placement="right" title="Total number of queries currently queued and awaiting execution">
<span className="text" data-bs-toggle="tooltip" data-placement="right" title="Total number of queries currently queued and awaiting execution">
Queued queries
</span>
</div>
</div>
<div className="col-xs-6">
<div className="col-6">
<div className="stat-title">
<span className="text" data-toggle="tooltip" data-placement="right" title="Total number of active worker nodes">
<span className="text" data-bs-toggle="tooltip" data-placement="right" title="Total number of active worker nodes">
Active Workers
</span>
</div>
</div>
</div>
<div className="row stat-line-end">
<div className="col-xs-6">
<div className="col-6">
<div className="stat stat-large">
<span className="stat-text">
{this.state.queuedQueries[this.state.queuedQueries.length - 1]}
</span>
<span className="sparkline" id="queued-queries-sparkline"><div className="loader">Loading ...</div></span>
</div>
</div>
<div className="col-xs-6">
<div className="col-6">
<div className="stat stat-large">
<span className="stat-text">
{this.state.activeWorkers[this.state.activeWorkers.length - 1]}
Expand All @@ -221,31 +221,31 @@ export class ClusterHUD extends React.Component {
</div>
</div>
<div className="row">
<div className="col-xs-6">
<div className="col-6">
<div className="stat-title">
<span className="text" data-toggle="tooltip" data-placement="right" title="Total number of queries currently blocked and unable to make progress">
<span className="text" data-bs-toggle="tooltip" data-placement="right" title="Total number of queries currently blocked and unable to make progress">
Blocked Queries
</span>
</div>
</div>
<div className="col-xs-6">
<div className="col-6">
<div className="stat-title">
<span className="text" data-toggle="tooltip" data-placement="right" title="Moving average of total running drivers">
<span className="text" data-bs-toggle="tooltip" data-placement="right" title="Moving average of total running drivers">
Running Drivers
</span>
</div>
</div>
</div>
<div className="row stat-line-end">
<div className="col-xs-6">
<div className="col-6">
<div className="stat stat-large">
<span className="stat-text">
{this.state.blockedQueries[this.state.blockedQueries.length - 1]}
</span>
<span className="sparkline" id="blocked-queries-sparkline"><div className="loader">Loading ...</div></span>
</div>
</div>
<div className="col-xs-6">
<div className="col-6">
<div className="stat stat-large">
<span className="stat-text">
{formatCount(this.state.runningDrivers[this.state.runningDrivers.length - 1])}
Expand All @@ -258,4 +258,3 @@ export class ClusterHUD extends React.Component {
</div>);
}
}

Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,7 @@ export class PageTitle extends React.Component<Props, State> {
refreshLoop() {
clearTimeout(this.timeoutId);
fetch("/v1/info")
.then(response => {
return response.json()
})
.then(response => response.json())
.then(info => {
this.setState({
info: info,
Expand All @@ -56,7 +54,7 @@ export class PageTitle extends React.Component<Props, State> {
modalShown: false,
});
//$FlowFixMe$ Bootstrap 3 plugin
$('#no-connection-modal').modal('hide');
$('#no-connection-modal').hide();
this.resetTimer();
})
.catch(error => {
Expand All @@ -69,7 +67,7 @@ export class PageTitle extends React.Component<Props, State> {

if (!this.state.modalShown && (error || (Date.now() - this.state.lastSuccess) > 30 * 1000)) {
//$FlowFixMe$ Bootstrap 3 plugin
$('#no-connection-modal').modal();
$('#no-connection-modal').hide();
this.setState({modalShown: true});
}
});
Expand Down Expand Up @@ -104,7 +102,7 @@ export class PageTitle extends React.Component<Props, State> {

return (
<div>
<nav className="navbar">
<nav className="navbar navbar-expand-lg navbar-dark bg-dark">
<div className="container-fluid">
<div className="navbar-header">
<table>
Expand All @@ -121,8 +119,11 @@ export class PageTitle extends React.Component<Props, State> {
</tbody>
</table>
</div>
<button className="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
<span className="navbar-toggler-icon"></span>
</button>
<div id="navbar" className="navbar-collapse collapse">
<ul className="nav navbar-nav navbar-cluster-info-right">
<ul className="nav navbar-nav navbar-right">
<li>
<span className="navbar-cluster-info">
<span className="uppercase">Environment</span><br/>
Expand All @@ -142,7 +143,7 @@ export class PageTitle extends React.Component<Props, State> {
<div className="modal-dialog modal-sm" role="document">
<div className="modal-content">
<div className="row error-message">
<div className="col-xs-12">
<div className="col-12">
<br />
<h4>Unable to connect to server</h4>
<p>{this.state.errorText ? "Error: " + this.state.errorText : null}</p>
Expand Down
Loading
Loading