@oneuptime/common 14.0.107 → 14.0.108
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/Models/DatabaseModels/DataBiConnection.d.mts +4 -0
- package/Models/DatabaseModels/DataBiConnection.d.ts +4 -0
- package/Models/DatabaseModels/DataBiConnection.js +59 -2
- package/Models/DatabaseModels/Index.js +2 -0
- package/Models/DatabaseModels/RumProductAnalyticsSavedView.d.mts +20 -0
- package/Models/DatabaseModels/RumProductAnalyticsSavedView.d.ts +20 -0
- package/Models/DatabaseModels/RumProductAnalyticsSavedView.js +353 -0
- package/Models/DatabaseModels/RumProductAnalyticsSavedView.mjs +2 -0
- package/Models/DatabaseModels/WhatsAppLog.d.mts +3 -0
- package/Models/DatabaseModels/WhatsAppLog.d.ts +3 -0
- package/Models/DatabaseModels/WhatsAppLog.js +62 -0
- package/Models/DatabaseModels/WorkspaceProjectAuthToken.d.mts +11 -0
- package/Models/DatabaseModels/WorkspaceProjectAuthToken.d.ts +11 -0
- package/Models/DatabaseModels/WorkspaceUserGroup.js +1 -1
- package/Server/Utils/Telemetry/NotificationDeliveryMetrics.d.mts +212 -0
- package/Server/Utils/Telemetry/NotificationDeliveryMetrics.d.ts +212 -0
- package/Server/Utils/Workspace/WorkspaceBase.d.mts +3 -0
- package/Server/Utils/Workspace/WorkspaceBase.d.ts +3 -0
- package/Types/AI/AIChatTypes.d.mts +2 -1
- package/Types/AI/AIChatTypes.d.ts +2 -1
- package/Types/AI/AIChatTypes.js +2 -0
- package/Types/AI/InvestigationNotStartedReason.d.mts +7 -0
- package/Types/AI/InvestigationNotStartedReason.d.ts +7 -0
- package/Types/CodeInSentence.d.mts +8 -0
- package/Types/CodeInSentence.d.ts +8 -0
- package/Types/CodeInSentence.js +875 -0
- package/Types/CodeInSentence.mjs +4 -0
- package/Types/Dashboard/DashboardComponentType.d.mts +2 -0
- package/Types/Dashboard/DashboardComponentType.d.ts +2 -0
- package/Types/Dashboard/DashboardComponentType.js +7 -0
- package/Types/Dashboard/DashboardComponents/ComponentArgument.d.mts +3 -1
- package/Types/Dashboard/DashboardComponents/ComponentArgument.d.ts +3 -1
- package/Types/Dashboard/DashboardComponents/ComponentArgument.js +3 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsFunnelComponent.d.mts +11 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsFunnelComponent.d.ts +11 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsFunnelComponent.js +2 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsFunnelComponent.mjs +1 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsRetentionComponent.d.mts +11 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsRetentionComponent.d.ts +11 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsRetentionComponent.js +2 -0
- package/Types/Dashboard/DashboardComponents/DashboardProductAnalyticsRetentionComponent.mjs +1 -0
- package/Types/Dashboard/PublicDashboardServedSettings.js +15 -7
- package/Types/DataObservability/DataBiRefreshAlert.d.mts +44 -0
- package/Types/DataObservability/DataBiRefreshAlert.d.ts +44 -0
- package/Types/DataObservability/DataBiRefreshAlert.js +206 -0
- package/Types/DataObservability/DataBiRefreshAlert.mjs +12 -0
- package/Types/DataObservability/DataObservabilityApiTypes.d.mts +7 -0
- package/Types/DataObservability/DataObservabilityApiTypes.d.ts +7 -0
- package/Types/DataObservability/DataObservabilityApiTypes.js +12 -0
- package/Types/DataObservability/DataTableLineage.d.mts +22 -1
- package/Types/DataObservability/DataTableLineage.d.ts +22 -1
- package/Types/DataObservability/DataTableLineage.js +13 -5
- package/Types/DataObservability/DataTableLineage.mjs +2 -0
- package/Types/HashedString.js +9 -2
- package/Types/Monitor/CriteriaFilterValues.d.mts +16 -0
- package/Types/Monitor/CriteriaFilterValues.d.ts +16 -0
- package/Types/Monitor/CriteriaFilterValues.js +324 -0
- package/Types/Monitor/CriteriaFilterValues.mjs +2 -0
- package/Types/Monitor/DataBiRefreshMonitorStep.d.mts +13 -0
- package/Types/Monitor/DataBiRefreshMonitorStep.d.ts +13 -0
- package/Types/Monitor/DataBiRefreshMonitorStep.js +108 -0
- package/Types/Monitor/DataBiRefreshMonitorStep.mjs +3 -0
- package/Types/Monitor/IncomingEmailMonitor/IncomingEmailMonitorRequest.d.mts +1 -0
- package/Types/Monitor/IncomingEmailMonitor/IncomingEmailMonitorRequest.d.ts +1 -0
- package/Types/Monitor/MonitorCriteriaInstance.js +22 -2
- package/Types/Monitor/MonitorStep.js +28 -11
- package/Types/Monitor/MonitorStepMetricMonitor.js +6 -1
- package/Types/Monitor/MonitorStepRollingTime.d.mts +12 -0
- package/Types/Monitor/MonitorStepRollingTime.d.ts +12 -0
- package/Types/Monitor/MonitorStepRollingTime.js +117 -0
- package/Types/Monitor/MonitorStepRollingTime.mjs +2 -0
- package/Types/Monitor/SeriesContext/SeriesLabelDisplay.js +11 -0
- package/Types/Monitor/ServerMonitor/ServerMonitorResponse.d.mts +1 -0
- package/Types/Monitor/ServerMonitor/ServerMonitorResponse.d.ts +1 -0
- package/Types/Monitor/TelemetryAlertRule.js +7 -2
- package/Types/NotificationRule/NotificationRepeat.d.mts +10 -0
- package/Types/NotificationRule/NotificationRepeat.d.ts +10 -0
- package/Types/NotificationRule/NotificationRepeat.js +51 -0
- package/Types/NotificationRule/NotificationRepeat.mjs +2 -0
- package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.d.mts +70 -0
- package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.d.ts +70 -0
- package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.js +276 -0
- package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.mjs +12 -0
- package/Types/OnCallDutyPolicy/OnCallEscalationWait.d.mts +9 -0
- package/Types/OnCallDutyPolicy/OnCallEscalationWait.d.ts +9 -0
- package/Types/OnCallDutyPolicy/OnCallEscalationWait.js +44 -0
- package/Types/OnCallDutyPolicy/OnCallEscalationWait.mjs +5 -0
- package/Types/Probe/ProbeMonitorResponse.d.mts +1 -0
- package/Types/Probe/ProbeMonitorResponse.d.ts +1 -0
- package/Types/ReadingDirection.d.mts +2 -0
- package/Types/ReadingDirection.d.ts +2 -0
- package/Types/ReadingDirection.js +221 -25
- package/Types/ReadingDirection.mjs +2 -0
- package/Types/RollingTime/RollingTimeUtil.d.mts +7 -0
- package/Types/RollingTime/RollingTimeUtil.d.ts +7 -0
- package/Types/RollingTime/RollingTimeUtil.js +240 -71
- package/Types/Rum/ProductAnalyticsSavedViews.d.mts +56 -0
- package/Types/Rum/ProductAnalyticsSavedViews.d.ts +56 -0
- package/Types/Rum/ProductAnalyticsSavedViews.js +219 -0
- package/Types/Rum/ProductAnalyticsSavedViews.mjs +14 -0
- package/Types/SecurityEvent/Connectors/SecurityEventConnectorCatalog.js +8 -7
- package/Types/Telemetry/ServiceType.d.mts +1 -0
- package/Types/Telemetry/ServiceType.d.ts +1 -0
- package/Types/Telemetry/ServiceType.js +6 -0
- package/Utils/Crypto.js +10 -3
- package/Utils/Dashboard/Components/DashboardProductAnalyticsFunnelComponent.d.mts +7 -0
- package/Utils/Dashboard/Components/DashboardProductAnalyticsFunnelComponent.d.ts +7 -0
- package/Utils/Dashboard/Components/DashboardProductAnalyticsFunnelComponent.js +67 -0
- package/Utils/Dashboard/Components/DashboardProductAnalyticsFunnelComponent.mjs +2 -0
- package/Utils/Dashboard/Components/DashboardProductAnalyticsRetentionComponent.d.mts +7 -0
- package/Utils/Dashboard/Components/DashboardProductAnalyticsRetentionComponent.d.ts +7 -0
- package/Utils/Dashboard/Components/DashboardProductAnalyticsRetentionComponent.js +68 -0
- package/Utils/Dashboard/Components/DashboardProductAnalyticsRetentionComponent.mjs +2 -0
- package/Utils/Dashboard/DashboardWidgetIds.js +6 -1
- package/Utils/Metrics/MetricQueryCloudAggregation.js +2 -4
- package/Utils/Monitor/MonitorRootCauseWording.js +28 -24
- package/Utils/Monitor/MonitorStepMetricQueries.js +2 -1
- package/Utils/Monitor/MonitorStepsValuesUtil.d.mts +13 -0
- package/Utils/Monitor/MonitorStepsValuesUtil.d.ts +13 -0
- package/Utils/Monitor/MonitorStepsValuesUtil.js +80 -0
- package/Utils/Monitor/MonitorStepsValuesUtil.mjs +2 -0
- package/Utils/Slo/SloProjection.d.mts +18 -0
- package/Utils/Slo/SloProjection.d.ts +18 -0
- package/Utils/Slo/SloProjection.js +53 -12
- package/Utils/Slo/SloProjection.mjs +2 -0
- package/Utils/StatusPage/ResourceExplorer.d.mts +0 -10
- package/Utils/StatusPage/ResourceExplorer.d.ts +0 -10
- package/Utils/StatusPage/ResourceExplorer.js +0 -28
- package/package.json +1 -1
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { ProductAnalyticsEventRef, ProductAnalyticsRetentionPeriod, ProductAnalyticsSegmentFilter } from "./ProductAnalyticsEventReads.mjs";
|
|
2
|
+
export declare enum ProductAnalyticsSavedViewType {
|
|
3
|
+
Funnel = "funnel",
|
|
4
|
+
Retention = "retention"
|
|
5
|
+
}
|
|
6
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_TYPES: ReadonlyArray<ProductAnalyticsSavedViewType>;
|
|
7
|
+
export declare function isProductAnalyticsSavedViewType(value: unknown): value is ProductAnalyticsSavedViewType;
|
|
8
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH: number;
|
|
9
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX: number;
|
|
10
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_URL_KEY: string;
|
|
11
|
+
export interface ProductAnalyticsFunnelDefinition {
|
|
12
|
+
steps: Array<ProductAnalyticsEventRef>;
|
|
13
|
+
windowMs: number;
|
|
14
|
+
filters: Array<ProductAnalyticsSegmentFilter>;
|
|
15
|
+
}
|
|
16
|
+
export interface ProductAnalyticsRetentionDefinition {
|
|
17
|
+
startEvent: ProductAnalyticsEventRef;
|
|
18
|
+
returnEvent: ProductAnalyticsEventRef;
|
|
19
|
+
period: ProductAnalyticsRetentionPeriod;
|
|
20
|
+
filters: Array<ProductAnalyticsSegmentFilter>;
|
|
21
|
+
}
|
|
22
|
+
export interface ProductAnalyticsSavedViewDefinitions {
|
|
23
|
+
[ProductAnalyticsSavedViewType.Funnel]: ProductAnalyticsFunnelDefinition;
|
|
24
|
+
[ProductAnalyticsSavedViewType.Retention]: ProductAnalyticsRetentionDefinition;
|
|
25
|
+
}
|
|
26
|
+
export type ProductAnalyticsDefinitionRead<T> = {
|
|
27
|
+
definition: T;
|
|
28
|
+
problem: null;
|
|
29
|
+
} | {
|
|
30
|
+
definition: null;
|
|
31
|
+
problem: string;
|
|
32
|
+
};
|
|
33
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS: {
|
|
34
|
+
notAnObject: string;
|
|
35
|
+
steps: string;
|
|
36
|
+
step: string;
|
|
37
|
+
window: string;
|
|
38
|
+
filters: string;
|
|
39
|
+
filter: string;
|
|
40
|
+
startEvent: string;
|
|
41
|
+
returnEvent: string;
|
|
42
|
+
period: string;
|
|
43
|
+
name: string;
|
|
44
|
+
nameTooLong: string;
|
|
45
|
+
viewType: string;
|
|
46
|
+
viewTypeFixed: string;
|
|
47
|
+
oneKindAtATime: string;
|
|
48
|
+
definition: string;
|
|
49
|
+
tooMany: string;
|
|
50
|
+
};
|
|
51
|
+
export declare function readProductAnalyticsFunnelDefinition(value: unknown): ProductAnalyticsDefinitionRead<ProductAnalyticsFunnelDefinition>;
|
|
52
|
+
export declare function readProductAnalyticsRetentionDefinition(value: unknown): ProductAnalyticsDefinitionRead<ProductAnalyticsRetentionDefinition>;
|
|
53
|
+
export declare function readProductAnalyticsSavedViewDefinition<T extends ProductAnalyticsSavedViewType>(viewType: T, value: unknown): ProductAnalyticsDefinitionRead<ProductAnalyticsSavedViewDefinitions[T]>;
|
|
54
|
+
export declare function toProductAnalyticsSavedViewName(value: unknown): string;
|
|
55
|
+
export declare function getProductAnalyticsSavedViewNameProblem(value: unknown): string | null;
|
|
56
|
+
export declare function isSameProductAnalyticsDefinition(left: unknown, right: unknown): boolean;
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { ProductAnalyticsEventRef, ProductAnalyticsRetentionPeriod, ProductAnalyticsSegmentFilter } from "./ProductAnalyticsEventReads";
|
|
2
|
+
export declare enum ProductAnalyticsSavedViewType {
|
|
3
|
+
Funnel = "funnel",
|
|
4
|
+
Retention = "retention"
|
|
5
|
+
}
|
|
6
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_TYPES: ReadonlyArray<ProductAnalyticsSavedViewType>;
|
|
7
|
+
export declare function isProductAnalyticsSavedViewType(value: unknown): value is ProductAnalyticsSavedViewType;
|
|
8
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH: number;
|
|
9
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX: number;
|
|
10
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_URL_KEY: string;
|
|
11
|
+
export interface ProductAnalyticsFunnelDefinition {
|
|
12
|
+
steps: Array<ProductAnalyticsEventRef>;
|
|
13
|
+
windowMs: number;
|
|
14
|
+
filters: Array<ProductAnalyticsSegmentFilter>;
|
|
15
|
+
}
|
|
16
|
+
export interface ProductAnalyticsRetentionDefinition {
|
|
17
|
+
startEvent: ProductAnalyticsEventRef;
|
|
18
|
+
returnEvent: ProductAnalyticsEventRef;
|
|
19
|
+
period: ProductAnalyticsRetentionPeriod;
|
|
20
|
+
filters: Array<ProductAnalyticsSegmentFilter>;
|
|
21
|
+
}
|
|
22
|
+
export interface ProductAnalyticsSavedViewDefinitions {
|
|
23
|
+
[ProductAnalyticsSavedViewType.Funnel]: ProductAnalyticsFunnelDefinition;
|
|
24
|
+
[ProductAnalyticsSavedViewType.Retention]: ProductAnalyticsRetentionDefinition;
|
|
25
|
+
}
|
|
26
|
+
export type ProductAnalyticsDefinitionRead<T> = {
|
|
27
|
+
definition: T;
|
|
28
|
+
problem: null;
|
|
29
|
+
} | {
|
|
30
|
+
definition: null;
|
|
31
|
+
problem: string;
|
|
32
|
+
};
|
|
33
|
+
export declare const PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS: {
|
|
34
|
+
notAnObject: string;
|
|
35
|
+
steps: string;
|
|
36
|
+
step: string;
|
|
37
|
+
window: string;
|
|
38
|
+
filters: string;
|
|
39
|
+
filter: string;
|
|
40
|
+
startEvent: string;
|
|
41
|
+
returnEvent: string;
|
|
42
|
+
period: string;
|
|
43
|
+
name: string;
|
|
44
|
+
nameTooLong: string;
|
|
45
|
+
viewType: string;
|
|
46
|
+
viewTypeFixed: string;
|
|
47
|
+
oneKindAtATime: string;
|
|
48
|
+
definition: string;
|
|
49
|
+
tooMany: string;
|
|
50
|
+
};
|
|
51
|
+
export declare function readProductAnalyticsFunnelDefinition(value: unknown): ProductAnalyticsDefinitionRead<ProductAnalyticsFunnelDefinition>;
|
|
52
|
+
export declare function readProductAnalyticsRetentionDefinition(value: unknown): ProductAnalyticsDefinitionRead<ProductAnalyticsRetentionDefinition>;
|
|
53
|
+
export declare function readProductAnalyticsSavedViewDefinition<T extends ProductAnalyticsSavedViewType>(viewType: T, value: unknown): ProductAnalyticsDefinitionRead<ProductAnalyticsSavedViewDefinitions[T]>;
|
|
54
|
+
export declare function toProductAnalyticsSavedViewName(value: unknown): string;
|
|
55
|
+
export declare function getProductAnalyticsSavedViewNameProblem(value: unknown): string | null;
|
|
56
|
+
export declare function isSameProductAnalyticsDefinition(left: unknown, right: unknown): boolean;
|
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*
|
|
3
|
+
* Saved funnels and retention tables (issue #6630): a RUM application's
|
|
4
|
+
* Funnels and User Retention pages keep what they read - a funnel's steps,
|
|
5
|
+
* the time to finish it and its segment; a retention table's start and
|
|
6
|
+
* return events, its period and its segment - under a name, for the team
|
|
7
|
+
* to open again, and for a dashboard widget to read with the dashboard's
|
|
8
|
+
* time range. The range is not part of it: the page keeps its own, and a
|
|
9
|
+
* widget reads the dashboard's.
|
|
10
|
+
*
|
|
11
|
+
* One shape for the three that write and read one - the server
|
|
12
|
+
* (RumProductAnalyticsSavedViewService refuses a definition the read
|
|
13
|
+
* routes would refuse), the pages and the widgets (each reads a stored
|
|
14
|
+
* one as untrusted, and says so when it cannot) - with the read routes'
|
|
15
|
+
* own rules (ProductAnalyticsEventReads): the same events, windows,
|
|
16
|
+
* periods and segments, and nothing else.
|
|
17
|
+
*/
|
|
18
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
|
+
exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS = exports.PRODUCT_ANALYTICS_SAVED_VIEW_URL_KEY = exports.PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX = exports.PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH = exports.PRODUCT_ANALYTICS_SAVED_VIEW_TYPES = exports.ProductAnalyticsSavedViewType = void 0;
|
|
20
|
+
exports.isProductAnalyticsSavedViewType = isProductAnalyticsSavedViewType;
|
|
21
|
+
exports.readProductAnalyticsFunnelDefinition = readProductAnalyticsFunnelDefinition;
|
|
22
|
+
exports.readProductAnalyticsRetentionDefinition = readProductAnalyticsRetentionDefinition;
|
|
23
|
+
exports.readProductAnalyticsSavedViewDefinition = readProductAnalyticsSavedViewDefinition;
|
|
24
|
+
exports.toProductAnalyticsSavedViewName = toProductAnalyticsSavedViewName;
|
|
25
|
+
exports.getProductAnalyticsSavedViewNameProblem = getProductAnalyticsSavedViewNameProblem;
|
|
26
|
+
exports.isSameProductAnalyticsDefinition = isSameProductAnalyticsDefinition;
|
|
27
|
+
const ProductAnalyticsEventReads_1 = require("./ProductAnalyticsEventReads");
|
|
28
|
+
/* What a saved definition is of: the page that saved it, and the widget that draws it. */
|
|
29
|
+
var ProductAnalyticsSavedViewType;
|
|
30
|
+
(function (ProductAnalyticsSavedViewType) {
|
|
31
|
+
ProductAnalyticsSavedViewType["Funnel"] = "funnel";
|
|
32
|
+
ProductAnalyticsSavedViewType["Retention"] = "retention";
|
|
33
|
+
})(ProductAnalyticsSavedViewType || (exports.ProductAnalyticsSavedViewType = ProductAnalyticsSavedViewType = {}));
|
|
34
|
+
exports.PRODUCT_ANALYTICS_SAVED_VIEW_TYPES = [
|
|
35
|
+
ProductAnalyticsSavedViewType.Funnel,
|
|
36
|
+
ProductAnalyticsSavedViewType.Retention,
|
|
37
|
+
];
|
|
38
|
+
function isProductAnalyticsSavedViewType(value) {
|
|
39
|
+
return (typeof value === "string" &&
|
|
40
|
+
exports.PRODUCT_ANALYTICS_SAVED_VIEW_TYPES.includes(value));
|
|
41
|
+
}
|
|
42
|
+
/* A name as the list shows it: the model's short text. */
|
|
43
|
+
exports.PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH = 100;
|
|
44
|
+
/*
|
|
45
|
+
* The most of one kind an application keeps: a team's list to pick from,
|
|
46
|
+
* which the pages read whole.
|
|
47
|
+
*/
|
|
48
|
+
exports.PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX = 100;
|
|
49
|
+
/*
|
|
50
|
+
* The address key a page opens a saved definition by
|
|
51
|
+
* (`?view=<id>`): the link a widget's "Open" goes to, and the one a page
|
|
52
|
+
* keeps while the definition on screen is the saved one.
|
|
53
|
+
*/
|
|
54
|
+
exports.PRODUCT_ANALYTICS_SAVED_VIEW_URL_KEY = "view";
|
|
55
|
+
/*
|
|
56
|
+
* Why a definition cannot be kept or read, in the words the read routes
|
|
57
|
+
* use for the same mistakes.
|
|
58
|
+
*/
|
|
59
|
+
exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS = {
|
|
60
|
+
notAnObject: "A saved definition must be an object.",
|
|
61
|
+
steps: `A funnel has ${ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_FUNNEL_MIN_STEPS} to ${ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_FUNNEL_MAX_STEPS} steps.`,
|
|
62
|
+
step: "Each step must be an event: a kind and, for a page or a custom event, its name.",
|
|
63
|
+
window: `windowMs must be one of ${ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_FUNNEL_WINDOWS_MS.join(", ")}.`,
|
|
64
|
+
filters: `A segment has at most ${ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_MAX_SEGMENT_FILTERS} filters.`,
|
|
65
|
+
filter: "Each filter needs a field, a key for a property or a user property, and a value.",
|
|
66
|
+
startEvent: "The start event must be an event: a kind and, for a page or a custom event, its name.",
|
|
67
|
+
returnEvent: "The return event must be an event: a kind and, for a page or a custom event, its name.",
|
|
68
|
+
period: `period must be one of ${ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_RETENTION_PERIODS.join(", ")}.`,
|
|
69
|
+
name: "Give it a name.",
|
|
70
|
+
nameTooLong: `A name has at most ${exports.PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH} characters.`,
|
|
71
|
+
viewType: `viewType must be one of ${exports.PRODUCT_ANALYTICS_SAVED_VIEW_TYPES.join(", ")}.`,
|
|
72
|
+
viewTypeFixed: "A saved funnel stays a funnel, and a saved retention table a retention table: save a new one instead.",
|
|
73
|
+
oneKindAtATime: "A definition is a funnel's or a retention table's: update saved funnels and saved retention tables apart.",
|
|
74
|
+
definition: "Save what the page shows: its definition is missing.",
|
|
75
|
+
tooMany: `An application keeps at most ${exports.PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX} saved funnels and ${exports.PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX} saved retention tables. Delete one you no longer use first.`,
|
|
76
|
+
};
|
|
77
|
+
function isRecord(value) {
|
|
78
|
+
return value !== null && typeof value === "object" && !Array.isArray(value);
|
|
79
|
+
}
|
|
80
|
+
function problem(message) {
|
|
81
|
+
return { definition: null, problem: message };
|
|
82
|
+
}
|
|
83
|
+
/* A segment as the routes read one: absent is none; each filter as the routes keep it. */
|
|
84
|
+
function readFilters(value) {
|
|
85
|
+
if (value === undefined || value === null) {
|
|
86
|
+
return { definition: [], problem: null };
|
|
87
|
+
}
|
|
88
|
+
if (!Array.isArray(value) ||
|
|
89
|
+
value.length > ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_MAX_SEGMENT_FILTERS) {
|
|
90
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.filters);
|
|
91
|
+
}
|
|
92
|
+
const filters = [];
|
|
93
|
+
for (const entry of value) {
|
|
94
|
+
const filter = (0, ProductAnalyticsEventReads_1.toProductAnalyticsSegmentFilter)(entry);
|
|
95
|
+
if (!filter) {
|
|
96
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.filter);
|
|
97
|
+
}
|
|
98
|
+
filters.push({
|
|
99
|
+
field: filter.field,
|
|
100
|
+
key: filter.key,
|
|
101
|
+
value: filter.value,
|
|
102
|
+
});
|
|
103
|
+
}
|
|
104
|
+
return { definition: filters, problem: null };
|
|
105
|
+
}
|
|
106
|
+
/*
|
|
107
|
+
* A funnel's definition: two to six steps, a time to finish it the page
|
|
108
|
+
* offers (the default when none is named) and a segment - kept in that
|
|
109
|
+
* shape alone, so nothing else a caller sent is stored.
|
|
110
|
+
*/
|
|
111
|
+
function readProductAnalyticsFunnelDefinition(value) {
|
|
112
|
+
if (!isRecord(value)) {
|
|
113
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.notAnObject);
|
|
114
|
+
}
|
|
115
|
+
const rawSteps = value["steps"];
|
|
116
|
+
if (!Array.isArray(rawSteps) ||
|
|
117
|
+
rawSteps.length < ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_FUNNEL_MIN_STEPS ||
|
|
118
|
+
rawSteps.length > ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_FUNNEL_MAX_STEPS) {
|
|
119
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.steps);
|
|
120
|
+
}
|
|
121
|
+
const steps = [];
|
|
122
|
+
for (const rawStep of rawSteps) {
|
|
123
|
+
const step = (0, ProductAnalyticsEventReads_1.toProductAnalyticsEventRef)(rawStep);
|
|
124
|
+
if (!step) {
|
|
125
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.step);
|
|
126
|
+
}
|
|
127
|
+
steps.push({ kind: step.kind, name: step.name });
|
|
128
|
+
}
|
|
129
|
+
const rawWindow = value["windowMs"];
|
|
130
|
+
const windowMs = rawWindow === undefined || rawWindow === null
|
|
131
|
+
? ProductAnalyticsEventReads_1.DEFAULT_PRODUCT_ANALYTICS_FUNNEL_WINDOW_MS
|
|
132
|
+
: rawWindow;
|
|
133
|
+
if (typeof windowMs !== "number" ||
|
|
134
|
+
!ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_FUNNEL_WINDOWS_MS.includes(windowMs)) {
|
|
135
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.window);
|
|
136
|
+
}
|
|
137
|
+
const filters = readFilters(value["filters"]);
|
|
138
|
+
if (!filters.definition) {
|
|
139
|
+
return problem(filters.problem);
|
|
140
|
+
}
|
|
141
|
+
return {
|
|
142
|
+
definition: {
|
|
143
|
+
steps: steps,
|
|
144
|
+
windowMs: windowMs,
|
|
145
|
+
filters: filters.definition,
|
|
146
|
+
},
|
|
147
|
+
problem: null,
|
|
148
|
+
};
|
|
149
|
+
}
|
|
150
|
+
/*
|
|
151
|
+
* A retention table's definition: its start and return events, a period
|
|
152
|
+
* (a week when none is named, as the read's own default) and a segment.
|
|
153
|
+
*/
|
|
154
|
+
function readProductAnalyticsRetentionDefinition(value) {
|
|
155
|
+
if (!isRecord(value)) {
|
|
156
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.notAnObject);
|
|
157
|
+
}
|
|
158
|
+
const startEvent = (0, ProductAnalyticsEventReads_1.toProductAnalyticsEventRef)(value["startEvent"]);
|
|
159
|
+
if (!startEvent) {
|
|
160
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.startEvent);
|
|
161
|
+
}
|
|
162
|
+
const returnEvent = (0, ProductAnalyticsEventReads_1.toProductAnalyticsEventRef)(value["returnEvent"]);
|
|
163
|
+
if (!returnEvent) {
|
|
164
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.returnEvent);
|
|
165
|
+
}
|
|
166
|
+
const rawPeriod = value["period"];
|
|
167
|
+
const period = rawPeriod === undefined || rawPeriod === null
|
|
168
|
+
? ProductAnalyticsEventReads_1.ProductAnalyticsRetentionPeriod.Week
|
|
169
|
+
: rawPeriod;
|
|
170
|
+
if (typeof period !== "string" ||
|
|
171
|
+
!ProductAnalyticsEventReads_1.PRODUCT_ANALYTICS_RETENTION_PERIODS.includes(period)) {
|
|
172
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.period);
|
|
173
|
+
}
|
|
174
|
+
const filters = readFilters(value["filters"]);
|
|
175
|
+
if (!filters.definition) {
|
|
176
|
+
return problem(filters.problem);
|
|
177
|
+
}
|
|
178
|
+
return {
|
|
179
|
+
definition: {
|
|
180
|
+
startEvent: { kind: startEvent.kind, name: startEvent.name },
|
|
181
|
+
returnEvent: { kind: returnEvent.kind, name: returnEvent.name },
|
|
182
|
+
period: period,
|
|
183
|
+
filters: filters.definition,
|
|
184
|
+
},
|
|
185
|
+
problem: null,
|
|
186
|
+
};
|
|
187
|
+
}
|
|
188
|
+
/* A definition of the kind named, read as that kind's. */
|
|
189
|
+
function readProductAnalyticsSavedViewDefinition(viewType, value) {
|
|
190
|
+
if (viewType === ProductAnalyticsSavedViewType.Funnel) {
|
|
191
|
+
return readProductAnalyticsFunnelDefinition(value);
|
|
192
|
+
}
|
|
193
|
+
if (viewType === ProductAnalyticsSavedViewType.Retention) {
|
|
194
|
+
return readProductAnalyticsRetentionDefinition(value);
|
|
195
|
+
}
|
|
196
|
+
return problem(exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.viewType);
|
|
197
|
+
}
|
|
198
|
+
/* A name as it is kept: trimmed. */
|
|
199
|
+
function toProductAnalyticsSavedViewName(value) {
|
|
200
|
+
return typeof value === "string" ? value.trim() : "";
|
|
201
|
+
}
|
|
202
|
+
/* What is wrong with a name, or null: there is one, and it fits. */
|
|
203
|
+
function getProductAnalyticsSavedViewNameProblem(value) {
|
|
204
|
+
const name = toProductAnalyticsSavedViewName(value);
|
|
205
|
+
if (name.length === 0) {
|
|
206
|
+
return exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.name;
|
|
207
|
+
}
|
|
208
|
+
if (name.length > exports.PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH) {
|
|
209
|
+
return exports.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS.nameTooLong;
|
|
210
|
+
}
|
|
211
|
+
return null;
|
|
212
|
+
}
|
|
213
|
+
/*
|
|
214
|
+
* Whether two definitions read the same: what a page compares to say the
|
|
215
|
+
* one on screen is the saved one, or has changed since.
|
|
216
|
+
*/
|
|
217
|
+
function isSameProductAnalyticsDefinition(left, right) {
|
|
218
|
+
return JSON.stringify(left) === JSON.stringify(right);
|
|
219
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import commonJsModule from "./ProductAnalyticsSavedViews.js";
|
|
2
|
+
export const PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX = commonJsModule.PRODUCT_ANALYTICS_SAVED_VIEWS_PER_APPLICATION_MAX;
|
|
3
|
+
export const PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH = commonJsModule.PRODUCT_ANALYTICS_SAVED_VIEW_NAME_MAX_LENGTH;
|
|
4
|
+
export const PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS = commonJsModule.PRODUCT_ANALYTICS_SAVED_VIEW_PROBLEMS;
|
|
5
|
+
export const PRODUCT_ANALYTICS_SAVED_VIEW_TYPES = commonJsModule.PRODUCT_ANALYTICS_SAVED_VIEW_TYPES;
|
|
6
|
+
export const PRODUCT_ANALYTICS_SAVED_VIEW_URL_KEY = commonJsModule.PRODUCT_ANALYTICS_SAVED_VIEW_URL_KEY;
|
|
7
|
+
export const ProductAnalyticsSavedViewType = commonJsModule.ProductAnalyticsSavedViewType;
|
|
8
|
+
export const getProductAnalyticsSavedViewNameProblem = commonJsModule.getProductAnalyticsSavedViewNameProblem;
|
|
9
|
+
export const isProductAnalyticsSavedViewType = commonJsModule.isProductAnalyticsSavedViewType;
|
|
10
|
+
export const isSameProductAnalyticsDefinition = commonJsModule.isSameProductAnalyticsDefinition;
|
|
11
|
+
export const readProductAnalyticsFunnelDefinition = commonJsModule.readProductAnalyticsFunnelDefinition;
|
|
12
|
+
export const readProductAnalyticsRetentionDefinition = commonJsModule.readProductAnalyticsRetentionDefinition;
|
|
13
|
+
export const readProductAnalyticsSavedViewDefinition = commonJsModule.readProductAnalyticsSavedViewDefinition;
|
|
14
|
+
export const toProductAnalyticsSavedViewName = commonJsModule.toProductAnalyticsSavedViewName;
|
|
@@ -10,6 +10,7 @@ const IconProp_1 = __importDefault(require("../../Icon/IconProp"));
|
|
|
10
10
|
const ProviderLogo_1 = __importDefault(require("../../ProviderLogo/ProviderLogo"));
|
|
11
11
|
const GoogleSecOpsRegion_1 = require("../GoogleSecOpsRegion");
|
|
12
12
|
const SecurityEventConnectorProvider_1 = __importDefault(require("./SecurityEventConnectorProvider"));
|
|
13
|
+
const Translator_1 = require("../../Translator");
|
|
13
14
|
exports.SecurityEventConnectorCategories = ["SIEM", "EDR / XDR", "Cloud security", "Identity"];
|
|
14
15
|
/*
|
|
15
16
|
* The connection setting that closes a product's alerts when the security
|
|
@@ -561,13 +562,13 @@ exports.SecurityEventConnectorCatalog = [
|
|
|
561
562
|
defaultPollIntervalInMinutes: 5,
|
|
562
563
|
supportsAlertingOnlyToggle: true,
|
|
563
564
|
alertingOnlyControl: {
|
|
564
|
-
title: "Data to import",
|
|
565
|
-
description: "Alerts are always imported because Google's API always returns them. Select Detections to also import rule matches that did not generate an alert.",
|
|
566
|
-
alertingLabel: "Alerts",
|
|
567
|
-
alertingHint: "Google's alerts API always includes alerts.",
|
|
568
|
-
nonAlertingLabel: "Detections",
|
|
569
|
-
alertingOnlySummary: "Alerts only",
|
|
570
|
-
withNonAlertingSummary: "Alerts and detections",
|
|
565
|
+
title: (0, Translator_1.translationKey)("Data to import"),
|
|
566
|
+
description: (0, Translator_1.translationKey)("Alerts are always imported because Google's API always returns them. Select Detections to also import rule matches that did not generate an alert."),
|
|
567
|
+
alertingLabel: (0, Translator_1.translationKey)("Alerts"),
|
|
568
|
+
alertingHint: (0, Translator_1.translationKey)("Google's alerts API always includes alerts."),
|
|
569
|
+
nonAlertingLabel: (0, Translator_1.translationKey)("Detections"),
|
|
570
|
+
alertingOnlySummary: (0, Translator_1.translationKey)("Alerts only"),
|
|
571
|
+
withNonAlertingSummary: (0, Translator_1.translationKey)("Alerts and detections"),
|
|
571
572
|
},
|
|
572
573
|
importedRecordName: "detection",
|
|
573
574
|
cursorOverlapInMinutes: 1,
|
|
@@ -70,6 +70,12 @@ var ServiceType;
|
|
|
70
70
|
* billed as ingested telemetry.
|
|
71
71
|
*/
|
|
72
72
|
ServiceType["DataReconciliation"] = "DataReconciliation";
|
|
73
|
+
/*
|
|
74
|
+
* Data Observability's BI tool rows (oneuptime.data.bi.*): which of a
|
|
75
|
+
* Power BI tool's datasets failed their last refresh. Like table health,
|
|
76
|
+
* never billed as ingested telemetry.
|
|
77
|
+
*/
|
|
78
|
+
ServiceType["DataBiConnection"] = "DataBiConnection";
|
|
73
79
|
/*
|
|
74
80
|
* Telemetry that arrived without an OTel service.name and with no
|
|
75
81
|
* host / docker / k8s resource signal. Instead of synthesising a
|
package/Utils/Crypto.js
CHANGED
|
@@ -3,13 +3,20 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
|
|
6
|
+
/*
|
|
7
|
+
* The two hashes this class gives, not crypto-js's index: a public dashboard
|
|
8
|
+
* reaches it through its metric charts (Utils/Telemetry/EntityKey), and the
|
|
9
|
+
* index brings every cipher and hash crypto-js has (HashedString says what
|
|
10
|
+
* that weighs).
|
|
11
|
+
*/
|
|
12
|
+
const md5_1 = __importDefault(require("crypto-js/md5"));
|
|
13
|
+
const sha256_1 = __importDefault(require("crypto-js/sha256"));
|
|
7
14
|
class Crypto {
|
|
8
15
|
static getMd5Hash(text) {
|
|
9
|
-
return
|
|
16
|
+
return (0, md5_1.default)(text).toString();
|
|
10
17
|
}
|
|
11
18
|
static getSha256Hash(text) {
|
|
12
|
-
return
|
|
19
|
+
return (0, sha256_1.default)(text).toString();
|
|
13
20
|
}
|
|
14
21
|
}
|
|
15
22
|
exports.default = Crypto;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import DashboardProductAnalyticsFunnelComponent from "../../../Types/Dashboard/DashboardComponents/DashboardProductAnalyticsFunnelComponent.mjs";
|
|
2
|
+
import { ComponentArgument } from "../../../Types/Dashboard/DashboardComponents/ComponentArgument.mjs";
|
|
3
|
+
import DashboardBaseComponentUtil from "./DashboardBaseComponent.mjs";
|
|
4
|
+
export default class DashboardProductAnalyticsFunnelComponentUtil extends DashboardBaseComponentUtil {
|
|
5
|
+
static getDefaultComponent(): DashboardProductAnalyticsFunnelComponent;
|
|
6
|
+
static getComponentConfigArguments(): Array<ComponentArgument<DashboardProductAnalyticsFunnelComponent>>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import DashboardProductAnalyticsFunnelComponent from "../../../Types/Dashboard/DashboardComponents/DashboardProductAnalyticsFunnelComponent";
|
|
2
|
+
import { ComponentArgument } from "../../../Types/Dashboard/DashboardComponents/ComponentArgument";
|
|
3
|
+
import DashboardBaseComponentUtil from "./DashboardBaseComponent";
|
|
4
|
+
export default class DashboardProductAnalyticsFunnelComponentUtil extends DashboardBaseComponentUtil {
|
|
5
|
+
static getDefaultComponent(): DashboardProductAnalyticsFunnelComponent;
|
|
6
|
+
static getComponentConfigArguments(): Array<ComponentArgument<DashboardProductAnalyticsFunnelComponent>>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const ComponentArgument_1 = require("../../../Types/Dashboard/DashboardComponents/ComponentArgument");
|
|
7
|
+
const DashboardComponentType_1 = __importDefault(require("../../../Types/Dashboard/DashboardComponentType"));
|
|
8
|
+
const JSON_1 = require("../../../Types/JSON");
|
|
9
|
+
const ObjectID_1 = __importDefault(require("../../../Types/ObjectID"));
|
|
10
|
+
const DashboardBaseComponent_1 = __importDefault(require("./DashboardBaseComponent"));
|
|
11
|
+
const DataSourceSection = {
|
|
12
|
+
name: "Data Source",
|
|
13
|
+
description: "Pick a funnel saved on a RUM application's Funnels page",
|
|
14
|
+
order: 1,
|
|
15
|
+
};
|
|
16
|
+
const DisplaySection = {
|
|
17
|
+
name: "Display Options",
|
|
18
|
+
description: "Configure the widget heading",
|
|
19
|
+
order: 2,
|
|
20
|
+
};
|
|
21
|
+
/*
|
|
22
|
+
* The Funnel widget (issue #6630): a saved funnel, read with the
|
|
23
|
+
* dashboard's time range.
|
|
24
|
+
*/
|
|
25
|
+
class DashboardProductAnalyticsFunnelComponentUtil extends DashboardBaseComponent_1.default {
|
|
26
|
+
static getDefaultComponent() {
|
|
27
|
+
return {
|
|
28
|
+
_type: JSON_1.ObjectType.DashboardComponent,
|
|
29
|
+
componentType: DashboardComponentType_1.default.ProductAnalyticsFunnel,
|
|
30
|
+
/*
|
|
31
|
+
* A bar a step, up to six, each with its name, its people and its
|
|
32
|
+
* drop-off beside it: half a board wide and five rows tall.
|
|
33
|
+
*/
|
|
34
|
+
widthInDashboardUnits: 6,
|
|
35
|
+
heightInDashboardUnits: 5,
|
|
36
|
+
topInDashboardUnits: 0,
|
|
37
|
+
leftInDashboardUnits: 0,
|
|
38
|
+
componentId: ObjectID_1.default.generate(),
|
|
39
|
+
minHeightInDashboardUnits: 3,
|
|
40
|
+
minWidthInDashboardUnits: 3,
|
|
41
|
+
arguments: {},
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
static getComponentConfigArguments() {
|
|
45
|
+
return [
|
|
46
|
+
{
|
|
47
|
+
name: "Saved Funnel",
|
|
48
|
+
description: "The funnel this widget shows. Save one on a RUM application's Funnels page.",
|
|
49
|
+
required: true,
|
|
50
|
+
type: ComponentArgument_1.ComponentInputType.EntityDropdown,
|
|
51
|
+
id: "savedViewId",
|
|
52
|
+
placeholder: "Select a saved funnel",
|
|
53
|
+
section: DataSourceSection,
|
|
54
|
+
entityFilterModelType: ComponentArgument_1.EntityFilterModelType.ProductAnalyticsSavedFunnel,
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
name: "Title",
|
|
58
|
+
description: "Header shown above the funnel. Defaults to the saved funnel's name.",
|
|
59
|
+
required: false,
|
|
60
|
+
type: ComponentArgument_1.ComponentInputType.Text,
|
|
61
|
+
id: "title",
|
|
62
|
+
section: DisplaySection,
|
|
63
|
+
},
|
|
64
|
+
];
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
exports.default = DashboardProductAnalyticsFunnelComponentUtil;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import DashboardProductAnalyticsRetentionComponent from "../../../Types/Dashboard/DashboardComponents/DashboardProductAnalyticsRetentionComponent.mjs";
|
|
2
|
+
import { ComponentArgument } from "../../../Types/Dashboard/DashboardComponents/ComponentArgument.mjs";
|
|
3
|
+
import DashboardBaseComponentUtil from "./DashboardBaseComponent.mjs";
|
|
4
|
+
export default class DashboardProductAnalyticsRetentionComponentUtil extends DashboardBaseComponentUtil {
|
|
5
|
+
static getDefaultComponent(): DashboardProductAnalyticsRetentionComponent;
|
|
6
|
+
static getComponentConfigArguments(): Array<ComponentArgument<DashboardProductAnalyticsRetentionComponent>>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import DashboardProductAnalyticsRetentionComponent from "../../../Types/Dashboard/DashboardComponents/DashboardProductAnalyticsRetentionComponent";
|
|
2
|
+
import { ComponentArgument } from "../../../Types/Dashboard/DashboardComponents/ComponentArgument";
|
|
3
|
+
import DashboardBaseComponentUtil from "./DashboardBaseComponent";
|
|
4
|
+
export default class DashboardProductAnalyticsRetentionComponentUtil extends DashboardBaseComponentUtil {
|
|
5
|
+
static getDefaultComponent(): DashboardProductAnalyticsRetentionComponent;
|
|
6
|
+
static getComponentConfigArguments(): Array<ComponentArgument<DashboardProductAnalyticsRetentionComponent>>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const ComponentArgument_1 = require("../../../Types/Dashboard/DashboardComponents/ComponentArgument");
|
|
7
|
+
const DashboardComponentType_1 = __importDefault(require("../../../Types/Dashboard/DashboardComponentType"));
|
|
8
|
+
const JSON_1 = require("../../../Types/JSON");
|
|
9
|
+
const ObjectID_1 = __importDefault(require("../../../Types/ObjectID"));
|
|
10
|
+
const DashboardBaseComponent_1 = __importDefault(require("./DashboardBaseComponent"));
|
|
11
|
+
const DataSourceSection = {
|
|
12
|
+
name: "Data Source",
|
|
13
|
+
description: "Pick a retention table saved on a RUM application's User Retention page",
|
|
14
|
+
order: 1,
|
|
15
|
+
};
|
|
16
|
+
const DisplaySection = {
|
|
17
|
+
name: "Display Options",
|
|
18
|
+
description: "Configure the widget heading",
|
|
19
|
+
order: 2,
|
|
20
|
+
};
|
|
21
|
+
/*
|
|
22
|
+
* The Retention widget (issue #6630): a saved retention table, read with
|
|
23
|
+
* the dashboard's time range.
|
|
24
|
+
*/
|
|
25
|
+
class DashboardProductAnalyticsRetentionComponentUtil extends DashboardBaseComponent_1.default {
|
|
26
|
+
static getDefaultComponent() {
|
|
27
|
+
return {
|
|
28
|
+
_type: JSON_1.ObjectType.DashboardComponent,
|
|
29
|
+
componentType: DashboardComponentType_1.default.ProductAnalyticsRetention,
|
|
30
|
+
/*
|
|
31
|
+
* A row a cohort and a column a period, a month's weeks or a
|
|
32
|
+
* quarter's: wide, and tall enough for All cohorts and five cohorts
|
|
33
|
+
* before it scrolls.
|
|
34
|
+
*/
|
|
35
|
+
widthInDashboardUnits: 8,
|
|
36
|
+
heightInDashboardUnits: 5,
|
|
37
|
+
topInDashboardUnits: 0,
|
|
38
|
+
leftInDashboardUnits: 0,
|
|
39
|
+
componentId: ObjectID_1.default.generate(),
|
|
40
|
+
minHeightInDashboardUnits: 3,
|
|
41
|
+
minWidthInDashboardUnits: 4,
|
|
42
|
+
arguments: {},
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
static getComponentConfigArguments() {
|
|
46
|
+
return [
|
|
47
|
+
{
|
|
48
|
+
name: "Saved Retention Table",
|
|
49
|
+
description: "The retention table this widget shows. Save one on a RUM application's User Retention page.",
|
|
50
|
+
required: true,
|
|
51
|
+
type: ComponentArgument_1.ComponentInputType.EntityDropdown,
|
|
52
|
+
id: "savedViewId",
|
|
53
|
+
placeholder: "Select a saved retention table",
|
|
54
|
+
section: DataSourceSection,
|
|
55
|
+
entityFilterModelType: ComponentArgument_1.EntityFilterModelType.ProductAnalyticsSavedRetention,
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
name: "Title",
|
|
59
|
+
description: "Header shown above the table. Defaults to the saved table's name.",
|
|
60
|
+
required: false,
|
|
61
|
+
type: ComponentArgument_1.ComponentInputType.Text,
|
|
62
|
+
id: "title",
|
|
63
|
+
section: DisplaySection,
|
|
64
|
+
},
|
|
65
|
+
];
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
exports.default = DashboardProductAnalyticsRetentionComponentUtil;
|
|
@@ -43,11 +43,16 @@ exports.DASHBOARD_WIDGET_ID_LIST_SETTINGS = [
|
|
|
43
43
|
"cephClusterIds",
|
|
44
44
|
"storageArrayIds",
|
|
45
45
|
];
|
|
46
|
-
|
|
46
|
+
/*
|
|
47
|
+
* The settings that hold one id: of an SLO, of a dashboard variable, or of
|
|
48
|
+
* a saved funnel or retention table (the product analytics widgets, issue
|
|
49
|
+
* #6630).
|
|
50
|
+
*/
|
|
47
51
|
exports.DASHBOARD_WIDGET_ID_SETTINGS = [
|
|
48
52
|
"serviceLevelObjectiveId",
|
|
49
53
|
"serviceLevelObjectiveVariableId",
|
|
50
54
|
"labelVariableId",
|
|
55
|
+
"savedViewId",
|
|
51
56
|
];
|
|
52
57
|
class DashboardWidgetIds {
|
|
53
58
|
/*
|