mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2025-01-21 15:41:24 +01:00
4.4.0 DEV3
This commit is contained in:
parent
bd2ffdce22
commit
9c46021f18
@ -52,6 +52,10 @@ GraphColors:
|
||||
ServerPreferencePie: '"#707070", "#828282", "#595959", "#676767", "#7F7F7F", "#989898", "#535353", "#888888", "#6F6F6F", "#707070"'
|
||||
WorldMap_High: "#555555"
|
||||
WorldMap_Low: "#DDDDDD"
|
||||
Ping:
|
||||
Max: '#707070'
|
||||
Avg: '#828282'
|
||||
Min: '#595959'
|
||||
|
||||
# Leave blank "" for white
|
||||
ParsedElements:
|
||||
|
@ -52,6 +52,10 @@ GraphColors:
|
||||
ServerPreferencePie: '"#2A89A5", "#709B31", "#0075FE", "#865186", "#459A8F", "#A3A344", "#5F3F9E", "#C27B33", "#4A8567", "#5F7291"'
|
||||
WorldMap_High: "#386F21"
|
||||
WorldMap_Low: "#EEFFEE"
|
||||
Ping:
|
||||
Max: '#ffa000'
|
||||
Avg: '#ffc107'
|
||||
Min: '#ffd54f'
|
||||
|
||||
# Leave blank "" for white
|
||||
ParsedElements:
|
||||
|
@ -52,6 +52,10 @@ GraphColors:
|
||||
ServerPreferencePie: '"#00E0FF", "#35EF00", "#0075FE", "#F007F0", "#00F5C6", "#C9C900", "#8700FF", "#FF4E00", "#00CF4C", "#267BFF"'
|
||||
WorldMap_High: "#00C800"
|
||||
WorldMap_Low: "#EEFFEE"
|
||||
Ping:
|
||||
Max: '#ffa000'
|
||||
Avg: '#ffc107'
|
||||
Min: '#ffd54f'
|
||||
|
||||
# Leave blank "" for white
|
||||
ParsedElements:
|
||||
|
@ -52,6 +52,10 @@ GraphColors:
|
||||
ServerPreferencePie: '"#84705F", "#948271", "#6D5948", "#7B6755", "#917F6E", "#A89889", "#675342", "#9A8877", "#836F5D", "#84705F"'
|
||||
WorldMap_High: "#695544"
|
||||
WorldMap_Low: "#FFFFFF"
|
||||
Ping:
|
||||
Max: '#ffa000'
|
||||
Avg: '#ffc107'
|
||||
Min: '#ffd54f'
|
||||
|
||||
# Leave blank "" for white
|
||||
ParsedElements:
|
||||
|
@ -52,6 +52,10 @@ GraphColors:
|
||||
ServerPreferencePie: '"#00869B", "#79AC00", "#25455D", "#8D3472", "#33A887", "#C5BC24", "#492176", "#EA7C00", "#307F4C", "#516681"'
|
||||
WorldMap_High: "#267f00"
|
||||
WorldMap_Low: "#EEFFEE"
|
||||
Ping:
|
||||
Max: '#ffa000'
|
||||
Avg: '#ffc107'
|
||||
Min: '#ffd54f'
|
||||
|
||||
# Leave blank "" for white
|
||||
ParsedElements:
|
||||
|
@ -52,6 +52,10 @@ GraphColors:
|
||||
ServerPreferencePie: '"#0099C6", "#66AA00", "#316395", "#994499", "#22AA99", "#AAAA11", "#6633CC", "#E67300", "#329262", "#5574A6"'
|
||||
WorldMap_High: "#267f00"
|
||||
WorldMap_Low: "#EEFFEE"
|
||||
Ping:
|
||||
Max: '#ffa000'
|
||||
Avg: '#ffc107'
|
||||
Min: '#ffd54f'
|
||||
|
||||
# Leave blank "" for white
|
||||
ParsedElements:
|
||||
|
40
Plan/src/main/resources/web/js/charts/horizontalBarGraph.js
Normal file
40
Plan/src/main/resources/web/js/charts/horizontalBarGraph.js
Normal file
@ -0,0 +1,40 @@
|
||||
function horizontalBarChart(id, categories, series, text) {
|
||||
Highcharts.chart(id, {
|
||||
chart: {
|
||||
type: 'bar'
|
||||
},
|
||||
title: {
|
||||
text: ''
|
||||
},
|
||||
xAxis: {
|
||||
categories: categories,
|
||||
title: {
|
||||
text: null
|
||||
}
|
||||
},
|
||||
yAxis: {
|
||||
min: 0,
|
||||
title: {
|
||||
text: text,
|
||||
align: 'high'
|
||||
},
|
||||
labels: {
|
||||
overflow: 'justify'
|
||||
}
|
||||
},
|
||||
legend: {
|
||||
enabled: false
|
||||
},
|
||||
plotOptions: {
|
||||
bar: {
|
||||
dataLabels: {
|
||||
enabled: true
|
||||
}
|
||||
}
|
||||
},
|
||||
credits: {
|
||||
enabled: true
|
||||
},
|
||||
series: series
|
||||
});
|
||||
}
|
36
Plan/src/main/resources/web/js/charts/lineGraph.js
Normal file
36
Plan/src/main/resources/web/js/charts/lineGraph.js
Normal file
@ -0,0 +1,36 @@
|
||||
function lineChart(id, series) {
|
||||
Highcharts.stockChart(id, {
|
||||
rangeSelector: {
|
||||
selected: 2,
|
||||
buttons: [{
|
||||
type: 'hour',
|
||||
count: 12,
|
||||
text: '12h'
|
||||
}, {
|
||||
type: 'hour',
|
||||
count: 24,
|
||||
text: '24h'
|
||||
}, {
|
||||
type: 'day',
|
||||
count: 7,
|
||||
text: '7d'
|
||||
}, {
|
||||
type: 'month',
|
||||
count: 1,
|
||||
text: '30d'
|
||||
}, {
|
||||
type: 'all',
|
||||
text: 'All'
|
||||
}]
|
||||
},
|
||||
yAxis: {
|
||||
softMax: 2,
|
||||
softMin: 0
|
||||
},
|
||||
title: {text: ''},
|
||||
legend: {
|
||||
enabled: true
|
||||
},
|
||||
series: series
|
||||
});
|
||||
}
|
@ -473,7 +473,14 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="body">
|
||||
<div id="worldMap" class="dashboard-flot-chart"></div>
|
||||
<div class="row clearfix">
|
||||
<div class="col-xs-12 col-sm-12 col-md-3 col-lg-3">
|
||||
<div id="countryBarChart" class="dashboard-flot-chart"></div>
|
||||
</div>
|
||||
<div class="col-xs-12 col-sm-12 col-md-9 col-lg-9">
|
||||
<div id="worldMap" class="dashboard-flot-chart"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -511,6 +518,7 @@
|
||||
<script src="../js/charts/activityPie.js"></script>
|
||||
<script src="../js/charts/stackGraph.js"></script>
|
||||
<script src="../js/charts/worldMap.js"></script>
|
||||
<script src="../js/charts/horizontalBarGraph.js"></script>
|
||||
|
||||
<!-- Chart Data -->
|
||||
<script>
|
||||
@ -533,7 +541,9 @@
|
||||
geolocations: ${geoMapSeries},
|
||||
activityStack: ${activityStackSeries},
|
||||
activityStackCategories: ${activityStackCategories},
|
||||
healthIndex: ${healthIndex}
|
||||
healthIndex: ${healthIndex},
|
||||
countryCategories: ${countryCategories},
|
||||
country: ${countrySeries}
|
||||
}
|
||||
};
|
||||
// HighCharts Series
|
||||
@ -559,6 +569,11 @@
|
||||
colorByPoint: true,
|
||||
data: v.data.activityPie
|
||||
},
|
||||
country: {
|
||||
color: '#4CAF50',
|
||||
name: 'Players',
|
||||
data: v.data.country
|
||||
},
|
||||
activityStack: v.data.activityStack,
|
||||
activityStackCategories: v.data.activityStackCategories
|
||||
};
|
||||
@ -590,6 +605,7 @@
|
||||
stackChart('activityStackGraph', series.activityStackCategories, series.activityStack, 'Players');
|
||||
healthGauge('healthGauge', [v.data.healthIndex]);
|
||||
worldMap('worldMap', v.colors.geolocationsLow, v.colors.geolocationsHigh, series.geolocations);
|
||||
horizontalBarChart('countryBarChart', v.data.countryCategories, [series.country], 'Players');
|
||||
|
||||
function openFunc(i) {
|
||||
return function () {
|
||||
|
@ -468,7 +468,8 @@
|
||||
data-container="body" data-html="true"
|
||||
data-original-title="Player Online Activity"
|
||||
data-content="Chart of Player Counts, recorded by TPS task.
|
||||
<br><br>TPS task starts 50 seconds after Plan enables and records Maximum player count for each minute."
|
||||
<br><br>TPS task starts 50 seconds after Plan enables and records Maximum player count for each minute.
|
||||
<br><br><b>Unique Players:</b> Calculated from sessions, new players are calculated from register dates. Same data is available on the Calendar."
|
||||
>help_outline</a>
|
||||
<ul class="nav nav-tabs tab-nav-right" role="tablist">
|
||||
<li role="presentation" class="active"><a href="#playersOnline"
|
||||
@ -819,7 +820,7 @@
|
||||
tabindex="0" data-trigger="focus" data-toggle="popover" data-placement="left"
|
||||
data-container="body" data-html="true"
|
||||
data-original-title="Performance Charts"
|
||||
data-content="Charts of different performance metrics, recorded by TPS task.
|
||||
data-content="Charts of different performance metrics, recorded by TPS task & Ping task.
|
||||
<br><br>TPS task starts 50 seconds after Plan enables and records Maximum player count & Average of other metrics for each minute.
|
||||
<br><br>Any dataset can be hidden by clicking the name in the legend.
|
||||
<br><br>Note: Due to JVM performance restraints CPU usage may be unavailable on some Machines."
|
||||
@ -835,6 +836,9 @@
|
||||
<li role="presentation"><a href="#world" data-toggle="tab"><i
|
||||
class="fa fa-map"></i>
|
||||
WORLD LOAD</a></li>
|
||||
<li role="presentation"><a href="#ping" data-toggle="tab"><i
|
||||
class="fa fa-signal"></i>
|
||||
PING</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
@ -853,6 +857,9 @@
|
||||
<div role="tabpanel" class="tab-pane fade" id="world">
|
||||
<div id="worldGraph" style="height: 500px;"></div>
|
||||
</div>
|
||||
<div role="tabpanel" class="tab-pane fade" id="ping">
|
||||
<div id="pingGraph" style="height: 500px;"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -1044,7 +1051,39 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="body">
|
||||
<div id="worldMap" class="dashboard-flot-chart"></div>
|
||||
<div class="row clearfix">
|
||||
<div class="col-xs-12 col-sm-12 col-md-3 col-lg-3">
|
||||
<div id="countryBarChart" class="dashboard-flot-chart"></div>
|
||||
</div>
|
||||
<div class="col-xs-12 col-sm-12 col-md-9 col-lg-9">
|
||||
<div id="worldMap" class="dashboard-flot-chart"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row clearfix">
|
||||
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">
|
||||
<div class="card">
|
||||
<div class="header">
|
||||
<div class="row clearfix">
|
||||
<div class="col-xs-8 col-sm-8 col-lg-8">
|
||||
<h2><i class="fa fa-wifi"></i> Connection Information</h2>
|
||||
</div>
|
||||
<div class="col-xs-4 col-sm-4 col-lg-4">
|
||||
<a href="javascript:void(0)" class="help material-icons pull-right"
|
||||
tabindex="0" data-trigger="focus" data-toggle="popover" data-placement="left"
|
||||
data-container="body" data-html="true"
|
||||
data-original-title="Connection Information"
|
||||
data-content="Ping gathered by Ping task - Ping data is stored for 2 weeks.<br><br>
|
||||
Geolocations are not directly linked to ping data, so player's ping is placed under the most recent login location."
|
||||
>help_outline</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-default">
|
||||
${tablePing}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -1119,6 +1158,7 @@
|
||||
<script src="js/charts/punchCard.js"></script>
|
||||
<script src="js/charts/healthGauge.js"></script>
|
||||
<script src="js/charts/activityPie.js"></script>
|
||||
<script src="js/charts/lineGraph.js"></script>
|
||||
<script src="js/charts/stackGraph.js"></script>
|
||||
<script src="js/charts/worldPie.js"></script>
|
||||
<script src="js/charts/performanceGraph.js"></script>
|
||||
@ -1127,6 +1167,7 @@
|
||||
<script src="js/charts/worldGraph.js"></script>
|
||||
<script src="js/charts/worldMap.js"></script>
|
||||
<script src="js/charts/onlineActivityCalendar.js"></script>
|
||||
<script src="js/charts/horizontalBarGraph.js"></script>
|
||||
|
||||
<!-- Chart Data -->
|
||||
<script>
|
||||
@ -1134,13 +1175,14 @@
|
||||
lang: {noData: "No Data to Display"},
|
||||
time: {
|
||||
timezoneOffset: ${timeZone} * 60
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
// Replaced Variables
|
||||
var v = {
|
||||
colors: {
|
||||
playersOnline: '${playersGraphColor}',
|
||||
newPlayers: '#8BC34A',
|
||||
tpsLow: '${tpsLowColor}',
|
||||
tpsMed: '${tpsMediumColor}',
|
||||
tpsHigh: '${tpsHighColor}',
|
||||
@ -1150,7 +1192,10 @@
|
||||
chunks: '#b58310',
|
||||
geolocationsLow: '${worldMapColLow}',
|
||||
geolocationsHigh: '${worldMapColHigh}',
|
||||
punchCard: '#222'
|
||||
punchCard: '#222',
|
||||
maxPing: '${maxPingColor}',
|
||||
minPing: '${minPingColor}',
|
||||
avgPing: '${avgPingColor}'
|
||||
},
|
||||
values: {
|
||||
tpsMed: ${tpsMedium},
|
||||
@ -1159,6 +1204,8 @@
|
||||
},
|
||||
data: {
|
||||
playersOnline: ${playersOnlineSeries},
|
||||
uniquePlayers: ${uniquePlayersSeries},
|
||||
newPlayers: ${newPlayersSeries},
|
||||
tps: ${tpsSeries},
|
||||
cpu: ${cpuSeries},
|
||||
ram: ${ramSeries},
|
||||
@ -1172,7 +1219,12 @@
|
||||
activityStack: ${activityStackSeries},
|
||||
activityStackCategories: ${activityStackCategories},
|
||||
healthIndex: ${healthIndex},
|
||||
calendar: ${calendarSeries}
|
||||
calendar: ${calendarSeries},
|
||||
countryCategories: ${countryCategories},
|
||||
country: ${countrySeries},
|
||||
avgPing: ${avgPingSeries},
|
||||
maxPing: ${maxPingSeries},
|
||||
minPing: ${minPingSeries}
|
||||
}
|
||||
};
|
||||
|
||||
@ -1180,11 +1232,16 @@
|
||||
var s = {
|
||||
name: {
|
||||
playersOnline: 'Players Online',
|
||||
uniquePlayers: 'Unique Players',
|
||||
newPlayers: 'New Players',
|
||||
tps: 'TPS',
|
||||
cpu: 'CPU Usage (%)',
|
||||
ram: 'RAM Usage (MB)',
|
||||
entities: 'Loaded Entities',
|
||||
chunks: 'Loaded Chunks'
|
||||
chunks: 'Loaded Chunks',
|
||||
maxPing: 'Worst Ping',
|
||||
minPing: 'Best Ping',
|
||||
avgPing: 'Average Ping'
|
||||
},
|
||||
tooltip: {
|
||||
twoDecimals: {
|
||||
@ -1220,6 +1277,41 @@
|
||||
color: v.colors.playersOnline,
|
||||
yAxis: 0
|
||||
},
|
||||
avgPing: {
|
||||
name: s.name.avgPing,
|
||||
type: s.type.spline,
|
||||
tooltip: s.tooltip.twoDecimals,
|
||||
data: v.data.avgPing,
|
||||
color: v.colors.avgPing
|
||||
},
|
||||
maxPing: {
|
||||
name: s.name.maxPing,
|
||||
type: s.type.spline,
|
||||
tooltip: s.tooltip.zeroDecimals,
|
||||
data: v.data.maxPing,
|
||||
color: v.colors.maxPing
|
||||
},
|
||||
minPing: {
|
||||
name: s.name.minPing,
|
||||
type: s.type.spline,
|
||||
tooltip: s.tooltip.zeroDecimals,
|
||||
data: v.data.minPing,
|
||||
color: v.colors.minPing
|
||||
},
|
||||
uniquePlayers: {
|
||||
name: s.name.uniquePlayers,
|
||||
type: s.type.spline,
|
||||
tooltip: s.tooltip.zeroDecimals,
|
||||
data: v.data.uniquePlayers,
|
||||
color: v.colors.playersOnline
|
||||
},
|
||||
newPlayers: {
|
||||
name: s.name.newPlayers,
|
||||
type: s.type.spline,
|
||||
tooltip: s.tooltip.zeroDecimals,
|
||||
data: v.data.newPlayers,
|
||||
color: v.colors.newPlayers
|
||||
},
|
||||
tps: {
|
||||
name: s.name.tps,
|
||||
type: s.type.spline,
|
||||
@ -1315,6 +1407,11 @@
|
||||
color: v.colors.punchCard,
|
||||
data: v.data.punchCard
|
||||
},
|
||||
country: {
|
||||
color: '#4CAF50',
|
||||
name: 'Players',
|
||||
data: v.data.country
|
||||
},
|
||||
activityStack: v.data.activityStack,
|
||||
activityStackCategories: v.data.activityStackCategories
|
||||
};
|
||||
@ -1346,6 +1443,7 @@
|
||||
|
||||
// Chart draw scripts
|
||||
activityPie('activityPie', series.activityPie);
|
||||
lineChart('uniqueChart', [series.uniquePlayers, series.newPlayers]);
|
||||
stackChart('activityStackGraph', series.activityStackCategories, series.activityStack, 'Players');
|
||||
worldPie('worldPie', series.worldPie, series.worldPieDrillDown);
|
||||
playersChart('playerChartDay', series.playersOnline, 3);
|
||||
@ -1358,6 +1456,8 @@
|
||||
punchCard('punchCard', series.punchCard);
|
||||
healthGauge('healthGauge', [v.data.healthIndex]);
|
||||
onlineActivityCalendar('#calendar', v.data.calendar, v.values.firstDay);
|
||||
horizontalBarChart('countryBarChart', v.data.countryCategories, [series.country], 'Players');
|
||||
lineChart('pingGraph', [series.avgPing, series.maxPing, series.minPing]);
|
||||
${sessionTabGraphViewFunctions}
|
||||
|
||||
/**/
|
||||
|
Loading…
Reference in New Issue
Block a user