Commit 5b6a2378 authored by Sven Franck's avatar Sven Franck

fixed results graph, except for colors

parent 2a25da18
......@@ -3,14 +3,14 @@ article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,su
/* splash */
.ui-mobile-rendering > * { visibility:visible!important; /* no need */}
/*
.splash:before { width: 100%; position: absolute; top: 0; bottom: 0; left: 0; right: 0; display: block; height: 115%; z-index: 999999; background-color: white; content: "offline version initializing..."; text-align: center; color: #bbb; text-shadow: none; line-height: 150px; vertical-align: bottom; }
*/
/* webfonts
* { font-family: "Open Sans",Arial; font-size: 14.5px; } */
h1,h2,h3,h4, .ui-btn-inner{ font-weight: 400; }
/* custom layouting */
.ui-title {
color: white;
......
......@@ -45,7 +45,7 @@
</div>
</div>
<div class="ui-block-b">
<div class="ui-body ui-body-d ui-corner-all ui-shadow" style="padding:1em;">
<!--<div class="ui-body ui-body-d ui-corner-all ui-shadow" style="padding:1em;">
<div id="map_canvas_1"></div>
<p class="mapControls">
<label for="from">From</label>
......@@ -63,7 +63,7 @@
<div class="ui-li ui-li-divider ui-btn ui-bar-a ui-corner-bottom ui-btn-up-undefined"></div>
</div>
</div>
</div>
</div>-->
</div>
<script type="text/javascript" language="javascript">
......
......@@ -223,7 +223,6 @@
}
}
colorObject.series_colors = colorArray;
//add rest, too...
if (axis === "log") {
colorObject.yaxis = "yaxis";
......@@ -231,7 +230,6 @@
colorObject.yaxis = "y2axis";
}
colorObject.legend = "#ccc";
return colorObject;
},
......@@ -466,7 +464,7 @@
machine_price,
machine_py,
machine_sql,
machine_currency = "$",
machine_currency,
machine_performance_unit = "s",
opts = "",
t = getTemplate(use_template, template_library);
......@@ -484,6 +482,9 @@
// set values for table row
for (i = 0; i < response.length; i += 1) {
entry = response[i];
machine_currency = "$";
machine_price = $.fn.fauna.pricing[entry["_id"]]
if (entry["provider"] !== "") {
machine_alias = entry["provider"];
machine_img = "../img/providers/" + entry["provider"].toLowerCase() + ".png";
......@@ -507,8 +508,6 @@
if ($.fn.fauna.pricing[entry["_id"]] === 0 ||
$.fn.fauna.pricing[entry["_id"]] === undefined) {
machine_price = "n/a"
} else {
machine_price = $.fn.fauna.pricing[entry["_id"]]
}
if (machine_price === "n/a") {
machine_currency = "";
......@@ -520,6 +519,7 @@
.replace(stored_regex.re_img_path, machine_img)
.replace(stored_regex.re_percentile , roundNumber(entry["percentile"]))
.replace(stored_regex.re_comp, entry["_id"])
.replace(stored_regex.re_alias, machine_name)
.replace(stored_regex.re_price, machine_price)
.replace(stored_regex.re_currency, machine_currency)
.replace(stored_regex.re_py, machine_py)
......@@ -580,13 +580,10 @@
// create data series arrays from available info
for (i = 0; i < response.length; i += 1) {
entry = response[i];
if (entry["provider"] === "") {
series_providers.push("n/a");
} else {
if (entry["provider"] !== "") {
series_providers.push(entry["provider"]);
}
series_availability.push( roundNumber(entry["percentile"]) )
series_cost.push( entry["cost"] || 0 );
series_availability.push( roundNumber(entry["percentile"]/100) )
series_cost.push( $.fn.fauna.pricing[entry["_id"]] || entry["cost"] || 0 );
// we could jio.get, but it takes to long to create an array
// looping over matching jIO records. Only use the performance
......@@ -599,6 +596,7 @@
series_sql.push(0);
}
}
}
// override barWidth for single results
if (series_availability.length === 1) {
......@@ -630,14 +628,14 @@
.append( $('<tr><td colspan="5"><div id="graph_container_cell"></div></td></tr>') )
plotOpts = {
title: 'System Availability/Cost',
// title: 'Performance Benchmarks',
seriesDefaults:{
renderer:$.jqplot.BarRenderer,
rendererOptions:{ varyBarColor : true, barWidth: useBarWidth }
},
tickDefaults: {
syncTicks: true,
//useSeriesColor: true,
useSeriesColor: true,
autoscale: true,
alignTicks: true,
forceTickAt0: true
......@@ -645,29 +643,38 @@
axes: {
xaxis: config_xaxis,
yaxis:{
label:'Log Scale',
label:'Performance (s)',
renderer:$.jqplot.LogAxisRenderer,
// rendererOptions: { tickDistribution: "power" },
// max: 100,
// max: 1200,
// renderer: $.jqplot.CategoryAxisRenderer,
// tickSpacing: 50,
// ticks: [[0],[90],[93],[96],[99],[99.3],[99.6],[99.7],[99.8],[99.9],[100]],
// autoscale: true,
// showLabel: false
// autoscale: true
},
y2axis:{
label: 'Normal Scale',
//renderer: $.jqplot.CategoryAxisRenderer,
//autoscale:true,
label: 'Uptime (%), Cost($/h)',
// renderer: $.jqplot.CategoryAxisRenderer,
//btickSpacing: 50,
// min: 0,
// ticks: [[0],[0.05],[0.1],[0.25],[0.50],[0.990],[0.992],[0.994],[0.996],[0.998],[1.00]],
// autoscale:true,
// min: 0,
// max: 1000
}
},
highlighter: { show: false },
legend: { show: true, location: 'outsideGrid' }
legend: {
show: true,
placement: 'outsideGrid'
}
};
// y-axis - only add series, if columntoggle is checked
// needs to be set after defining object to update accordingly
// TODO: not generic, this is crap...
// TODO: not generic.. redo...
for (i = 0; i < toggle_inputs.length; i += 1) {
if (toggle_inputs[i].checked) {
switch (i) {
......@@ -681,13 +688,13 @@
// 0-5
plotSeries.push(series_py);
plotLables.push("PyStone");
series_colors.push(makeColors(series_py, "min", "norm"));
series_colors.push(makeColors(series_py, "min", "log"));
break;
case 4:
// 0-700
plotSeries.push(series_sql);
plotLables.push("SQLBench");
series_colors.push(makeColors(series_sql, "min", "norm"));
series_colors.push(makeColors(series_sql, "min", "log"));
break;
case 5:
// 0-1
......@@ -700,9 +707,9 @@
}
plotOpts.legend.labels = plotLables;
plotOpts.series = series_colors;
console.log(series_colors);
console.log(plotOpts);
// now we plot
// now we plot - only if a series is shown
if (plotSeries.length !== 0) {
plot1 = $.jqplot('graph_container_cell', plotSeries, plotOpts);
// add i18n attributes
......@@ -735,6 +742,7 @@
plot1.replot( plotOpts, { resetAxes: true });
});
}
}
);
}
);
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -10,7 +10,7 @@
"fr": "Français"
},
"show_all":"Alle anzeigen",
"found": "Gefundene Provider:",
"found": "Passende Systemkonfigurationen:",
"please_select": "Bitte wählen",
"all": "Alle anzeigen",
"criteria": "Kriterien:",
......@@ -44,7 +44,7 @@
"providers_info":"Informationen über die jeweiligen Anbieter aufrufen",
"monitoring":"Monitoring",
"monitoring_info":"Information zur Datenerhebung",
"sys_vs_cost": "Systemverfügbarkeit/Kosten"
"sys_vs_cost": "Übersicht Performance"
},
"pages": {
"titles": {
......
......@@ -10,7 +10,7 @@
"fr": "Français"
},
"show_all":"Show all",
"found": "Providers found:",
"found": "Matching configurations:",
"please_select": "Please select",
"all": "Show all",
"criteria": "Criteria:",
......@@ -41,7 +41,7 @@
"providers_info":"More information on the monitored providers",
"monitoring":"Monitoring",
"monitoring_info":"Information on how data is being gathered",
"sys_vs_cost": "System Availability/Cost"
"sys_vs_cost": "Performance Benchmark"
},
"pages": {
"titles": {
......
......@@ -10,7 +10,7 @@
"fr": "Français"
},
"show_all":"Montrer tout",
"found": "Fournisseur trouvés:",
"found": "Correspondant à la configuration:",
"please_select": "Sélectionner",
"all": "Montrer Tout",
"criteria": "Critères:",
......@@ -41,7 +41,7 @@
"providers_info":"Plus d'informations sur les fournisseurs surveillés.",
"monitoring":"Méthodologie",
"monitoring_info":"Informations sur la façon dont les données sont recueillies.",
"sys_vs_cost": "Disponibilité/Frais"
"sys_vs_cost": "Critères de Performance"
},
"pages": {
"titles": {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment