@nsshunt/stsoauth2plugin 1.0.71 → 1.0.73
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/stsoauth2plugin.mjs +318 -483
- package/dist/stsoauth2plugin.mjs.map +1 -1
- package/dist/stsoauth2plugin.umd.js +320 -484
- package/dist/stsoauth2plugin.umd.js.map +1 -1
- package/package.json +7 -11
- package/types/index.test.d.ts +1 -0
package/dist/stsoauth2plugin.mjs
CHANGED
|
@@ -42,7 +42,6 @@ import { ClientStorageFactory, ClientStorageType } from "@nsshunt/stsvueutils";
|
|
|
42
42
|
import { defineStore } from "pinia";
|
|
43
43
|
import https from "node:https";
|
|
44
44
|
import axios from "axios";
|
|
45
|
-
import debugModule from "debug";
|
|
46
45
|
import "socket.io-client";
|
|
47
46
|
import "colors";
|
|
48
47
|
const STSOAuth2ManagerPluginKey = Symbol();
|
|
@@ -5461,6 +5460,303 @@ var SubscriptionTopic = /* @__PURE__ */ ((SubscriptionTopic2) => {
|
|
|
5461
5460
|
SubscriptionTopic2["LogProcessing"] = "LogProcessing";
|
|
5462
5461
|
return SubscriptionTopic2;
|
|
5463
5462
|
})(SubscriptionTopic || {});
|
|
5463
|
+
const instrumentationObservationInterval = 1e3;
|
|
5464
|
+
const instrumentationTimeWindow = 600;
|
|
5465
|
+
const consoleLogging = true;
|
|
5466
|
+
const instrumentLogging = true;
|
|
5467
|
+
const globalServiceDefinitions = {
|
|
5468
|
+
coreFieldList: [
|
|
5469
|
+
{ fieldName: "requestCount", gauge: Gauge.REQUEST_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5470
|
+
{ fieldName: "errorCount", gauge: Gauge.ERROR_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5471
|
+
{ fieldName: "retryCount", gauge: Gauge.RETRY_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5472
|
+
{ fieldName: "authenticationCount", gauge: Gauge.AUTHENTICATION_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5473
|
+
{ fieldName: "authenticationErrorCount", gauge: Gauge.AUTHENTICATION_ERROR_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5474
|
+
{ fieldName: "authenticationRetryCount", gauge: Gauge.AUTHENTICATION_RETRY_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5475
|
+
{ fieldName: "velocity", gauge: Gauge.VELOCITY_GAUGE, instrumentProperty: "va", dataType: "number", influxdbDataType: "floatField", gaugeType: GaugeTypes.INSTRUMENT_VELOCITY },
|
|
5476
|
+
{
|
|
5477
|
+
fieldName: "activeRequestCount",
|
|
5478
|
+
gauge: Gauge.ACTIVE_REQUEST_GAUGE,
|
|
5479
|
+
instrumentProperty: "val",
|
|
5480
|
+
dataType: "number",
|
|
5481
|
+
timeSeriesIndex: true,
|
|
5482
|
+
quantile: true,
|
|
5483
|
+
influxdbDataType: "intField",
|
|
5484
|
+
gaugeType: GaugeTypes.INSTRUMENT_GAUGE,
|
|
5485
|
+
instrumentOptions: {
|
|
5486
|
+
interval: instrumentationObservationInterval,
|
|
5487
|
+
sampleSize: instrumentationTimeWindow
|
|
5488
|
+
}
|
|
5489
|
+
},
|
|
5490
|
+
{ fieldName: "coreCount", gauge: Gauge.CORE_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5491
|
+
{ fieldName: "rx", gauge: Gauge.NETWORK_RX_GAUGE, instrumentProperty: "va", dataType: "number", influxdbDataType: "floatField", gaugeType: GaugeTypes.INSTRUMENT_VELOCITY },
|
|
5492
|
+
{ fieldName: "tx", gauge: Gauge.NETWORK_TX_GAUGE, instrumentProperty: "va", dataType: "number", influxdbDataType: "floatField", gaugeType: GaugeTypes.INSTRUMENT_VELOCITY },
|
|
5493
|
+
{ fieldName: "timer", gauge: Gauge.TIMER_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "floatField", gaugeType: GaugeTypes.INSTRUMENT_TIMER },
|
|
5494
|
+
{
|
|
5495
|
+
fieldName: "duration",
|
|
5496
|
+
gauge: Gauge.DURATION_GAUGE,
|
|
5497
|
+
instrumentProperty: "val",
|
|
5498
|
+
dataType: "number",
|
|
5499
|
+
timeSeriesIndex: true,
|
|
5500
|
+
quantile: true,
|
|
5501
|
+
influxdbDataType: "floatField",
|
|
5502
|
+
gaugeType: GaugeTypes.INSTRUMENT_GAUGE,
|
|
5503
|
+
instrumentOptions: {
|
|
5504
|
+
interval: instrumentationObservationInterval,
|
|
5505
|
+
sampleSize: instrumentationTimeWindow
|
|
5506
|
+
},
|
|
5507
|
+
histo: [
|
|
5508
|
+
{ label: "B10", bucketLimit: 10 },
|
|
5509
|
+
{ label: "B20", bucketLimit: 20 },
|
|
5510
|
+
{ label: "B50", bucketLimit: 50 },
|
|
5511
|
+
{ label: "B100", bucketLimit: 100 },
|
|
5512
|
+
{ label: "B1000", bucketLimit: 1e3 },
|
|
5513
|
+
{ label: "B50000", bucketLimit: 5e4 },
|
|
5514
|
+
{ label: "BInfinity", bucketLimit: -1 }
|
|
5515
|
+
],
|
|
5516
|
+
histoGauge: Gauge.DURATION_HISTOGRAM_GAUGE
|
|
5517
|
+
},
|
|
5518
|
+
{
|
|
5519
|
+
fieldName: "latency",
|
|
5520
|
+
gauge: Gauge.LATENCY_GAUGE,
|
|
5521
|
+
instrumentProperty: "val",
|
|
5522
|
+
dataType: "number",
|
|
5523
|
+
timeSeriesIndex: true,
|
|
5524
|
+
quantile: true,
|
|
5525
|
+
influxdbDataType: "floatField",
|
|
5526
|
+
gaugeType: GaugeTypes.INSTRUMENT_GAUGE,
|
|
5527
|
+
instrumentOptions: {
|
|
5528
|
+
interval: instrumentationObservationInterval,
|
|
5529
|
+
sampleSize: instrumentationTimeWindow
|
|
5530
|
+
},
|
|
5531
|
+
histo: [
|
|
5532
|
+
{ label: "B10", bucketLimit: 10 },
|
|
5533
|
+
{ label: "B20", bucketLimit: 20 },
|
|
5534
|
+
{ label: "B50", bucketLimit: 50 },
|
|
5535
|
+
{ label: "B100", bucketLimit: 100 },
|
|
5536
|
+
{ label: "B1000", bucketLimit: 1e3 },
|
|
5537
|
+
{ label: "B50000", bucketLimit: 5e4 },
|
|
5538
|
+
{ label: "BInfinity", bucketLimit: -1 }
|
|
5539
|
+
],
|
|
5540
|
+
histoGauge: Gauge.LATENCY_HISTOGRAM_GAUGE
|
|
5541
|
+
}
|
|
5542
|
+
],
|
|
5543
|
+
logFieldList: [
|
|
5544
|
+
{
|
|
5545
|
+
fieldName: "log",
|
|
5546
|
+
gauge: Gauge.LOGGER,
|
|
5547
|
+
instrumentProperty: "val",
|
|
5548
|
+
dataType: "string",
|
|
5549
|
+
timeSeriesIndex: false,
|
|
5550
|
+
quantile: false,
|
|
5551
|
+
influxdbDataType: "stringField",
|
|
5552
|
+
gaugeType: GaugeTypes.INSTRUMENT_LOG,
|
|
5553
|
+
instrumentOptions: {
|
|
5554
|
+
consoleLogging,
|
|
5555
|
+
instrumentLogging
|
|
5556
|
+
}
|
|
5557
|
+
}
|
|
5558
|
+
],
|
|
5559
|
+
services: {
|
|
5560
|
+
["service"]: {
|
|
5561
|
+
influxDBContextTags: [
|
|
5562
|
+
"serviceId",
|
|
5563
|
+
"serviceName",
|
|
5564
|
+
"serviceVersion",
|
|
5565
|
+
"serviceInstanceId",
|
|
5566
|
+
"serviceInstanceProcessId",
|
|
5567
|
+
"hostName",
|
|
5568
|
+
"pid",
|
|
5569
|
+
"ppid"
|
|
5570
|
+
],
|
|
5571
|
+
redisIndexPrefixDefinitions: {
|
|
5572
|
+
timeSeriesIndex: "idx:serviceIndexTimeSeries",
|
|
5573
|
+
timeSeriesPrefix: "/serviceTimeSeries:",
|
|
5574
|
+
instantIndex: "idx:serviceIndexInstant",
|
|
5575
|
+
instantPrefix: "/serviceInstant:"
|
|
5576
|
+
},
|
|
5577
|
+
fieldList: [
|
|
5578
|
+
{
|
|
5579
|
+
fieldName: "cpu",
|
|
5580
|
+
gauge: Gauge.CPU_LOAD_GAUGE,
|
|
5581
|
+
instrumentProperty: "val",
|
|
5582
|
+
dataType: "number",
|
|
5583
|
+
timeSeriesIndex: true,
|
|
5584
|
+
quantile: true,
|
|
5585
|
+
influxdbDataType: "floatField",
|
|
5586
|
+
gaugeType: GaugeTypes.INSTRUMENT_GAUGE,
|
|
5587
|
+
instrumentOptions: {
|
|
5588
|
+
interval: instrumentationObservationInterval,
|
|
5589
|
+
sampleSize: instrumentationTimeWindow
|
|
5590
|
+
}
|
|
5591
|
+
},
|
|
5592
|
+
{
|
|
5593
|
+
fieldName: "connectionCount",
|
|
5594
|
+
gauge: Gauge.CONNECTION_COUNT_GAUGE,
|
|
5595
|
+
instrumentProperty: "val",
|
|
5596
|
+
dataType: "number",
|
|
5597
|
+
timeSeriesIndex: true,
|
|
5598
|
+
quantile: true,
|
|
5599
|
+
influxdbDataType: "intField",
|
|
5600
|
+
gaugeType: GaugeTypes.INSTRUMENT_GAUGE,
|
|
5601
|
+
instrumentOptions: {
|
|
5602
|
+
interval: instrumentationObservationInterval,
|
|
5603
|
+
sampleSize: instrumentationTimeWindow
|
|
5604
|
+
}
|
|
5605
|
+
},
|
|
5606
|
+
{ fieldName: "connectionPoolCount", gauge: Gauge.CONNECTION_POOL_TOTAL_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5607
|
+
{ fieldName: "connectionIdleCount", gauge: Gauge.CONNECTION_POOL_IDLE_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5608
|
+
{ fieldName: "connectionWaitingCount", gauge: Gauge.CONNECTION_POOL_WAITING_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5609
|
+
{ fieldName: "systemcpu", gauge: Gauge.CPU_SYSTEM_LOAD_GAUGE, instrumentProperty: "val", dataType: "number", timeSeriesIndex: true, quantile: true, influxdbDataType: "floatField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5610
|
+
{
|
|
5611
|
+
fieldName: "memory",
|
|
5612
|
+
gauge: Gauge.OBJECT_GAUGE,
|
|
5613
|
+
instrumentProperty: "val",
|
|
5614
|
+
dataType: "JSON",
|
|
5615
|
+
influxdbDataType: "stringField",
|
|
5616
|
+
gaugeType: GaugeTypes.INSTRUMENT_OBJECT,
|
|
5617
|
+
instrumentOptions: {
|
|
5618
|
+
label: "InstrumentObjectMaster"
|
|
5619
|
+
}
|
|
5620
|
+
}
|
|
5621
|
+
],
|
|
5622
|
+
GetPathFromContext(context) {
|
|
5623
|
+
const { serviceId, serviceInstanceId, serviceInstanceProcessId } = context;
|
|
5624
|
+
return `/${serviceId}/${serviceInstanceId}/${serviceInstanceProcessId}`;
|
|
5625
|
+
},
|
|
5626
|
+
redisQueryFilters: {
|
|
5627
|
+
level1ContextField: "serviceType",
|
|
5628
|
+
level2ContextField: "appid",
|
|
5629
|
+
level3ContextField: "appinstanceid"
|
|
5630
|
+
},
|
|
5631
|
+
subscriptionTopics: [
|
|
5632
|
+
{
|
|
5633
|
+
subscriptionTopic: SubscriptionTopic.AllServicesCombined,
|
|
5634
|
+
route: "/metrics"
|
|
5635
|
+
},
|
|
5636
|
+
{
|
|
5637
|
+
subscriptionTopic: SubscriptionTopic.Services,
|
|
5638
|
+
route: "/metrics/services"
|
|
5639
|
+
},
|
|
5640
|
+
{
|
|
5641
|
+
subscriptionTopic: SubscriptionTopic.ServiceInstances,
|
|
5642
|
+
route: "/metrics/services/:key"
|
|
5643
|
+
},
|
|
5644
|
+
{
|
|
5645
|
+
subscriptionTopic: SubscriptionTopic.ServiceInstance,
|
|
5646
|
+
route: "/metrics/services/:key/:subkey"
|
|
5647
|
+
}
|
|
5648
|
+
]
|
|
5649
|
+
},
|
|
5650
|
+
["agent"]: {
|
|
5651
|
+
influxDBContextTags: [
|
|
5652
|
+
"id",
|
|
5653
|
+
"hostName",
|
|
5654
|
+
"agentName",
|
|
5655
|
+
"threadId",
|
|
5656
|
+
"asyncRunnerId"
|
|
5657
|
+
],
|
|
5658
|
+
redisIndexPrefixDefinitions: {
|
|
5659
|
+
timeSeriesIndex: "idx:agentIndexTimeSeries",
|
|
5660
|
+
timeSeriesPrefix: "/agentTimeSeries:",
|
|
5661
|
+
instantIndex: "idx:agentIndexInstant",
|
|
5662
|
+
instantPrefix: "/agentInstant:"
|
|
5663
|
+
},
|
|
5664
|
+
fieldList: [
|
|
5665
|
+
{ fieldName: "childCount", gauge: Gauge.CHILD_COUNT, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE }
|
|
5666
|
+
],
|
|
5667
|
+
//@@ need type declare in appframework ?? agent does not use appframework ... perhaps stspublisher
|
|
5668
|
+
GetPathFromContext(context) {
|
|
5669
|
+
const { agentName, threadId, asyncRunnerId } = context;
|
|
5670
|
+
return `/${agentName}/${threadId}/${asyncRunnerId}`;
|
|
5671
|
+
},
|
|
5672
|
+
redisQueryFilters: {
|
|
5673
|
+
level1ContextField: "serviceType",
|
|
5674
|
+
level2ContextField: "appid",
|
|
5675
|
+
//@@ this should be named something else
|
|
5676
|
+
level3ContextField: "appinstanceid"
|
|
5677
|
+
//@@ this should be named something else
|
|
5678
|
+
},
|
|
5679
|
+
subscriptionTopics: [
|
|
5680
|
+
{
|
|
5681
|
+
subscriptionTopic: SubscriptionTopic.AllAgentsCombined,
|
|
5682
|
+
route: "/metrics"
|
|
5683
|
+
},
|
|
5684
|
+
{
|
|
5685
|
+
subscriptionTopic: SubscriptionTopic.Agents,
|
|
5686
|
+
route: "/metrics/agents"
|
|
5687
|
+
},
|
|
5688
|
+
{
|
|
5689
|
+
subscriptionTopic: SubscriptionTopic.AgentWorkers,
|
|
5690
|
+
route: "/metrics/agents/:key"
|
|
5691
|
+
},
|
|
5692
|
+
{
|
|
5693
|
+
subscriptionTopic: SubscriptionTopic.AgentWorker,
|
|
5694
|
+
route: "/metrics/agents/:key/:subkey"
|
|
5695
|
+
}
|
|
5696
|
+
]
|
|
5697
|
+
},
|
|
5698
|
+
["lambda"]: {
|
|
5699
|
+
influxDBContextTags: [
|
|
5700
|
+
"technology",
|
|
5701
|
+
"subTechnology",
|
|
5702
|
+
"lambdaFunctionName",
|
|
5703
|
+
"lambdaInstance",
|
|
5704
|
+
"hostName",
|
|
5705
|
+
"processId",
|
|
5706
|
+
"parentProcessId",
|
|
5707
|
+
"useCase",
|
|
5708
|
+
"pattern"
|
|
5709
|
+
],
|
|
5710
|
+
redisIndexPrefixDefinitions: {
|
|
5711
|
+
timeSeriesIndex: "idx:lambdaIndexTimeSeries",
|
|
5712
|
+
timeSeriesPrefix: "/lambdaTimeSeries:",
|
|
5713
|
+
instantIndex: "idx:lambdaIndexInstant",
|
|
5714
|
+
instantPrefix: "/lambdaInstant:"
|
|
5715
|
+
},
|
|
5716
|
+
fieldList: [
|
|
5717
|
+
{ fieldName: "cpu", gauge: Gauge.CPU_LOAD_GAUGE, instrumentProperty: "val", dataType: "number", timeSeriesIndex: true, quantile: true, influxdbDataType: "floatField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5718
|
+
{ fieldName: "connectionCount", gauge: Gauge.CONNECTION_COUNT_GAUGE, instrumentProperty: "val", dataType: "number", timeSeriesIndex: true, quantile: true, influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5719
|
+
{ fieldName: "connectionPoolCount", gauge: Gauge.CONNECTION_POOL_TOTAL_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5720
|
+
{ fieldName: "connectionIdleCount", gauge: Gauge.CONNECTION_POOL_IDLE_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5721
|
+
{ fieldName: "connectionWaitingCount", gauge: Gauge.CONNECTION_POOL_WAITING_GAUGE, instrumentProperty: "val", dataType: "number", influxdbDataType: "intField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5722
|
+
{ fieldName: "systemcpu", gauge: Gauge.CPU_SYSTEM_LOAD_GAUGE, instrumentProperty: "val", dataType: "number", timeSeriesIndex: true, quantile: true, influxdbDataType: "floatField", gaugeType: GaugeTypes.INSTRUMENT_GAUGE },
|
|
5723
|
+
{ fieldName: "memory", gauge: Gauge.OBJECT_GAUGE, instrumentProperty: "val", dataType: "JSON", influxdbDataType: "stringField", gaugeType: GaugeTypes.INSTRUMENT_OBJECT }
|
|
5724
|
+
],
|
|
5725
|
+
//@@ need type declare in appframework
|
|
5726
|
+
GetPathFromContext(context) {
|
|
5727
|
+
const { technology, subTechnology, lambdaInstance } = context;
|
|
5728
|
+
return `/${technology}/${subTechnology}/${lambdaInstance}`;
|
|
5729
|
+
},
|
|
5730
|
+
redisQueryFilters: {
|
|
5731
|
+
level1ContextField: "serviceType",
|
|
5732
|
+
level2ContextField: "technology",
|
|
5733
|
+
level3ContextField: "subTechnology"
|
|
5734
|
+
},
|
|
5735
|
+
subscriptionTopics: [
|
|
5736
|
+
{
|
|
5737
|
+
subscriptionTopic: SubscriptionTopic.AllLambdasCombined,
|
|
5738
|
+
// uicontrollerlanding
|
|
5739
|
+
route: "/metrics"
|
|
5740
|
+
},
|
|
5741
|
+
{
|
|
5742
|
+
subscriptionTopic: SubscriptionTopic.LambdaTechnologies,
|
|
5743
|
+
// uicontrollerlambda
|
|
5744
|
+
route: "/metrics/lambdas"
|
|
5745
|
+
},
|
|
5746
|
+
{
|
|
5747
|
+
subscriptionTopic: SubscriptionTopic.LambdaSubTechnologies,
|
|
5748
|
+
// uicontrollerlambdasubtechnologies
|
|
5749
|
+
route: "/metrics/lambdas/:key"
|
|
5750
|
+
},
|
|
5751
|
+
{
|
|
5752
|
+
subscriptionTopic: SubscriptionTopic.LambdaSubTechnologiesInstance,
|
|
5753
|
+
// uicontrollerlambdasubtechnologiesinstance
|
|
5754
|
+
route: "/metrics/lambdas/:key/:subkey"
|
|
5755
|
+
}
|
|
5756
|
+
]
|
|
5757
|
+
}
|
|
5758
|
+
}
|
|
5759
|
+
};
|
|
5464
5760
|
const _ObservabilityModelUtils = class _ObservabilityModelUtils2 {
|
|
5465
5761
|
static GetModelNode(data) {
|
|
5466
5762
|
const fixedSize = 2;
|
|
@@ -5559,6 +5855,24 @@ const _ObservabilityModelUtils = class _ObservabilityModelUtils2 {
|
|
|
5559
5855
|
};
|
|
5560
5856
|
}
|
|
5561
5857
|
}
|
|
5858
|
+
static GetModelData(serviceType, model, data, parseLog) {
|
|
5859
|
+
const fieldList = [
|
|
5860
|
+
...globalServiceDefinitions.coreFieldList,
|
|
5861
|
+
...globalServiceDefinitions.services[serviceType].fieldList
|
|
5862
|
+
];
|
|
5863
|
+
fieldList.forEach((field) => {
|
|
5864
|
+
if (field.quantile) {
|
|
5865
|
+
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, field.gauge, field.fieldName, `${field.fieldName}_quantile`);
|
|
5866
|
+
} else if (field.gaugeType.localeCompare(GaugeTypes.INSTRUMENT_OBJECT) === 0) {
|
|
5867
|
+
_ObservabilityModelUtils2.ParseModelNodeObject(model, data, parseLog, field.gauge, field.fieldName);
|
|
5868
|
+
} else {
|
|
5869
|
+
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, field.gauge, field.fieldName);
|
|
5870
|
+
}
|
|
5871
|
+
if (field.histo) {
|
|
5872
|
+
_ObservabilityModelUtils2.ParseModelNodeHisto(model, data, parseLog, field.histoGauge, `${field.fieldName}_histo`);
|
|
5873
|
+
}
|
|
5874
|
+
});
|
|
5875
|
+
}
|
|
5562
5876
|
static GetModelForService(id, data, subscribeToKafka, logger) {
|
|
5563
5877
|
try {
|
|
5564
5878
|
const parseLog = [];
|
|
@@ -5566,29 +5880,7 @@ const _ObservabilityModelUtils = class _ObservabilityModelUtils2 {
|
|
|
5566
5880
|
id,
|
|
5567
5881
|
instruments: {}
|
|
5568
5882
|
};
|
|
5569
|
-
|
|
5570
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.ERROR_COUNT_GAUGE, "errorCount");
|
|
5571
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.RETRY_COUNT_GAUGE, "retryCount");
|
|
5572
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_COUNT_GAUGE, "authenticationCount");
|
|
5573
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_ERROR_COUNT_GAUGE, "authenticationErrorCount");
|
|
5574
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_RETRY_COUNT_GAUGE, "authenticationRetryCount");
|
|
5575
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.VELOCITY_GAUGE, "velocity");
|
|
5576
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.ACTIVE_REQUEST_GAUGE, "activeRequestCount");
|
|
5577
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_COUNT_GAUGE, "connectionCount");
|
|
5578
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_POOL_TOTAL_GAUGE, "connectionPoolCount");
|
|
5579
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_POOL_IDLE_GAUGE, "connectionIdleCount");
|
|
5580
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_POOL_WAITING_GAUGE, "connectionWaitingCount");
|
|
5581
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CORE_COUNT_GAUGE, "coreCount");
|
|
5582
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.TIMER_GAUGE, "timer");
|
|
5583
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.NETWORK_RX_GAUGE, "rx");
|
|
5584
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.NETWORK_TX_GAUGE, "tx");
|
|
5585
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.CPU_LOAD_GAUGE, "cpu", "cpu_quantile");
|
|
5586
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.CPU_SYSTEM_LOAD_GAUGE, "systemcpu", "systemcpu_quantile");
|
|
5587
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.DURATION_GAUGE, "duration", "duration_quantile");
|
|
5588
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.LATENCY_GAUGE, "latency", "latency_quantile");
|
|
5589
|
-
_ObservabilityModelUtils2.ParseModelNodeHisto(model, data, parseLog, Gauge.DURATION_HISTOGRAM_GAUGE, "duration_histo");
|
|
5590
|
-
_ObservabilityModelUtils2.ParseModelNodeHisto(model, data, parseLog, Gauge.LATENCY_HISTOGRAM_GAUGE, "latency_histo");
|
|
5591
|
-
_ObservabilityModelUtils2.ParseModelNodeObject(model, data, parseLog, Gauge.OBJECT_GAUGE, "memory");
|
|
5883
|
+
this.GetModelData("service", model, data, parseLog);
|
|
5592
5884
|
if (!subscribeToKafka) {
|
|
5593
5885
|
model.instruments[Gauge.LOGGER] = _ObservabilityModelUtils2.GetModelNodeRawStringArray(data["logMessages"]);
|
|
5594
5886
|
}
|
|
@@ -5607,29 +5899,7 @@ const _ObservabilityModelUtils = class _ObservabilityModelUtils2 {
|
|
|
5607
5899
|
id,
|
|
5608
5900
|
instruments: {}
|
|
5609
5901
|
};
|
|
5610
|
-
|
|
5611
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.ERROR_COUNT_GAUGE, "errorCount");
|
|
5612
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.RETRY_COUNT_GAUGE, "retryCount");
|
|
5613
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_COUNT_GAUGE, "authenticationCount");
|
|
5614
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_ERROR_COUNT_GAUGE, "authenticationErrorCount");
|
|
5615
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_RETRY_COUNT_GAUGE, "authenticationRetryCount");
|
|
5616
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.VELOCITY_GAUGE, "velocity");
|
|
5617
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.ACTIVE_REQUEST_GAUGE, "activeRequestCount");
|
|
5618
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_COUNT_GAUGE, "connectionCount");
|
|
5619
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_POOL_TOTAL_GAUGE, "connectionPoolCount");
|
|
5620
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_POOL_IDLE_GAUGE, "connectionIdleCount");
|
|
5621
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CONNECTION_POOL_WAITING_GAUGE, "connectionWaitingCount");
|
|
5622
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CORE_COUNT_GAUGE, "coreCount");
|
|
5623
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.TIMER_GAUGE, "timer");
|
|
5624
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.NETWORK_RX_GAUGE, "rx");
|
|
5625
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.NETWORK_TX_GAUGE, "tx");
|
|
5626
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.CPU_LOAD_GAUGE, "cpu", "cpu_quantile");
|
|
5627
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.CPU_SYSTEM_LOAD_GAUGE, "systemcpu", "systemcpu_quantile");
|
|
5628
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.DURATION_GAUGE, "duration", "duration_quantile");
|
|
5629
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.LATENCY_GAUGE, "latency", "latency_quantile");
|
|
5630
|
-
_ObservabilityModelUtils2.ParseModelNodeHisto(model, data, parseLog, Gauge.DURATION_HISTOGRAM_GAUGE, "duration_histo");
|
|
5631
|
-
_ObservabilityModelUtils2.ParseModelNodeHisto(model, data, parseLog, Gauge.LATENCY_HISTOGRAM_GAUGE, "latency_histo");
|
|
5632
|
-
_ObservabilityModelUtils2.ParseModelNodeObject(model, data, parseLog, Gauge.OBJECT_GAUGE, "memory");
|
|
5902
|
+
this.GetModelData("lambda", model, data, parseLog);
|
|
5633
5903
|
if (!subscribeToKafka) {
|
|
5634
5904
|
model.instruments[Gauge.LOGGER] = _ObservabilityModelUtils2.GetModelNodeRawStringArray(data["logMessages"]);
|
|
5635
5905
|
}
|
|
@@ -5651,22 +5921,7 @@ const _ObservabilityModelUtils = class _ObservabilityModelUtils2 {
|
|
|
5651
5921
|
id,
|
|
5652
5922
|
instruments: {}
|
|
5653
5923
|
};
|
|
5654
|
-
|
|
5655
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.ERROR_COUNT_GAUGE, "errorCount");
|
|
5656
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.RETRY_COUNT_GAUGE, "retryCount");
|
|
5657
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_COUNT_GAUGE, "authenticationCount");
|
|
5658
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_ERROR_COUNT_GAUGE, "authenticationErrorCount");
|
|
5659
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.AUTHENTICATION_RETRY_COUNT_GAUGE, "authenticationRetryCount");
|
|
5660
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.VELOCITY_GAUGE, "velocity");
|
|
5661
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.CORE_COUNT_GAUGE, "coreCount");
|
|
5662
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.TIMER_GAUGE, "timer");
|
|
5663
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.ACTIVE_REQUEST_GAUGE, "activeRequestCount");
|
|
5664
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.NETWORK_RX_GAUGE, "rx");
|
|
5665
|
-
_ObservabilityModelUtils2.ParseModelNode(model, data, parseLog, Gauge.NETWORK_TX_GAUGE, "tx");
|
|
5666
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.DURATION_GAUGE, "duration", "duration_quantile");
|
|
5667
|
-
_ObservabilityModelUtils2.ParseModelNodeWithQuantile(model, data, parseLog, Gauge.LATENCY_GAUGE, "latency", "latency_quantile");
|
|
5668
|
-
_ObservabilityModelUtils2.ParseModelNodeHisto(model, data, parseLog, Gauge.DURATION_HISTOGRAM_GAUGE, "duration_histo");
|
|
5669
|
-
_ObservabilityModelUtils2.ParseModelNodeHisto(model, data, parseLog, Gauge.LATENCY_HISTOGRAM_GAUGE, "latency_histo");
|
|
5924
|
+
this.GetModelData("agent", model, data, parseLog);
|
|
5670
5925
|
if (!subscribeToKafka) {
|
|
5671
5926
|
model.instruments[Gauge.LOGGER] = _ObservabilityModelUtils2.GetModelNodeRawStringArray(data["logMessages"]);
|
|
5672
5927
|
}
|
|
@@ -5715,431 +5970,11 @@ __publicField2(_ObservabilityModelUtils, "ParseModelNodeObject", (model, data, p
|
|
|
5715
5970
|
model.instruments[gaugeName] = _ObservabilityModelUtils.GetModelNodeObject({});
|
|
5716
5971
|
}
|
|
5717
5972
|
});
|
|
5718
|
-
debugModule(`proc:${process.pid}`);
|
|
5719
5973
|
const byteToHex = [];
|
|
5720
5974
|
for (let i = 0; i < 256; ++i) {
|
|
5721
5975
|
byteToHex.push((i + 256).toString(16).slice(1));
|
|
5722
5976
|
}
|
|
5723
5977
|
typeof crypto !== "undefined" && crypto.randomUUID && crypto.randomUUID.bind(crypto);
|
|
5724
|
-
({
|
|
5725
|
-
coreFieldList: [
|
|
5726
|
-
{
|
|
5727
|
-
fieldName: "requestCount",
|
|
5728
|
-
gauge: Gauge.REQUEST_COUNT_GAUGE,
|
|
5729
|
-
instrumentProperty: "val",
|
|
5730
|
-
dataType: "number",
|
|
5731
|
-
influxdbDataType: "intField"
|
|
5732
|
-
/* intField */
|
|
5733
|
-
},
|
|
5734
|
-
{
|
|
5735
|
-
fieldName: "errorCount",
|
|
5736
|
-
gauge: Gauge.ERROR_COUNT_GAUGE,
|
|
5737
|
-
instrumentProperty: "val",
|
|
5738
|
-
dataType: "number",
|
|
5739
|
-
influxdbDataType: "intField"
|
|
5740
|
-
/* intField */
|
|
5741
|
-
},
|
|
5742
|
-
{
|
|
5743
|
-
fieldName: "retryCount",
|
|
5744
|
-
gauge: Gauge.RETRY_COUNT_GAUGE,
|
|
5745
|
-
instrumentProperty: "val",
|
|
5746
|
-
dataType: "number",
|
|
5747
|
-
influxdbDataType: "intField"
|
|
5748
|
-
/* intField */
|
|
5749
|
-
},
|
|
5750
|
-
{
|
|
5751
|
-
fieldName: "authenticationCount",
|
|
5752
|
-
gauge: Gauge.AUTHENTICATION_COUNT_GAUGE,
|
|
5753
|
-
instrumentProperty: "val",
|
|
5754
|
-
dataType: "number",
|
|
5755
|
-
influxdbDataType: "intField"
|
|
5756
|
-
/* intField */
|
|
5757
|
-
},
|
|
5758
|
-
{
|
|
5759
|
-
fieldName: "authenticationErrorCount",
|
|
5760
|
-
gauge: Gauge.AUTHENTICATION_ERROR_COUNT_GAUGE,
|
|
5761
|
-
instrumentProperty: "val",
|
|
5762
|
-
dataType: "number",
|
|
5763
|
-
influxdbDataType: "intField"
|
|
5764
|
-
/* intField */
|
|
5765
|
-
},
|
|
5766
|
-
{
|
|
5767
|
-
fieldName: "authenticationRetryCount",
|
|
5768
|
-
gauge: Gauge.AUTHENTICATION_RETRY_COUNT_GAUGE,
|
|
5769
|
-
instrumentProperty: "val",
|
|
5770
|
-
dataType: "number",
|
|
5771
|
-
influxdbDataType: "intField"
|
|
5772
|
-
/* intField */
|
|
5773
|
-
},
|
|
5774
|
-
{
|
|
5775
|
-
fieldName: "velocity",
|
|
5776
|
-
gauge: Gauge.VELOCITY_GAUGE,
|
|
5777
|
-
instrumentProperty: "va",
|
|
5778
|
-
dataType: "number",
|
|
5779
|
-
influxdbDataType: "floatField"
|
|
5780
|
-
/* floatField */
|
|
5781
|
-
},
|
|
5782
|
-
{
|
|
5783
|
-
fieldName: "activeRequestCount",
|
|
5784
|
-
gauge: Gauge.ACTIVE_REQUEST_GAUGE,
|
|
5785
|
-
instrumentProperty: "val",
|
|
5786
|
-
dataType: "number",
|
|
5787
|
-
timeSeriesIndex: true,
|
|
5788
|
-
quantile: true,
|
|
5789
|
-
influxdbDataType: "intField"
|
|
5790
|
-
/* intField */
|
|
5791
|
-
},
|
|
5792
|
-
{
|
|
5793
|
-
fieldName: "coreCount",
|
|
5794
|
-
gauge: Gauge.CORE_COUNT_GAUGE,
|
|
5795
|
-
instrumentProperty: "val",
|
|
5796
|
-
dataType: "number",
|
|
5797
|
-
influxdbDataType: "intField"
|
|
5798
|
-
/* intField */
|
|
5799
|
-
},
|
|
5800
|
-
{
|
|
5801
|
-
fieldName: "rx",
|
|
5802
|
-
gauge: Gauge.NETWORK_RX_GAUGE,
|
|
5803
|
-
instrumentProperty: "va",
|
|
5804
|
-
dataType: "number",
|
|
5805
|
-
influxdbDataType: "floatField"
|
|
5806
|
-
/* floatField */
|
|
5807
|
-
},
|
|
5808
|
-
{
|
|
5809
|
-
fieldName: "tx",
|
|
5810
|
-
gauge: Gauge.NETWORK_TX_GAUGE,
|
|
5811
|
-
instrumentProperty: "va",
|
|
5812
|
-
dataType: "number",
|
|
5813
|
-
influxdbDataType: "floatField"
|
|
5814
|
-
/* floatField */
|
|
5815
|
-
},
|
|
5816
|
-
{
|
|
5817
|
-
fieldName: "timer",
|
|
5818
|
-
gauge: Gauge.TIMER_GAUGE,
|
|
5819
|
-
instrumentProperty: "val",
|
|
5820
|
-
dataType: "number",
|
|
5821
|
-
influxdbDataType: "floatField"
|
|
5822
|
-
/* floatField */
|
|
5823
|
-
},
|
|
5824
|
-
{
|
|
5825
|
-
fieldName: "duration",
|
|
5826
|
-
gauge: Gauge.DURATION_GAUGE,
|
|
5827
|
-
instrumentProperty: "val",
|
|
5828
|
-
dataType: "number",
|
|
5829
|
-
timeSeriesIndex: true,
|
|
5830
|
-
quantile: true,
|
|
5831
|
-
influxdbDataType: "floatField",
|
|
5832
|
-
histo: [
|
|
5833
|
-
{ label: "B10", bucketLimit: 10 },
|
|
5834
|
-
{ label: "B20", bucketLimit: 20 },
|
|
5835
|
-
{ label: "B50", bucketLimit: 50 },
|
|
5836
|
-
{ label: "B100", bucketLimit: 100 },
|
|
5837
|
-
{ label: "B1000", bucketLimit: 1e3 },
|
|
5838
|
-
{ label: "B50000", bucketLimit: 5e4 },
|
|
5839
|
-
{ label: "BInfinity", bucketLimit: -1 }
|
|
5840
|
-
]
|
|
5841
|
-
},
|
|
5842
|
-
{
|
|
5843
|
-
fieldName: "latency",
|
|
5844
|
-
gauge: Gauge.LATENCY_GAUGE,
|
|
5845
|
-
instrumentProperty: "val",
|
|
5846
|
-
dataType: "number",
|
|
5847
|
-
timeSeriesIndex: true,
|
|
5848
|
-
quantile: true,
|
|
5849
|
-
influxdbDataType: "floatField",
|
|
5850
|
-
histo: [
|
|
5851
|
-
{ label: "B10", bucketLimit: 10 },
|
|
5852
|
-
{ label: "B20", bucketLimit: 20 },
|
|
5853
|
-
{ label: "B50", bucketLimit: 50 },
|
|
5854
|
-
{ label: "B100", bucketLimit: 100 },
|
|
5855
|
-
{ label: "B1000", bucketLimit: 1e3 },
|
|
5856
|
-
{ label: "B50000", bucketLimit: 5e4 },
|
|
5857
|
-
{ label: "BInfinity", bucketLimit: -1 }
|
|
5858
|
-
]
|
|
5859
|
-
}
|
|
5860
|
-
],
|
|
5861
|
-
services: {
|
|
5862
|
-
["service"]: {
|
|
5863
|
-
influxDBContextTags: [
|
|
5864
|
-
"serviceId",
|
|
5865
|
-
"serviceName",
|
|
5866
|
-
"serviceVersion",
|
|
5867
|
-
"serviceInstanceId",
|
|
5868
|
-
"serviceInstanceProcessId",
|
|
5869
|
-
"hostName",
|
|
5870
|
-
"pid",
|
|
5871
|
-
"ppid"
|
|
5872
|
-
],
|
|
5873
|
-
redisIndexPrefixDefinitions: {
|
|
5874
|
-
timeSeriesIndex: "idx:serviceIndexTimeSeries",
|
|
5875
|
-
timeSeriesPrefix: "/serviceTimeSeries:",
|
|
5876
|
-
instantIndex: "idx:serviceIndexInstant",
|
|
5877
|
-
instantPrefix: "/serviceInstant:"
|
|
5878
|
-
},
|
|
5879
|
-
fieldList: [
|
|
5880
|
-
{
|
|
5881
|
-
fieldName: "cpu",
|
|
5882
|
-
gauge: Gauge.CPU_LOAD_GAUGE,
|
|
5883
|
-
instrumentProperty: "val",
|
|
5884
|
-
dataType: "number",
|
|
5885
|
-
timeSeriesIndex: true,
|
|
5886
|
-
quantile: true,
|
|
5887
|
-
influxdbDataType: "floatField"
|
|
5888
|
-
/* floatField */
|
|
5889
|
-
},
|
|
5890
|
-
{
|
|
5891
|
-
fieldName: "connectionCount",
|
|
5892
|
-
gauge: Gauge.CONNECTION_COUNT_GAUGE,
|
|
5893
|
-
instrumentProperty: "val",
|
|
5894
|
-
dataType: "number",
|
|
5895
|
-
timeSeriesIndex: true,
|
|
5896
|
-
quantile: true,
|
|
5897
|
-
influxdbDataType: "intField"
|
|
5898
|
-
/* intField */
|
|
5899
|
-
},
|
|
5900
|
-
{
|
|
5901
|
-
fieldName: "connectionPoolCount",
|
|
5902
|
-
gauge: Gauge.CONNECTION_POOL_TOTAL_GAUGE,
|
|
5903
|
-
instrumentProperty: "val",
|
|
5904
|
-
dataType: "number",
|
|
5905
|
-
influxdbDataType: "intField"
|
|
5906
|
-
/* intField */
|
|
5907
|
-
},
|
|
5908
|
-
{
|
|
5909
|
-
fieldName: "connectionIdleCount",
|
|
5910
|
-
gauge: Gauge.CONNECTION_POOL_IDLE_GAUGE,
|
|
5911
|
-
instrumentProperty: "val",
|
|
5912
|
-
dataType: "number",
|
|
5913
|
-
influxdbDataType: "intField"
|
|
5914
|
-
/* intField */
|
|
5915
|
-
},
|
|
5916
|
-
{
|
|
5917
|
-
fieldName: "connectionWaitingCount",
|
|
5918
|
-
gauge: Gauge.CONNECTION_POOL_WAITING_GAUGE,
|
|
5919
|
-
instrumentProperty: "val",
|
|
5920
|
-
dataType: "number",
|
|
5921
|
-
influxdbDataType: "intField"
|
|
5922
|
-
/* intField */
|
|
5923
|
-
},
|
|
5924
|
-
{
|
|
5925
|
-
fieldName: "systemcpu",
|
|
5926
|
-
gauge: Gauge.CPU_SYSTEM_LOAD_GAUGE,
|
|
5927
|
-
instrumentProperty: "val",
|
|
5928
|
-
dataType: "number",
|
|
5929
|
-
timeSeriesIndex: true,
|
|
5930
|
-
quantile: true,
|
|
5931
|
-
influxdbDataType: "floatField"
|
|
5932
|
-
/* floatField */
|
|
5933
|
-
},
|
|
5934
|
-
{
|
|
5935
|
-
fieldName: "memory",
|
|
5936
|
-
gauge: Gauge.OBJECT_GAUGE,
|
|
5937
|
-
instrumentProperty: "val",
|
|
5938
|
-
dataType: "JSON",
|
|
5939
|
-
influxdbDataType: "stringField"
|
|
5940
|
-
/* stringField */
|
|
5941
|
-
}
|
|
5942
|
-
],
|
|
5943
|
-
GetPathFromContext(context) {
|
|
5944
|
-
const { serviceId, serviceInstanceId, serviceInstanceProcessId } = context;
|
|
5945
|
-
return `/${serviceId}/${serviceInstanceId}/${serviceInstanceProcessId}`;
|
|
5946
|
-
},
|
|
5947
|
-
redisQueryFilters: {
|
|
5948
|
-
level1ContextField: "serviceType",
|
|
5949
|
-
level2ContextField: "appid",
|
|
5950
|
-
level3ContextField: "appinstanceid"
|
|
5951
|
-
},
|
|
5952
|
-
subscriptionTopics: [
|
|
5953
|
-
{
|
|
5954
|
-
subscriptionTopic: SubscriptionTopic.AllServicesCombined,
|
|
5955
|
-
route: "/metrics"
|
|
5956
|
-
},
|
|
5957
|
-
{
|
|
5958
|
-
subscriptionTopic: SubscriptionTopic.Services,
|
|
5959
|
-
route: "/metrics/services"
|
|
5960
|
-
},
|
|
5961
|
-
{
|
|
5962
|
-
subscriptionTopic: SubscriptionTopic.ServiceInstances,
|
|
5963
|
-
route: "/metrics/services/:key"
|
|
5964
|
-
},
|
|
5965
|
-
{
|
|
5966
|
-
subscriptionTopic: SubscriptionTopic.ServiceInstance,
|
|
5967
|
-
route: "/metrics/services/:key/:subkey"
|
|
5968
|
-
}
|
|
5969
|
-
]
|
|
5970
|
-
},
|
|
5971
|
-
["agent"]: {
|
|
5972
|
-
influxDBContextTags: [
|
|
5973
|
-
"id",
|
|
5974
|
-
"hostName",
|
|
5975
|
-
"agentName",
|
|
5976
|
-
"threadId",
|
|
5977
|
-
"asyncRunnerId"
|
|
5978
|
-
],
|
|
5979
|
-
redisIndexPrefixDefinitions: {
|
|
5980
|
-
timeSeriesIndex: "idx:agentIndexTimeSeries",
|
|
5981
|
-
timeSeriesPrefix: "/agentTimeSeries:",
|
|
5982
|
-
instantIndex: "idx:agentIndexInstant",
|
|
5983
|
-
instantPrefix: "/agentInstant:"
|
|
5984
|
-
},
|
|
5985
|
-
fieldList: [
|
|
5986
|
-
{
|
|
5987
|
-
fieldName: "childCount",
|
|
5988
|
-
gauge: Gauge.CHILD_COUNT,
|
|
5989
|
-
instrumentProperty: "val",
|
|
5990
|
-
dataType: "number",
|
|
5991
|
-
influxdbDataType: "intField"
|
|
5992
|
-
/* intField */
|
|
5993
|
-
}
|
|
5994
|
-
],
|
|
5995
|
-
//@@ need type declare in appframework ?? agent does not use appframework ... perhaps stspublisher
|
|
5996
|
-
GetPathFromContext(context) {
|
|
5997
|
-
const { agentName, threadId, asyncRunnerId } = context;
|
|
5998
|
-
return `/${agentName}/${threadId}/${asyncRunnerId}`;
|
|
5999
|
-
},
|
|
6000
|
-
redisQueryFilters: {
|
|
6001
|
-
level1ContextField: "serviceType",
|
|
6002
|
-
level2ContextField: "appid",
|
|
6003
|
-
//@@ this should be named something else
|
|
6004
|
-
level3ContextField: "appinstanceid"
|
|
6005
|
-
//@@ this should be named something else
|
|
6006
|
-
},
|
|
6007
|
-
subscriptionTopics: [
|
|
6008
|
-
{
|
|
6009
|
-
subscriptionTopic: SubscriptionTopic.AllAgentsCombined,
|
|
6010
|
-
route: "/metrics"
|
|
6011
|
-
},
|
|
6012
|
-
{
|
|
6013
|
-
subscriptionTopic: SubscriptionTopic.Agents,
|
|
6014
|
-
route: "/metrics/agents"
|
|
6015
|
-
},
|
|
6016
|
-
{
|
|
6017
|
-
subscriptionTopic: SubscriptionTopic.AgentWorkers,
|
|
6018
|
-
route: "/metrics/agents/:key"
|
|
6019
|
-
},
|
|
6020
|
-
{
|
|
6021
|
-
subscriptionTopic: SubscriptionTopic.AgentWorker,
|
|
6022
|
-
route: "/metrics/agents/:key/:subkey"
|
|
6023
|
-
}
|
|
6024
|
-
]
|
|
6025
|
-
},
|
|
6026
|
-
["lambda"]: {
|
|
6027
|
-
influxDBContextTags: [
|
|
6028
|
-
"technology",
|
|
6029
|
-
"subTechnology",
|
|
6030
|
-
"lambdaFunctionName",
|
|
6031
|
-
"lambdaInstance",
|
|
6032
|
-
"hostName",
|
|
6033
|
-
"processId",
|
|
6034
|
-
"parentProcessId",
|
|
6035
|
-
"useCase",
|
|
6036
|
-
"pattern"
|
|
6037
|
-
],
|
|
6038
|
-
redisIndexPrefixDefinitions: {
|
|
6039
|
-
timeSeriesIndex: "idx:lambdaIndexTimeSeries",
|
|
6040
|
-
timeSeriesPrefix: "/lambdaTimeSeries:",
|
|
6041
|
-
instantIndex: "idx:lambdaIndexInstant",
|
|
6042
|
-
instantPrefix: "/lambdaInstant:"
|
|
6043
|
-
},
|
|
6044
|
-
fieldList: [
|
|
6045
|
-
{
|
|
6046
|
-
fieldName: "cpu",
|
|
6047
|
-
gauge: Gauge.CPU_LOAD_GAUGE,
|
|
6048
|
-
instrumentProperty: "val",
|
|
6049
|
-
dataType: "number",
|
|
6050
|
-
timeSeriesIndex: true,
|
|
6051
|
-
quantile: true,
|
|
6052
|
-
influxdbDataType: "floatField"
|
|
6053
|
-
/* floatField */
|
|
6054
|
-
},
|
|
6055
|
-
{
|
|
6056
|
-
fieldName: "connectionCount",
|
|
6057
|
-
gauge: Gauge.CONNECTION_COUNT_GAUGE,
|
|
6058
|
-
instrumentProperty: "val",
|
|
6059
|
-
dataType: "number",
|
|
6060
|
-
timeSeriesIndex: true,
|
|
6061
|
-
quantile: true,
|
|
6062
|
-
influxdbDataType: "intField"
|
|
6063
|
-
/* intField */
|
|
6064
|
-
},
|
|
6065
|
-
{
|
|
6066
|
-
fieldName: "connectionPoolCount",
|
|
6067
|
-
gauge: Gauge.CONNECTION_POOL_TOTAL_GAUGE,
|
|
6068
|
-
instrumentProperty: "val",
|
|
6069
|
-
dataType: "number",
|
|
6070
|
-
influxdbDataType: "intField"
|
|
6071
|
-
/* intField */
|
|
6072
|
-
},
|
|
6073
|
-
{
|
|
6074
|
-
fieldName: "connectionIdleCount",
|
|
6075
|
-
gauge: Gauge.CONNECTION_POOL_IDLE_GAUGE,
|
|
6076
|
-
instrumentProperty: "val",
|
|
6077
|
-
dataType: "number",
|
|
6078
|
-
influxdbDataType: "intField"
|
|
6079
|
-
/* intField */
|
|
6080
|
-
},
|
|
6081
|
-
{
|
|
6082
|
-
fieldName: "connectionWaitingCount",
|
|
6083
|
-
gauge: Gauge.CONNECTION_POOL_WAITING_GAUGE,
|
|
6084
|
-
instrumentProperty: "val",
|
|
6085
|
-
dataType: "number",
|
|
6086
|
-
influxdbDataType: "intField"
|
|
6087
|
-
/* intField */
|
|
6088
|
-
},
|
|
6089
|
-
{
|
|
6090
|
-
fieldName: "systemcpu",
|
|
6091
|
-
gauge: Gauge.CPU_SYSTEM_LOAD_GAUGE,
|
|
6092
|
-
instrumentProperty: "val",
|
|
6093
|
-
dataType: "number",
|
|
6094
|
-
timeSeriesIndex: true,
|
|
6095
|
-
quantile: true,
|
|
6096
|
-
influxdbDataType: "floatField"
|
|
6097
|
-
/* floatField */
|
|
6098
|
-
},
|
|
6099
|
-
{
|
|
6100
|
-
fieldName: "memory",
|
|
6101
|
-
gauge: Gauge.OBJECT_GAUGE,
|
|
6102
|
-
instrumentProperty: "val",
|
|
6103
|
-
dataType: "JSON",
|
|
6104
|
-
influxdbDataType: "stringField"
|
|
6105
|
-
/* stringField */
|
|
6106
|
-
}
|
|
6107
|
-
],
|
|
6108
|
-
//@@ need type declare in appframework
|
|
6109
|
-
GetPathFromContext(context) {
|
|
6110
|
-
const { technology, subTechnology, lambdaInstance } = context;
|
|
6111
|
-
return `/${technology}/${subTechnology}/${lambdaInstance}`;
|
|
6112
|
-
},
|
|
6113
|
-
redisQueryFilters: {
|
|
6114
|
-
level1ContextField: "serviceType",
|
|
6115
|
-
level2ContextField: "technology",
|
|
6116
|
-
level3ContextField: "subTechnology"
|
|
6117
|
-
},
|
|
6118
|
-
subscriptionTopics: [
|
|
6119
|
-
{
|
|
6120
|
-
subscriptionTopic: SubscriptionTopic.AllLambdasCombined,
|
|
6121
|
-
// uicontrollerlanding
|
|
6122
|
-
route: "/metrics"
|
|
6123
|
-
},
|
|
6124
|
-
{
|
|
6125
|
-
subscriptionTopic: SubscriptionTopic.LambdaTechnologies,
|
|
6126
|
-
// uicontrollerlambda
|
|
6127
|
-
route: "/metrics/lambdas"
|
|
6128
|
-
},
|
|
6129
|
-
{
|
|
6130
|
-
subscriptionTopic: SubscriptionTopic.LambdaSubTechnologies,
|
|
6131
|
-
// uicontrollerlambdasubtechnologies
|
|
6132
|
-
route: "/metrics/lambdas/:key"
|
|
6133
|
-
},
|
|
6134
|
-
{
|
|
6135
|
-
subscriptionTopic: SubscriptionTopic.LambdaSubTechnologiesInstance,
|
|
6136
|
-
// uicontrollerlambdasubtechnologiesinstance
|
|
6137
|
-
route: "/metrics/lambdas/:key/:subkey"
|
|
6138
|
-
}
|
|
6139
|
-
]
|
|
6140
|
-
}
|
|
6141
|
-
}
|
|
6142
|
-
});
|
|
6143
5978
|
class STSOAuth2Manager {
|
|
6144
5979
|
// ms
|
|
6145
5980
|
constructor(app, options) {
|