@nsshunt/stsobservability 1.0.79 → 1.0.81
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/stsobservability.mjs +4 -2
- package/dist/stsobservability.mjs.map +1 -1
- package/dist/stsobservability.umd.js +3 -1
- package/dist/stsobservability.umd.js.map +1 -1
- package/package.json +7 -7
- package/types/socketioutils/socketIoServerHelper.d.ts +2 -2
- package/types/socketioutils/socketIoServerHelper.d.ts.map +1 -1
|
@@ -20,7 +20,7 @@ var __privateWrapper = (obj, member, setter, getter) => ({
|
|
|
20
20
|
var _a, _label, _options2, _data2, _val, _interval, _timeoutComputeVelocity, _lastVelocity, _delta, _maxVelocity, _timerInterval, _copy, _velocity, _velocityVal, _valStack, _averageValStack, _maxAverageValStack, _maxAverageIterations, _valStackMaxLength, _valStackAverage, _timeStamp, _maxTimeDiff, _vaTimeDiff, _velocityTimeDiff, _autoComputeVelocity, _autoComputeVelocityTimeout, _countDiff, _timeDiff, _deltaCountDiff, _deltaTimeDif, _minTimeForReporting, _averageVelocity, _InstrumentVelocity_instances, ComputeVelocityByTimeDiff_fn, ComputeVelocity_fn, SetupAutoComputeVelocity_fn, GetVelocityStackAverage_fn, GetVal_fn, SetVal_fn, GetVelocity_fn, GetMaxVelocity_fn, GetDelta_fn, GetTimeStamp_fn, GetCountDiff_fn, GetTimeDiff_fn, GetDeltaCountDiff_fn, GetDeltaTimeDif_fn, GetAverageVelocity_fn, _histogramData, _val2, _copy2, _InstrumentHistogram_instances, GetVal_fn2, SetVal_fn2, GetHistogramData_fn, SetHistogramData_fn, _messages, _readPos, _maxSize, _copy3, _useLatestMessages, _consoleLogging, _instrumentLogging, _winstonLogging, _stsLogger, _InstrumentLog_instances, DumpToConsole_fn, GetVal_fn3, SetVal_fn3, _start, _copy4, _pauseVal, _InstrumentTimerGauge_instances, GetVal_fn4, SetVal_fn4, _val3, _maxval, _lastObservedValue, _timeSeriesList, _maxSampleSize, _timerInterval2, _observer, _min, _max, _observations, _total, _copy5, _InstrumentGauge_instances, GetVal_fn5, SetVal_fn5, GetMin_fn, GetMax_fn, GetAverage_fn, GetAndResetMaxVal_fn, NumberCompare_fn, GetPercentileData_fn, _val4, _copy6, _InstrumentObject_instances, GetVal_fn6, SetVal_fn6, _tinyEmitter, _RequestCompleted, _agentManager2, _inPublish, _observer2, _publishState, _publisherTransport, _PublishInstruments_instances, PublishTimeoutLoop_fn, UpdateState_fn, _instruments, _publisher, _PublishInstrumentController_instances, GetInstrument_fn, ProcessTelemetryCommand_fn, CreateInstrument_fn, CreateInstruments_fn, _kafkaLog, _maxLogLength, _socketSubscribeKeepAlive, _options3, _agentManager3, _ObservabilityRESTAPISubscriber_instances, LogDebugMessage_fn, LogErrorMessage_fn, InvokeRESTAPI_fn, _GetData, SetupTimeout_fn, AddKeepAlive_fn, RemoveKeepAlive_fn, _messageWithAckPayloadRecords, _socket, _maxReties, _timeoutValue, _options4, _SocketIoMessageSender_instances, LogDebugMessage_fn2, GetSubscribeKeepAliveAckEventName_fn, _socketSubscribeKeepAlive2, _socket2, _options5, _socketIoMessageSender, _ObservabilitySocketIOSubscriber_instances, LogDebugMessage_fn3, LogErrorMessage_fn2, AddKeepAlive_fn2, RemoveKeepAlive_fn2, _observabilitySocketIOSubscriber, _subscriptions, _kafkaHelper, _serviceModel, _agentModel, _lambdaModel, _options6, _ObservabilitySubscriptionManager_instances, LogDebugMessage_fn4, LogErrorMessage_fn3, _options7, _sockets, _agentManager4, _SocketIoClientHelper_instances, LogDebugMessage_fn5, LogErrorMessage_fn4, EstablishSocketConnect_fn, _socketIoServerHelperOptions, _namespace, _SetupStandardEvents, _SetupConnectionMiddleware, _SetupMessageMiddleware;
|
|
21
21
|
import _cloneDeep from "lodash.clonedeep";
|
|
22
22
|
import isNode from "detect-node";
|
|
23
|
-
import { STSOptionsBase } from "@nsshunt/stsutils";
|
|
23
|
+
import { STSOptionsBase, Sleep } from "@nsshunt/stsutils";
|
|
24
24
|
import { TinyEmitter } from "tiny-emitter";
|
|
25
25
|
import axios from "axios";
|
|
26
26
|
import http from "node:http";
|
|
@@ -8976,8 +8976,10 @@ class SocketIoServerHelper {
|
|
|
8976
8976
|
__publicField(this, "GetSTSSocketIONamespaces", () => {
|
|
8977
8977
|
return __privateGet(this, _namespace);
|
|
8978
8978
|
});
|
|
8979
|
-
__publicField(this, "DisconnectSockets", () => {
|
|
8979
|
+
__publicField(this, "DisconnectSockets", async () => {
|
|
8980
8980
|
for (const [, namespace] of Object.entries(__privateGet(this, _namespace))) {
|
|
8981
|
+
await namespace.socketionamespace.adapter.close();
|
|
8982
|
+
await Sleep(50);
|
|
8981
8983
|
namespace.socketionamespace.disconnectSockets();
|
|
8982
8984
|
}
|
|
8983
8985
|
__privateSet(this, _namespace, {});
|