@dx-do/client 7.1.0 → 7.2.0
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/index.cjs.js +148 -53
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +146 -54
- package/dist/index.esm.js.map +1 -1
- package/dist/src/lib/model/config/DXDoConfiguration.d.ts +8 -0
- package/dist/src/lib/model/config/DXDoConfiguration.d.ts.map +1 -1
- package/dist/src/lib/model/config/DXSaaSConfiguration.d.ts +16 -0
- package/dist/src/lib/model/config/DXSaaSConfiguration.d.ts.map +1 -1
- package/dist/src/lib/model/datastore/metrics-metadata/register.d.ts +23 -0
- package/dist/src/lib/model/datastore/metrics-metadata/register.d.ts.map +1 -1
- package/dist/src/lib/services/datastore/datastore-metrics-metadata.service.d.ts +7 -3
- package/dist/src/lib/services/datastore/datastore-metrics-metadata.service.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -21,6 +21,14 @@ import { AxiosProxyConfig } from "axios";
|
|
|
21
21
|
export interface DXDoConfiguration {
|
|
22
22
|
/** DX SaaS v4 authentication and endpoint configuration. */
|
|
23
23
|
dxConfiguration: DXSaaSConfiguration4;
|
|
24
|
+
/**
|
|
25
|
+
* Absolute path of the profile file the configuration was loaded from.
|
|
26
|
+
* Absent when the configuration was assembled from environment variables
|
|
27
|
+
* or command-line flags — consumers use this both as provenance (identity
|
|
28
|
+
* verification applies only to file-backed profiles) and as the write
|
|
29
|
+
* target for stamping `tenantId`/`tenantCN` back into the profile.
|
|
30
|
+
*/
|
|
31
|
+
configurationFilePath?: string;
|
|
24
32
|
/**
|
|
25
33
|
* Optional Axios proxy settings. When provided, all HTTP requests issued by
|
|
26
34
|
* client services will be routed through the specified proxy host/port.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DXDoConfiguration.d.ts","sourceRoot":"","sources":["../../../../../src/lib/model/config/DXDoConfiguration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,oBAAoB,EAAC,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAC,gBAAgB,EAAC,MAAM,OAAO,CAAC;AAEvC;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,WAAW,iBAAiB;IAChC,4DAA4D;IAC5D,eAAe,EAAE,oBAAoB,CAAC;IACtC;;;OAGG;IACH,kBAAkB,CAAC,EAAE,gBAAgB,CAAC;CACvC"}
|
|
1
|
+
{"version":3,"file":"DXDoConfiguration.d.ts","sourceRoot":"","sources":["../../../../../src/lib/model/config/DXDoConfiguration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,oBAAoB,EAAC,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAC,gBAAgB,EAAC,MAAM,OAAO,CAAC;AAEvC;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,WAAW,iBAAiB;IAChC,4DAA4D;IAC5D,eAAe,EAAE,oBAAoB,CAAC;IACtC;;;;;;OAMG;IACH,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B;;;OAGG;IACH,kBAAkB,CAAC,EAAE,gBAAgB,CAAC;CACvC"}
|
|
@@ -56,6 +56,22 @@ export type DXSaaSConfiguration4 = {
|
|
|
56
56
|
"cohortId": string;
|
|
57
57
|
/** Base HTTPS URL of the DX API gateway (e.g. `"https://apmgw.dxi-na1.saas.broadcom.com"`). */
|
|
58
58
|
"dxGatewayHost": string;
|
|
59
|
+
/**
|
|
60
|
+
* Optional: numeric tenant id from the `userToken`'s JWT `tid` claim,
|
|
61
|
+
* stamped at profile creation or first connect. When present, every
|
|
62
|
+
* configured invocation verifies the current token still decodes to this
|
|
63
|
+
* tenant and refuses to run on mismatch — the guard against a token
|
|
64
|
+
* pasted from a different tenant. Delete the field (or recreate the
|
|
65
|
+
* profile) to re-stamp after an intentional tenant change.
|
|
66
|
+
*/
|
|
67
|
+
"tenantId"?: number;
|
|
68
|
+
/**
|
|
69
|
+
* Optional: human-readable tenant common name (from the identity
|
|
70
|
+
* endpoint), stamped at first connect. Informational — it's how a human
|
|
71
|
+
* tells profiles apart; a mismatch against the live tenant only warns
|
|
72
|
+
* (`tenantId` is the enforced check).
|
|
73
|
+
*/
|
|
74
|
+
"tenantCN"?: string;
|
|
59
75
|
/** Optional: base URL for the ASM API. Required only if using {@link AsmService}. */
|
|
60
76
|
"dxASMbaseAPIURL"?: string;
|
|
61
77
|
/** Optional: bearer token for ASM API calls. Required only if using {@link AsmService}. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DXSaaSConfiguration.d.ts","sourceRoot":"","sources":["../../../../../src/lib/model/config/DXSaaSConfiguration.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,uBAAuB,GAAG;IAClC,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;CACtB,CAAA;AAED,MAAM,MAAM,uBAAuB,GAAG,uBAAuB,GAAG;IAC5D,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC/B,CAAA;AAED;;;GAGG;AACH,MAAM,MAAM,yBAAyB,GAAG,uBAAuB,GAAG;IAC9D,QAAQ,EAAE,MAAM,CAAC;IACjB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,WAAW,CAAC,EAAE,MAAM,CAAA;CACvB,CAAA;AAED;;;GAGG;AACH,MAAM,MAAM,oBAAoB,GAAG,uBAAuB,GAAG;IACzD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sBAAsB,EAAE,GAAG,CAAA;CAC9B,CAAA;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,M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AM,CAAC;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sBAAsB,EAAE,GAAG,CAAA;CAC9B,CAAA;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,MAAM,oBAAoB,GAAG;IAC/B,mEAAmE;IACnE,sBAAsB,EAAE,GAAG,CAAC;IAC5B,qDAAqD;IACrD,WAAW,EAAE,MAAM,CAAC;IACpB,wFAAwF;IACxF,UAAU,EAAE,MAAM,CAAC;IACnB,+FAA+F;IAC/F,eAAe,EAAE,MAAM,CAAC;IACxB;;;;;;;OAOG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,qFAAqF;IACrF,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,2FAA2F;IAC3F,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;+EAE2E;IAC3E,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B;;;;;;;OAOG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;CACxB,CAAA"}
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
import { z } from 'zod/v4';
|
|
2
|
+
/**
|
|
3
|
+
* Reserved `attributes` key for tag-differentiated metrics: its value is the
|
|
4
|
+
* array of attribute names that form the metric's primary key. See
|
|
5
|
+
* `docs/data-store-doc/metadata-index.html` §3.1.3.
|
|
6
|
+
*/
|
|
7
|
+
export declare const TAGS_ATTRIBUTE_KEY = "@tags";
|
|
2
8
|
export declare const MetricRegisterSchema: z.ZodObject<{
|
|
3
9
|
id: z.ZodOptional<z.ZodString>;
|
|
4
10
|
sourceName: z.ZodString;
|
|
@@ -10,6 +16,23 @@ export declare const MetricRegisterSchema: z.ZodObject<{
|
|
|
10
16
|
lastSeen: z.ZodOptional<z.ZodNumber>;
|
|
11
17
|
}, z.core.$loose>;
|
|
12
18
|
export type MetricRegister = z.infer<typeof MetricRegisterSchema>;
|
|
19
|
+
/** True when the metric's type (numeric or enum form) carries the TYPE_TAGS flag. */
|
|
20
|
+
export declare function hasTypeTagsFlag(metric: MetricRegister): boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Request-side variant of {@link MetricRegisterSchema} enforcing the server's
|
|
23
|
+
* tag-registration restrictions (§3.1.3). Kept off the response path — server
|
|
24
|
+
* responses are validated defensively and must stay tolerant.
|
|
25
|
+
*/
|
|
26
|
+
export declare const MetricRegisterInputSchema: z.ZodObject<{
|
|
27
|
+
id: z.ZodOptional<z.ZodString>;
|
|
28
|
+
sourceName: z.ZodString;
|
|
29
|
+
attributeName: z.ZodString;
|
|
30
|
+
type: z.ZodOptional<z.ZodNumber>;
|
|
31
|
+
typeEnum: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
32
|
+
attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
33
|
+
firstSeen: z.ZodOptional<z.ZodNumber>;
|
|
34
|
+
lastSeen: z.ZodOptional<z.ZodNumber>;
|
|
35
|
+
}, z.core.$loose>;
|
|
13
36
|
export declare const MetricRegisterRequestSchema: z.ZodObject<{
|
|
14
37
|
sync: z.ZodOptional<z.ZodBoolean>;
|
|
15
38
|
metrics: z.ZodArray<z.ZodObject<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"register.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/model/datastore/metrics-metadata/register.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"register.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/model/datastore/metrics-metadata/register.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAG3B;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,UAAU,CAAC;AAE1C,eAAO,MAAM,oBAAoB;;;;;;;;;iBAmB/B,CAAC;AAEH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAElE,qFAAqF;AACrF,wBAAgB,eAAe,CAAC,MAAM,EAAE,cAAc,GAAG,OAAO,CAQ/D;AAED;;;;GAIG;AACH,eAAO,MAAM,yBAAyB;;;;;;;;;iBAkDrC,CAAC;AAEF,eAAO,MAAM,2BAA2B;;;;;;;;;;;;iBAGtC,CAAC;AAEH,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAEhF,eAAO,MAAM,0BAA0B;;;iBAGrC,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC;AAE9E,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;iBAGvC,CAAC;AAEH,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAC1C,OAAO,4BAA4B,CACpC,CAAC"}
|
|
@@ -39,10 +39,14 @@ export declare class DataStoreMetricsMetadataService {
|
|
|
39
39
|
* Registers one or more metrics via `POST /metadata/registerMetric`.
|
|
40
40
|
*
|
|
41
41
|
* @remarks The request is validated against {@link MetricRegisterRequestSchema}.
|
|
42
|
-
*
|
|
43
|
-
*
|
|
42
|
+
* Metrics carrying an `attributes["@tags"]` array get the TYPE_TAGS flag
|
|
43
|
+
* added to their type automatically (idempotent). If the response fails
|
|
44
|
+
* schema validation, a warning is logged but the raw API response is
|
|
45
|
+
* still returned.
|
|
44
46
|
*
|
|
45
|
-
* @throws ZodError if the request fails schema validation
|
|
47
|
+
* @throws ZodError if the request fails schema validation — including the
|
|
48
|
+
* tag-registration restrictions ("@tags" non-empty, every listed tag
|
|
49
|
+
* present with a non-empty string value, TYPE_TAGS never set without tags).
|
|
46
50
|
*/
|
|
47
51
|
registerMetrics(metrics: MetricRegister[], sync?: boolean): Promise<MetricRegisterResponse>;
|
|
48
52
|
/** Registers a single metric. Convenience wrapper around {@link registerMetrics}. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"datastore-metrics-metadata.service.d.ts","sourceRoot":"","sources":["../../../../../src/lib/services/datastore/datastore-metrics-metadata.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"datastore-metrics-metadata.service.d.ts","sourceRoot":"","sources":["../../../../../src/lib/services/datastore/datastore-metrics-metadata.service.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AASnD,OAAO,KAAK,EACV,mBAAmB,EACnB,6BAA6B,EAC7B,cAAc,EAEd,sBAAsB,EACvB,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AACtC,OAAO,SAAS,GAAG,OAAO,CAAC,SAAS,CAAC;AA8BrC;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,qBAAa,+BAA+B;IAQxC,OAAO,CAAC,QAAQ,CAAC,aAAa;IAC9B,OAAO,CAAC,QAAQ,CAAC,GAAG;IARtB;;;;;OAKG;gBAEgB,aAAa,EAAE,aAAa,EAC5B,GAAG,EAAE,SAAS;IAGjC;;;;;;;;;;;;OAYG;IACG,eAAe,CACnB,OAAO,EAAE,cAAc,EAAE,EACzB,IAAI,CAAC,EAAE,OAAO,GACb,OAAO,CAAC,sBAAsB,CAAC;IAoBlC,qFAAqF;IAC/E,cAAc,CAClB,MAAM,EAAE,cAAc,EACtB,IAAI,CAAC,EAAE,OAAO,GACb,OAAO,CAAC,sBAAsB,CAAC;IAIlC;;;;;;;;;;;OAWG;IACG,WAAW,CACf,KAAK,EAAE,mBAAmB,GACzB,OAAO,CAAC,6BAA6B,CAAC;CAe1C"}
|