mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-07-17 14:55:25 +00:00
add calculations
This commit is contained in:
parent
61d182b986
commit
9b8a939e62
@ -26,6 +26,8 @@ export enum MetricQueryTypes {
|
|||||||
export enum Calculations {
|
export enum Calculations {
|
||||||
Percentage = "percentage",
|
Percentage = "percentage",
|
||||||
ByteToKB = "byteToKB",
|
ByteToKB = "byteToKB",
|
||||||
|
ByteToMB = "ByteToMB",
|
||||||
|
ByteToGB = "ByteToGB",
|
||||||
Apdex = "apdex",
|
Apdex = "apdex",
|
||||||
Precision = "precision",
|
Precision = "precision",
|
||||||
ConvertSeconds = "convertSeconds",
|
ConvertSeconds = "convertSeconds",
|
||||||
|
@ -324,6 +324,12 @@ export function aggregation(val: number, config: any): number | string {
|
|||||||
case Calculations.ByteToKB:
|
case Calculations.ByteToKB:
|
||||||
data = val / 1024;
|
data = val / 1024;
|
||||||
break;
|
break;
|
||||||
|
case Calculations.ByteToMB:
|
||||||
|
data = val / 1024 / 1024;
|
||||||
|
break;
|
||||||
|
case Calculations.ByteToGB:
|
||||||
|
data = val / 1024 / 1024 / 1024;
|
||||||
|
break;
|
||||||
case Calculations.Apdex:
|
case Calculations.Apdex:
|
||||||
data = val / 10000;
|
data = val / 10000;
|
||||||
break;
|
break;
|
||||||
|
@ -38,8 +38,8 @@ const msg = {
|
|||||||
health: "Health",
|
health: "Health",
|
||||||
groupName: "Group Name",
|
groupName: "Group Name",
|
||||||
topologies: "Topologies",
|
topologies: "Topologies",
|
||||||
dataPanel: "Data Panel",
|
dataPanel: "Data Plane",
|
||||||
controlPanel: "Control Panel",
|
controlPanel: "Control Plane",
|
||||||
eventList: "Event List",
|
eventList: "Event List",
|
||||||
databasePanel: "Database Panel",
|
databasePanel: "Database Panel",
|
||||||
meshServicePanel: "Service Panel",
|
meshServicePanel: "Service Panel",
|
||||||
|
@ -269,8 +269,10 @@ export const TextColors: { [key: string]: string } = {
|
|||||||
|
|
||||||
export const CalculationOpts = [
|
export const CalculationOpts = [
|
||||||
{ label: "Percentage", value: "percentage" },
|
{ label: "Percentage", value: "percentage" },
|
||||||
{ label: "Byte to KB", value: "byteToKB" },
|
|
||||||
{ label: "Apdex", value: "apdex" },
|
{ label: "Apdex", value: "apdex" },
|
||||||
|
{ label: "Byte to KB", value: "byteToKB" },
|
||||||
|
{ label: "Byte to MB", value: "byteToMB" },
|
||||||
|
{ label: "Byte to GB", value: "byteToGB" },
|
||||||
{
|
{
|
||||||
label: "Convert milliseconds to YYYY-MM-DD HH:mm:ss",
|
label: "Convert milliseconds to YYYY-MM-DD HH:mm:ss",
|
||||||
value: "convertMilliseconds",
|
value: "convertMilliseconds",
|
||||||
|
Loading…
Reference in New Issue
Block a user