@gooddata/sdk-backend-base 11.44.0-alpha.0 → 11.44.0-alpha.2
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/esm/cachingBackend/index.d.ts +19 -0
- package/esm/cachingBackend/index.d.ts.map +1 -1
- package/esm/cachingBackend/index.js +100 -0
- package/esm/decoratedBackend/analyticalWorkspace.d.ts.map +1 -1
- package/esm/decoratedBackend/analyticalWorkspace.js +4 -0
- package/esm/decoratedBackend/insights.d.ts +33 -0
- package/esm/decoratedBackend/insights.d.ts.map +1 -0
- package/esm/decoratedBackend/insights.js +59 -0
- package/esm/decoratedBackend/types.d.ts +6 -1
- package/esm/decoratedBackend/types.d.ts.map +1 -1
- package/esm/dummyBackend/index.js +0 -3
- package/esm/index.d.ts +2 -1
- package/esm/index.d.ts.map +1 -1
- package/esm/index.js +1 -0
- package/esm/sdk-backend-base.d.ts +68 -0
- package/package.json +7 -7
|
@@ -37,6 +37,10 @@ export type CacheControl = {
|
|
|
37
37
|
* Resets the export templates cache.
|
|
38
38
|
*/
|
|
39
39
|
resetExportTemplates: () => void;
|
|
40
|
+
/**
|
|
41
|
+
* Resets all workspace insight caches.
|
|
42
|
+
*/
|
|
43
|
+
resetInsights: () => void;
|
|
40
44
|
/**
|
|
41
45
|
* Convenience method to reset all caches (calls all the particular resets).
|
|
42
46
|
*/
|
|
@@ -201,6 +205,21 @@ export type CachingConfiguration = {
|
|
|
201
205
|
* When non-positive number is specified, then no caching will be done.
|
|
202
206
|
*/
|
|
203
207
|
maxAutomationsWorkspaces?: number;
|
|
208
|
+
/**
|
|
209
|
+
* Maximum number of insights to cache per workspace.
|
|
210
|
+
*
|
|
211
|
+
* Only the read-only, idempotent {@link @gooddata/sdk-backend-spi#IWorkspaceInsightsService.getInsight}
|
|
212
|
+
* call is cached. The insight reference (plus any options that change the response) is used as cache key.
|
|
213
|
+
* This mainly serves to de-duplicate in-flight requests so that concurrent dashboard widgets referencing
|
|
214
|
+
* the same insight share a single network request.
|
|
215
|
+
*
|
|
216
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
217
|
+
*
|
|
218
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen.
|
|
219
|
+
*
|
|
220
|
+
* When non-positive number is specified, then no caching of insights will be done.
|
|
221
|
+
*/
|
|
222
|
+
maxInsightsPerWorkspace?: number;
|
|
204
223
|
/**
|
|
205
224
|
* Maximum number of organizations for which to cache export templates.
|
|
206
225
|
* Export templates are organization-level, so typically a single entry suffices.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cachingBackend/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAGH,KAAK,kBAAkB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/cachingBackend/index.ts"],"names":[],"mappings":"AAQA,OAAO,EAGH,KAAK,kBAAkB,EA0C1B,MAAM,2BAA2B,CAAC;AAk9DnC;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG;IACvB;;;;;OAKG;IACH,eAAe,EAAE,MAAM,IAAI,CAAC;IAE5B;;OAEG;IACH,aAAa,EAAE,MAAM,IAAI,CAAC;IAE1B;;OAEG;IACH,qBAAqB,EAAE,MAAM,IAAI,CAAC;IAElC;;OAEG;IACH,eAAe,EAAE,MAAM,IAAI,CAAC;IAE5B;;OAEG;IACH,sBAAsB,EAAE,MAAM,IAAI,CAAC;IAEnC;;OAEG;IACH,cAAc,EAAE,MAAM,IAAI,CAAC;IAE3B;;OAEG;IACH,oBAAoB,EAAE,MAAM,IAAI,CAAC;IAEjC;;OAEG;IACH,aAAa,EAAE,MAAM,IAAI,CAAC;IAE1B;;OAEG;IACH,QAAQ,EAAE,MAAM,IAAI,CAAC;CACxB,CAAC;AAEF;;;;GAIG;AACH,MAAM,MAAM,oBAAoB,GAAG;IAC/B;;;;;;;;;;;;;;OAcG;IACH,aAAa,CAAC,EAAE,M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eAAO,MAAM,+BAA+B,EAAE,oBAkB7C,CAAC;AAEF;;;;;;;;GAQG;AACH,wBAAgB,WAAW,CACvB,WAAW,EAAE,kBAAkB,EAC/B,MAAM,EAAE,oBAAoB,GAC7B,kBAAkB,CAqFpB"}
|
|
@@ -12,6 +12,7 @@ import { DecoratedWorkspaceCatalogFactory } from "../decoratedBackend/catalog.js
|
|
|
12
12
|
import { DecoratedElementsQuery, DecoratedElementsQueryFactory } from "../decoratedBackend/elements.js";
|
|
13
13
|
import { DecoratedDataView, DecoratedExecutionFactory, DecoratedExecutionResult, DecoratedPreparedExecution, } from "../decoratedBackend/execution.js";
|
|
14
14
|
import { decoratedBackend } from "../decoratedBackend/index.js";
|
|
15
|
+
import { DecoratedWorkspaceInsightsService } from "../decoratedBackend/insights.js";
|
|
15
16
|
import { DecoratedOrganizationExportTemplatesService } from "../decoratedBackend/organizationExportTemplates.js";
|
|
16
17
|
import { DecoratedSecuritySettingsService } from "../decoratedBackend/securitySettings.js";
|
|
17
18
|
import { DecoratedWorkspaceSettingsService } from "../decoratedBackend/workspaceSettings.js";
|
|
@@ -1156,6 +1157,94 @@ class WithAutomationsCaching extends DecoratedWorkspaceAutomationsService {
|
|
|
1156
1157
|
}
|
|
1157
1158
|
}
|
|
1158
1159
|
//
|
|
1160
|
+
// INSIGHTS CACHING
|
|
1161
|
+
//
|
|
1162
|
+
function insightCacheKey(ref, options) {
|
|
1163
|
+
const fingerprint = stringify(options ?? {}) || "undefined";
|
|
1164
|
+
return new SparkMD5().append(objRefToString(ref)).append(fingerprint).end();
|
|
1165
|
+
}
|
|
1166
|
+
function getOrCreateInsightsCache(ctx, workspace) {
|
|
1167
|
+
const cache = ctx.caches.workspaceInsights;
|
|
1168
|
+
let cacheEntry = cache.get(workspace);
|
|
1169
|
+
if (!cacheEntry) {
|
|
1170
|
+
cacheEntry = {
|
|
1171
|
+
insights: new LRUCache({
|
|
1172
|
+
max: ctx.config.maxInsightsPerWorkspace,
|
|
1173
|
+
}),
|
|
1174
|
+
};
|
|
1175
|
+
cache.set(workspace, cacheEntry);
|
|
1176
|
+
}
|
|
1177
|
+
return cacheEntry;
|
|
1178
|
+
}
|
|
1179
|
+
class WithInsightsCaching extends DecoratedWorkspaceInsightsService {
|
|
1180
|
+
ctx;
|
|
1181
|
+
constructor(decorated, ctx, workspace) {
|
|
1182
|
+
super(decorated, workspace);
|
|
1183
|
+
this.ctx = ctx;
|
|
1184
|
+
}
|
|
1185
|
+
getInsight = (ref, options) => {
|
|
1186
|
+
const cache = getOrCreateInsightsCache(this.ctx, this.workspace).insights;
|
|
1187
|
+
const cacheKey = insightCacheKey(ref, options);
|
|
1188
|
+
let insight = cache.get(cacheKey);
|
|
1189
|
+
if (!insight) {
|
|
1190
|
+
insight = this.decorated.getInsight(ref, options).catch((e) => {
|
|
1191
|
+
cache.delete(cacheKey);
|
|
1192
|
+
throw e;
|
|
1193
|
+
});
|
|
1194
|
+
cache.set(cacheKey, insight);
|
|
1195
|
+
}
|
|
1196
|
+
return insight;
|
|
1197
|
+
};
|
|
1198
|
+
// Insight mutations are not cached, but they must invalidate the read cache so that edits
|
|
1199
|
+
// made during a session are never served stale (the SDK has no separate invalidation signal).
|
|
1200
|
+
async createInsight(insight) {
|
|
1201
|
+
try {
|
|
1202
|
+
return await super.createInsight(insight);
|
|
1203
|
+
}
|
|
1204
|
+
finally {
|
|
1205
|
+
this.invalidateCache();
|
|
1206
|
+
}
|
|
1207
|
+
}
|
|
1208
|
+
async updateInsight(insight) {
|
|
1209
|
+
try {
|
|
1210
|
+
return await super.updateInsight(insight);
|
|
1211
|
+
}
|
|
1212
|
+
finally {
|
|
1213
|
+
this.invalidateCache();
|
|
1214
|
+
}
|
|
1215
|
+
}
|
|
1216
|
+
async updateInsightMeta(insight) {
|
|
1217
|
+
try {
|
|
1218
|
+
return await super.updateInsightMeta(insight);
|
|
1219
|
+
}
|
|
1220
|
+
finally {
|
|
1221
|
+
this.invalidateCache();
|
|
1222
|
+
}
|
|
1223
|
+
}
|
|
1224
|
+
async setCertification(ref, certification) {
|
|
1225
|
+
try {
|
|
1226
|
+
await super.setCertification(ref, certification);
|
|
1227
|
+
}
|
|
1228
|
+
finally {
|
|
1229
|
+
this.invalidateCache();
|
|
1230
|
+
}
|
|
1231
|
+
}
|
|
1232
|
+
async deleteInsight(ref) {
|
|
1233
|
+
try {
|
|
1234
|
+
await super.deleteInsight(ref);
|
|
1235
|
+
}
|
|
1236
|
+
finally {
|
|
1237
|
+
this.invalidateCache();
|
|
1238
|
+
}
|
|
1239
|
+
}
|
|
1240
|
+
invalidateCache = () => {
|
|
1241
|
+
getOrCreateInsightsCache(this.ctx, this.workspace).insights.clear();
|
|
1242
|
+
};
|
|
1243
|
+
}
|
|
1244
|
+
function cachedInsights(ctx) {
|
|
1245
|
+
return (original, workspace) => new WithInsightsCaching(original, ctx, workspace);
|
|
1246
|
+
}
|
|
1247
|
+
//
|
|
1159
1248
|
// ORGANIZATION EXPORT TEMPLATES CACHING
|
|
1160
1249
|
//
|
|
1161
1250
|
class WithOrganizationExportTemplatesCaching extends DecoratedOrganizationExportTemplatesService {
|
|
@@ -1327,6 +1416,9 @@ function cacheControl(ctx) {
|
|
|
1327
1416
|
resetExportTemplates: () => {
|
|
1328
1417
|
ctx.caches.organizationExportTemplates?.clear();
|
|
1329
1418
|
},
|
|
1419
|
+
resetInsights: () => {
|
|
1420
|
+
ctx.caches.workspaceInsights?.clear();
|
|
1421
|
+
},
|
|
1330
1422
|
resetAll: () => {
|
|
1331
1423
|
control.resetExecutions();
|
|
1332
1424
|
control.resetCatalogs();
|
|
@@ -1335,6 +1427,7 @@ function cacheControl(ctx) {
|
|
|
1335
1427
|
control.resetWorkspaceSettings();
|
|
1336
1428
|
control.resetGeoStyles();
|
|
1337
1429
|
control.resetExportTemplates();
|
|
1430
|
+
control.resetInsights();
|
|
1338
1431
|
},
|
|
1339
1432
|
};
|
|
1340
1433
|
return control;
|
|
@@ -1365,6 +1458,7 @@ export const RecommendedCachingConfiguration = {
|
|
|
1365
1458
|
maxAttributeElementResultsPerWorkspace: 100,
|
|
1366
1459
|
maxWorkspaceSettings: 1,
|
|
1367
1460
|
maxAutomationsWorkspaces: 1,
|
|
1461
|
+
maxInsightsPerWorkspace: 50,
|
|
1368
1462
|
maxExportTemplatesOrgs: 1,
|
|
1369
1463
|
cacheGeoStyles: true,
|
|
1370
1464
|
};
|
|
@@ -1390,6 +1484,7 @@ export function withCaching(realBackend, config) {
|
|
|
1390
1484
|
const attributeCaching = cachingEnabled(config.maxAttributeWorkspaces);
|
|
1391
1485
|
const workspaceSettingsCaching = cachingEnabled(config.maxWorkspaceSettings);
|
|
1392
1486
|
const automationsCaching = cachingEnabled(config.maxAutomationsWorkspaces);
|
|
1487
|
+
const insightsCaching = cachingEnabled(config.maxInsightsPerWorkspace);
|
|
1393
1488
|
// Accept both the new and deprecated config names for backward compatibility
|
|
1394
1489
|
const exportTemplatesMaxOrgs = config.maxExportTemplatesOrgs ?? config.maxExportTemplatesWorkspaces;
|
|
1395
1490
|
const exportTemplatesCaching = cachingEnabled(exportTemplatesMaxOrgs);
|
|
@@ -1414,6 +1509,9 @@ export function withCaching(realBackend, config) {
|
|
|
1414
1509
|
workspaceAutomations: automationsCaching
|
|
1415
1510
|
? new LRUCache({ max: config.maxAutomationsWorkspaces })
|
|
1416
1511
|
: undefined,
|
|
1512
|
+
workspaceInsights: insightsCaching
|
|
1513
|
+
? new LRUCache({ max: config.maxInsightsPerWorkspace })
|
|
1514
|
+
: undefined,
|
|
1417
1515
|
organizationExportTemplates: exportTemplatesCaching
|
|
1418
1516
|
? new LRUCache({ max: exportTemplatesMaxOrgs })
|
|
1419
1517
|
: undefined,
|
|
@@ -1432,6 +1530,7 @@ export function withCaching(realBackend, config) {
|
|
|
1432
1530
|
const securitySettings = securitySettingsCaching ? cachedSecuritySettings(ctx) : (v) => v;
|
|
1433
1531
|
const attributes = attributeCaching ? cachedAttributes(ctx) : (v) => v;
|
|
1434
1532
|
const automations = automationsCaching ? cachedAutomations(ctx) : (v) => v;
|
|
1533
|
+
const insights = insightsCaching ? cachedInsights(ctx) : (v) => v;
|
|
1435
1534
|
const organizationExportTemplates = exportTemplatesCaching
|
|
1436
1535
|
? cachedOrganizationExportTemplates(ctx)
|
|
1437
1536
|
: undefined;
|
|
@@ -1447,6 +1546,7 @@ export function withCaching(realBackend, config) {
|
|
|
1447
1546
|
attributes,
|
|
1448
1547
|
workspaceSettings,
|
|
1449
1548
|
automations,
|
|
1549
|
+
insights,
|
|
1450
1550
|
organizationExportTemplates,
|
|
1451
1551
|
geo,
|
|
1452
1552
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"analyticalWorkspace.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/analyticalWorkspace.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,oBAAoB,EACzB,KAAK,4BAA4B,EACjC,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,iBAAiB,EACtB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,8BAA8B,EACnC,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,wBAAwB,EAC7B,KAAK,2BAA2B,EAChC,KAAK,yBAAyB,EAC9B,KAAK,oBAAoB,EACzB,KAAK,0BAA0B,EAC/B,KAAK,kCAAkC,EACvC,KAAK,sBAAsB,EAC3B,KAAK,yBAAyB,EAC9B,KAAK,kCAAkC,EACvC,KAAK,6BAA6B,EAClC,KAAK,yBAAyB,EAC9B,KAAK,kCAAkC,EACvC,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,yBAAyB,EAC9B,KAAK,oBAAoB,EAC5B,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAE,KAAK,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAErD,qBAAa,4BAA6B,YAAW,oBAAoB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7C;IAEM,aAAa,IAAI,8BAA8B,CAErD;IAEM,iBAAiB,IAAI,kCAAkC,CAE7D;IAEM,oBAAoB,IAAI,4BAA4B,CAE1D;IAEM,MAAM,IAAI,uBAAuB,CAEvC;IAEM,iBAAiB,IAAI,kCAAkC,CAE7D;IAEM,WAAW,IAAI,mBAAmB,CAExC;IAEM,YAAY,IAAI,6BAA6B,CAEnD;IAEM,WAAW,IAAI,2BAA2B,CAQhD;IAEM,KAAK,IAAI,aAAa,CAE5B;IAEM,UAAU,IAAI,kBAAkB,CAEtC;CACJ"}
|
|
@@ -51,6 +51,10 @@ export class AnalyticalWorkspaceDecorator {
|
|
|
51
51
|
return this.decorated.facts();
|
|
52
52
|
}
|
|
53
53
|
insights() {
|
|
54
|
+
const { insights } = this.factories;
|
|
55
|
+
if (insights) {
|
|
56
|
+
return insights(this.decorated.insights(), this.workspace);
|
|
57
|
+
}
|
|
54
58
|
return this.decorated.insights();
|
|
55
59
|
}
|
|
56
60
|
dashboards() {
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { type IGetInsightOptions, type IGetVisualizationClassesOptions, type IInsightReferences, type IInsightReferencing, type IInsightsQuery, type IInsightsQueryOptions, type IInsightsQueryResult, type IWorkspaceInsightsService, type SupportedInsightReferenceTypes } from "@gooddata/sdk-backend-spi";
|
|
2
|
+
import { type ICatalogAttribute, type ICatalogFact, type ICatalogMeasure, type IFilter, type IInsight, type IInsightDefinition, type IMetadataObjectBase, type IMetadataObjectIdentity, type IObjectCertificationWrite, type IVisualizationClass, type ObjRef } from "@gooddata/sdk-model";
|
|
3
|
+
/**
|
|
4
|
+
* Abstract base class for decorators of the {@link @gooddata/sdk-backend-spi#IWorkspaceInsightsService}.
|
|
5
|
+
*
|
|
6
|
+
* @remarks
|
|
7
|
+
* It delegates all the calls to the decorated service. Override the methods you want to enrich.
|
|
8
|
+
*
|
|
9
|
+
* @alpha
|
|
10
|
+
*/
|
|
11
|
+
export declare abstract class DecoratedWorkspaceInsightsService implements IWorkspaceInsightsService {
|
|
12
|
+
protected readonly decorated: IWorkspaceInsightsService;
|
|
13
|
+
readonly workspace: string;
|
|
14
|
+
protected constructor(decorated: IWorkspaceInsightsService, workspace: string);
|
|
15
|
+
getVisualizationClass(ref: ObjRef): Promise<IVisualizationClass>;
|
|
16
|
+
getVisualizationClasses(options?: IGetVisualizationClassesOptions): Promise<IVisualizationClass[]>;
|
|
17
|
+
getInsightWithCatalogItems(ref: ObjRef): Promise<{
|
|
18
|
+
insight: IInsight;
|
|
19
|
+
catalogItems: Array<ICatalogFact | ICatalogMeasure | ICatalogAttribute>;
|
|
20
|
+
}>;
|
|
21
|
+
getInsight(ref: ObjRef, options?: IGetInsightOptions): Promise<IInsight>;
|
|
22
|
+
getInsights(options?: IInsightsQueryOptions): Promise<IInsightsQueryResult>;
|
|
23
|
+
getInsightsQuery(): IInsightsQuery;
|
|
24
|
+
createInsight(insight: IInsightDefinition): Promise<IInsight>;
|
|
25
|
+
updateInsight(insight: IInsight): Promise<IInsight>;
|
|
26
|
+
updateInsightMeta(insight: Partial<IMetadataObjectBase> & IMetadataObjectIdentity): Promise<IInsight>;
|
|
27
|
+
setCertification(ref: ObjRef, certification?: IObjectCertificationWrite): Promise<void>;
|
|
28
|
+
deleteInsight(ref: ObjRef): Promise<void>;
|
|
29
|
+
getInsightReferencedObjects(insight: IInsight, types?: SupportedInsightReferenceTypes[]): Promise<IInsightReferences>;
|
|
30
|
+
getInsightReferencingObjects(ref: ObjRef): Promise<IInsightReferencing>;
|
|
31
|
+
getInsightWithAddedFilters<T extends IInsightDefinition>(insight: T, filters: IFilter[]): Promise<T>;
|
|
32
|
+
}
|
|
33
|
+
//# sourceMappingURL=insights.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"insights.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/insights.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,kBAAkB,EACvB,KAAK,+BAA+B,EACpC,KAA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AG,OAAO,CAAC,QAAQ,CAAC,CAEnE;IAEM,aAAa,CAAC,OAAO,EAAE,QAAQ,GAAG,OAAO,CAAC,QAAQ,CAAC,CAEzD;IAEM,iBAAiB,CACpB,OAAO,EAAE,OAAO,CAAC,mBAAmB,CAAC,GAAG,uBAAuB,GAChE,OAAO,CAAC,QAAQ,CAAC,CAEnB;IAEM,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,aAAa,CAAC,EAAE,yBAAyB,GAAG,OAAO,CAAC,IAAI,CAAC,CAE7F;IAEM,aAAa,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAE/C;IAEM,2BAA2B,CAC9B,OAAO,EAAE,QAAQ,EACjB,KAAK,CAAC,EAAE,8BAA8B,EAAE,GACzC,OAAO,CAAC,kBAAkB,CAAC,CAE7B;IAEM,4BAA4B,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAE7E;IAEM,0BAA0B,CAAC,CAAC,SAAS,kBAAkB,EAC1D,OAAO,EAAE,CAAC,EACV,OAAO,EAAE,OAAO,EAAE,GACnB,OAAO,CAAC,CAAC,CAAC,CAEZ;CACJ"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
// (C) 2024-2026 GoodData Corporation
|
|
2
|
+
/**
|
|
3
|
+
* Abstract base class for decorators of the {@link @gooddata/sdk-backend-spi#IWorkspaceInsightsService}.
|
|
4
|
+
*
|
|
5
|
+
* @remarks
|
|
6
|
+
* It delegates all the calls to the decorated service. Override the methods you want to enrich.
|
|
7
|
+
*
|
|
8
|
+
* @alpha
|
|
9
|
+
*/
|
|
10
|
+
export class DecoratedWorkspaceInsightsService {
|
|
11
|
+
decorated;
|
|
12
|
+
workspace;
|
|
13
|
+
constructor(decorated, workspace) {
|
|
14
|
+
this.decorated = decorated;
|
|
15
|
+
this.workspace = workspace;
|
|
16
|
+
}
|
|
17
|
+
getVisualizationClass(ref) {
|
|
18
|
+
return this.decorated.getVisualizationClass(ref);
|
|
19
|
+
}
|
|
20
|
+
getVisualizationClasses(options) {
|
|
21
|
+
return this.decorated.getVisualizationClasses(options);
|
|
22
|
+
}
|
|
23
|
+
getInsightWithCatalogItems(ref) {
|
|
24
|
+
return this.decorated.getInsightWithCatalogItems(ref);
|
|
25
|
+
}
|
|
26
|
+
getInsight(ref, options) {
|
|
27
|
+
return this.decorated.getInsight(ref, options);
|
|
28
|
+
}
|
|
29
|
+
getInsights(options) {
|
|
30
|
+
return this.decorated.getInsights(options);
|
|
31
|
+
}
|
|
32
|
+
getInsightsQuery() {
|
|
33
|
+
return this.decorated.getInsightsQuery();
|
|
34
|
+
}
|
|
35
|
+
createInsight(insight) {
|
|
36
|
+
return this.decorated.createInsight(insight);
|
|
37
|
+
}
|
|
38
|
+
updateInsight(insight) {
|
|
39
|
+
return this.decorated.updateInsight(insight);
|
|
40
|
+
}
|
|
41
|
+
updateInsightMeta(insight) {
|
|
42
|
+
return this.decorated.updateInsightMeta(insight);
|
|
43
|
+
}
|
|
44
|
+
setCertification(ref, certification) {
|
|
45
|
+
return this.decorated.setCertification(ref, certification);
|
|
46
|
+
}
|
|
47
|
+
deleteInsight(ref) {
|
|
48
|
+
return this.decorated.deleteInsight(ref);
|
|
49
|
+
}
|
|
50
|
+
getInsightReferencedObjects(insight, types) {
|
|
51
|
+
return this.decorated.getInsightReferencedObjects(insight, types);
|
|
52
|
+
}
|
|
53
|
+
getInsightReferencingObjects(ref) {
|
|
54
|
+
return this.decorated.getInsightReferencingObjects(ref);
|
|
55
|
+
}
|
|
56
|
+
getInsightWithAddedFilters(insight, filters) {
|
|
57
|
+
return this.decorated.getInsightWithAddedFilters(insight, filters);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type IExecutionFactory, type IGeoService, type IOrganizationExportTemplatesService, type ISecuritySettingsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceDashboardsService, type IWorkspaceSettingsService } from "@gooddata/sdk-backend-spi";
|
|
1
|
+
import { type IExecutionFactory, type IGeoService, type IOrganizationExportTemplatesService, type ISecuritySettingsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceDashboardsService, type IWorkspaceInsightsService, type IWorkspaceSettingsService } from "@gooddata/sdk-backend-spi";
|
|
2
2
|
/**
|
|
3
3
|
* @alpha
|
|
4
4
|
*/
|
|
@@ -27,6 +27,10 @@ export type AutomationsDecoratorFactory = (automations: IWorkspaceAutomationServ
|
|
|
27
27
|
* @alpha
|
|
28
28
|
*/
|
|
29
29
|
export type DashboardsDecoratorFactory = (dashboards: IWorkspaceDashboardsService, workspace: string) => IWorkspaceDashboardsService;
|
|
30
|
+
/**
|
|
31
|
+
* @alpha
|
|
32
|
+
*/
|
|
33
|
+
export type InsightsDecoratorFactory = (insights: IWorkspaceInsightsService, workspace: string) => IWorkspaceInsightsService;
|
|
30
34
|
/**
|
|
31
35
|
* @alpha
|
|
32
36
|
*/
|
|
@@ -49,6 +53,7 @@ export type DecoratorFactories = {
|
|
|
49
53
|
workspaceSettings?: WorkspaceSettingsDecoratorFactory;
|
|
50
54
|
attributes?: AttributesDecoratorFactory;
|
|
51
55
|
automations?: AutomationsDecoratorFactory;
|
|
56
|
+
insights?: InsightsDecoratorFactory;
|
|
52
57
|
dashboards?: DashboardsDecoratorFactory;
|
|
53
58
|
geo?: GeoDecoratorFactory;
|
|
54
59
|
organizationExportTemplates?: OrganizationExportTemplatesDecoratorFactory;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/types.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,KAAK,mCAAmC,EACxC,KAAK,wBAAwB,EAC7B,KAAK,2BAA2B,EAChC,KAAK,2BAA2B,EAChC,KAAK,wBAAwB,E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AAU,EAAE,2BAA2B,EACvC,SAAS,EAAE,MAAM,KAChB,2BAA2B,CAAC;AAEjC;;GAEG;AACH,MAAM,MAAM,wBAAwB,GAAG,CACnC,QAAQ,EAAE,yBAAyB,EACnC,SAAS,EAAE,MAAM,KAChB,yBAAyB,CAAC;AAE/B;;GAEG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,GAAG,EAAE,WAAW,KAAK,WAAW,CAAC;AAEpE;;GAEG;AACH,MAAM,MAAM,2CAA2C,GAAG,CACtD,eAAe,EAAE,mCAAmC,EACpD,cAAc,EAAE,MAAM,KACrB,mCAAmC,CAAC;AAEzC;;;;;;GAMG;AACH,MAAM,MAAM,kBAAkB,GAAG;IAC7B,SAAS,CAAC,EAAE,yBAAyB,CAAC;IACtC,OAAO,CAAC,EAAE,uBAAuB,CAAC;IAClC,gBAAgB,CAAC,EAAE,gCAAgC,CAAC;IACpD,iBAAiB,CAAC,EAAE,iCAAiC,CAAC;IACtD,UAAU,CAAC,EAAE,0BAA0B,CAAC;IACxC,WAAW,CAAC,EAAE,2BAA2B,CAAC;IAC1C,QAAQ,CAAC,EAAE,wBAAwB,CAAC;IACpC,UAAU,CAAC,EAAE,0BAA0B,CAAC;IACxC,GAAG,CAAC,EAAE,mBAAmB,CAAC;IAC1B,2BAA2B,CAAC,EAAE,2CAA2C,CAAC;CAC7E,CAAC"}
|
|
@@ -289,9 +289,6 @@ function dummyWorkspace(workspace, config) {
|
|
|
289
289
|
getSemanticSearchQuery() {
|
|
290
290
|
return new DummySemanticSearchQueryBuilder(workspace);
|
|
291
291
|
},
|
|
292
|
-
semanticSearchIndex() {
|
|
293
|
-
throw new NotSupported("not supported");
|
|
294
|
-
},
|
|
295
292
|
getLlmConfigured() {
|
|
296
293
|
throw new NotSupported("not supported");
|
|
297
294
|
},
|
package/esm/index.d.ts
CHANGED
|
@@ -12,9 +12,10 @@ export { type DummyBackendConfig, dummyBackend, dummyBackendEmptyData, dummyData
|
|
|
12
12
|
export { DummySemanticSearchQueryBuilder } from "./dummyBackend/DummySemanticSearch.js";
|
|
13
13
|
export { DummyGenAIChatThread, DummyChatConversations } from "./dummyBackend/DummyGenAIChatThread.js";
|
|
14
14
|
export { decoratedBackend } from "./decoratedBackend/index.js";
|
|
15
|
-
export type { DecoratorFactories, CatalogDecoratorFactory, ExecutionDecoratorFactory, SecuritySettingsDecoratorFactory, WorkspaceSettingsDecoratorFactory, AutomationsDecoratorFactory, AttributesDecoratorFactory, DashboardsDecoratorFactory, GeoDecoratorFactory, OrganizationExportTemplatesDecoratorFactory, } from "./decoratedBackend/types.js";
|
|
15
|
+
export type { DecoratorFactories, CatalogDecoratorFactory, ExecutionDecoratorFactory, SecuritySettingsDecoratorFactory, WorkspaceSettingsDecoratorFactory, AutomationsDecoratorFactory, AttributesDecoratorFactory, InsightsDecoratorFactory, DashboardsDecoratorFactory, GeoDecoratorFactory, OrganizationExportTemplatesDecoratorFactory, } from "./decoratedBackend/types.js";
|
|
16
16
|
export { type PreparedExecutionWrapper, DecoratedExecutionFactory, DecoratedPreparedExecution, DecoratedExecutionResult, } from "./decoratedBackend/execution.js";
|
|
17
17
|
export { DecoratedWorkspaceDashboardsService } from "./decoratedBackend/dashboards.js";
|
|
18
|
+
export { DecoratedWorkspaceInsightsService } from "./decoratedBackend/insights.js";
|
|
18
19
|
export { type WorkspaceCatalogWrapper, DecoratedWorkspaceCatalogFactory, DecoratedWorkspaceCatalog, } from "./decoratedBackend/catalog.js";
|
|
19
20
|
export { DecoratedSecuritySettingsService } from "./decoratedBackend/securitySettings.js";
|
|
20
21
|
export { DecoratedOrganizationExportTemplatesService } from "./decoratedBackend/organizationExportTemplates.js";
|
package/esm/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAIA;;;;;;;;;GASG;AACH,OAAO,EACH,KAAK,kBAAkB,EACvB,YAAY,EACZ,qBAAqB,EACrB,a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EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAE9G,OAAO,EAAE,iCAAiC,EAAE,MAAM,2CAA2C,CAAC"}
|
package/esm/index.js
CHANGED
|
@@ -16,6 +16,7 @@ export { DummyGenAIChatThread, DummyChatConversations } from "./dummyBackend/Dum
|
|
|
16
16
|
export { decoratedBackend } from "./decoratedBackend/index.js";
|
|
17
17
|
export { DecoratedExecutionFactory, DecoratedPreparedExecution, DecoratedExecutionResult, } from "./decoratedBackend/execution.js";
|
|
18
18
|
export { DecoratedWorkspaceDashboardsService } from "./decoratedBackend/dashboards.js";
|
|
19
|
+
export { DecoratedWorkspaceInsightsService } from "./decoratedBackend/insights.js";
|
|
19
20
|
export { DecoratedWorkspaceCatalogFactory, DecoratedWorkspaceCatalog, } from "./decoratedBackend/catalog.js";
|
|
20
21
|
export { DecoratedSecuritySettingsService } from "./decoratedBackend/securitySettings.js";
|
|
21
22
|
export { DecoratedOrganizationExportTemplatesService } from "./decoratedBackend/organizationExportTemplates.js";
|
|
@@ -103,10 +103,17 @@ import { IForecastResult } from '@gooddata/sdk-backend-spi';
|
|
|
103
103
|
import { IGeoService } from '@gooddata/sdk-backend-spi';
|
|
104
104
|
import { IGetDashboardOptions } from '@gooddata/sdk-backend-spi';
|
|
105
105
|
import { IGetDashboardPluginOptions } from '@gooddata/sdk-backend-spi';
|
|
106
|
+
import { IGetInsightOptions } from '@gooddata/sdk-backend-spi';
|
|
106
107
|
import { IGetScheduledMailOptions } from '@gooddata/sdk-backend-spi';
|
|
108
|
+
import { IGetVisualizationClassesOptions } from '@gooddata/sdk-backend-spi';
|
|
107
109
|
import { IGroupableCatalogItemBase } from '@gooddata/sdk-model';
|
|
108
110
|
import { IInsight } from '@gooddata/sdk-model';
|
|
109
111
|
import { IInsightDefinition } from '@gooddata/sdk-model';
|
|
112
|
+
import { IInsightReferences } from '@gooddata/sdk-backend-spi';
|
|
113
|
+
import { IInsightReferencing } from '@gooddata/sdk-backend-spi';
|
|
114
|
+
import { IInsightsQuery } from '@gooddata/sdk-backend-spi';
|
|
115
|
+
import { IInsightsQueryOptions } from '@gooddata/sdk-backend-spi';
|
|
116
|
+
import { IInsightsQueryResult } from '@gooddata/sdk-backend-spi';
|
|
110
117
|
import { IInsightWidget } from '@gooddata/sdk-model';
|
|
111
118
|
import { IInsightWidgetDefinition } from '@gooddata/sdk-model';
|
|
112
119
|
import { IKpi } from '@gooddata/sdk-model';
|
|
@@ -118,6 +125,8 @@ import { IListedDashboard } from '@gooddata/sdk-model';
|
|
|
118
125
|
import { IMeasure } from '@gooddata/sdk-model';
|
|
119
126
|
import { IMeasureMetadataObject } from '@gooddata/sdk-model';
|
|
120
127
|
import { IMetadataObject } from '@gooddata/sdk-model';
|
|
128
|
+
import { IMetadataObjectBase } from '@gooddata/sdk-model';
|
|
129
|
+
import { IMetadataObjectIdentity } from '@gooddata/sdk-model';
|
|
121
130
|
import { IMetricFormatOverrideSetting } from '@gooddata/sdk-model';
|
|
122
131
|
import { InsightDrillDefinition } from '@gooddata/sdk-model';
|
|
123
132
|
import { INullableFilter } from '@gooddata/sdk-model';
|
|
@@ -143,6 +152,7 @@ import { ISortItem } from '@gooddata/sdk-model';
|
|
|
143
152
|
import { IUser } from '@gooddata/sdk-model';
|
|
144
153
|
import { IUserWorkspaceSettings } from '@gooddata/sdk-backend-spi';
|
|
145
154
|
import { IVariableMetadataObject } from '@gooddata/sdk-model';
|
|
155
|
+
import { IVisualizationClass } from '@gooddata/sdk-model';
|
|
146
156
|
import { IWidget } from '@gooddata/sdk-model';
|
|
147
157
|
import { IWidgetAlert } from '@gooddata/sdk-model';
|
|
148
158
|
import { IWidgetAlertCount } from '@gooddata/sdk-backend-spi';
|
|
@@ -155,6 +165,7 @@ import { IWorkspaceCatalogAvailableItemsFactory } from '@gooddata/sdk-backend-sp
|
|
|
155
165
|
import { IWorkspaceCatalogFactory } from '@gooddata/sdk-backend-spi';
|
|
156
166
|
import { IWorkspaceCatalogFactoryOptions } from '@gooddata/sdk-backend-spi';
|
|
157
167
|
import { IWorkspaceDashboardsService } from '@gooddata/sdk-backend-spi';
|
|
168
|
+
import { IWorkspaceInsightsService } from '@gooddata/sdk-backend-spi';
|
|
158
169
|
import { IWorkspaceSettings } from '@gooddata/sdk-backend-spi';
|
|
159
170
|
import { IWorkspaceSettingsService } from '@gooddata/sdk-backend-spi';
|
|
160
171
|
import { KpiDrillDefinition } from '@gooddata/sdk-model';
|
|
@@ -164,6 +175,7 @@ import { MetricType } from '@gooddata/sdk-model';
|
|
|
164
175
|
import { NotAuthenticated } from '@gooddata/sdk-backend-spi';
|
|
165
176
|
import { ObjRef } from '@gooddata/sdk-model';
|
|
166
177
|
import { SupportedDashboardReferenceTypes } from '@gooddata/sdk-backend-spi';
|
|
178
|
+
import { SupportedInsightReferenceTypes } from '@gooddata/sdk-backend-spi';
|
|
167
179
|
import { SupportedWidgetReferenceTypes } from '@gooddata/sdk-backend-spi';
|
|
168
180
|
import { ValidationContext } from '@gooddata/sdk-backend-spi';
|
|
169
181
|
import { VisualizationProperties } from '@gooddata/sdk-model';
|
|
@@ -452,6 +464,10 @@ export declare type CacheControl = {
|
|
|
452
464
|
* Resets the export templates cache.
|
|
453
465
|
*/
|
|
454
466
|
resetExportTemplates: () => void;
|
|
467
|
+
/**
|
|
468
|
+
* Resets all workspace insight caches.
|
|
469
|
+
*/
|
|
470
|
+
resetInsights: () => void;
|
|
455
471
|
/**
|
|
456
472
|
* Convenience method to reset all caches (calls all the particular resets).
|
|
457
473
|
*/
|
|
@@ -617,6 +633,21 @@ export declare type CachingConfiguration = {
|
|
|
617
633
|
* When non-positive number is specified, then no caching will be done.
|
|
618
634
|
*/
|
|
619
635
|
maxAutomationsWorkspaces?: number;
|
|
636
|
+
/**
|
|
637
|
+
* Maximum number of insights to cache per workspace.
|
|
638
|
+
*
|
|
639
|
+
* Only the read-only, idempotent {@link @gooddata/sdk-backend-spi#IWorkspaceInsightsService.getInsight}
|
|
640
|
+
* call is cached. The insight reference (plus any options that change the response) is used as cache key.
|
|
641
|
+
* This mainly serves to de-duplicate in-flight requests so that concurrent dashboard widgets referencing
|
|
642
|
+
* the same insight share a single network request.
|
|
643
|
+
*
|
|
644
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
645
|
+
*
|
|
646
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen.
|
|
647
|
+
*
|
|
648
|
+
* When non-positive number is specified, then no caching of insights will be done.
|
|
649
|
+
*/
|
|
650
|
+
maxInsightsPerWorkspace?: number;
|
|
620
651
|
/**
|
|
621
652
|
* Maximum number of organizations for which to cache export templates.
|
|
622
653
|
* Export templates are organization-level, so typically a single entry suffices.
|
|
@@ -1191,6 +1222,37 @@ export declare abstract class DecoratedWorkspaceDashboardsService implements IWo
|
|
|
1191
1222
|
setFilterViewAsDefault(ref: ObjRef, isDefault: boolean): Promise<void>;
|
|
1192
1223
|
}
|
|
1193
1224
|
|
|
1225
|
+
/**
|
|
1226
|
+
* Abstract base class for decorators of the {@link @gooddata/sdk-backend-spi#IWorkspaceInsightsService}.
|
|
1227
|
+
*
|
|
1228
|
+
* @remarks
|
|
1229
|
+
* It delegates all the calls to the decorated service. Override the methods you want to enrich.
|
|
1230
|
+
*
|
|
1231
|
+
* @alpha
|
|
1232
|
+
*/
|
|
1233
|
+
export declare abstract class DecoratedWorkspaceInsightsService implements IWorkspaceInsightsService {
|
|
1234
|
+
protected readonly decorated: IWorkspaceInsightsService;
|
|
1235
|
+
readonly workspace: string;
|
|
1236
|
+
protected constructor(decorated: IWorkspaceInsightsService, workspace: string);
|
|
1237
|
+
getVisualizationClass(ref: ObjRef): Promise<IVisualizationClass>;
|
|
1238
|
+
getVisualizationClasses(options?: IGetVisualizationClassesOptions): Promise<IVisualizationClass[]>;
|
|
1239
|
+
getInsightWithCatalogItems(ref: ObjRef): Promise<{
|
|
1240
|
+
insight: IInsight;
|
|
1241
|
+
catalogItems: Array<ICatalogFact | ICatalogMeasure | ICatalogAttribute>;
|
|
1242
|
+
}>;
|
|
1243
|
+
getInsight(ref: ObjRef, options?: IGetInsightOptions): Promise<IInsight>;
|
|
1244
|
+
getInsights(options?: IInsightsQueryOptions): Promise<IInsightsQueryResult>;
|
|
1245
|
+
getInsightsQuery(): IInsightsQuery;
|
|
1246
|
+
createInsight(insight: IInsightDefinition): Promise<IInsight>;
|
|
1247
|
+
updateInsight(insight: IInsight): Promise<IInsight>;
|
|
1248
|
+
updateInsightMeta(insight: Partial<IMetadataObjectBase> & IMetadataObjectIdentity): Promise<IInsight>;
|
|
1249
|
+
setCertification(ref: ObjRef, certification?: IObjectCertificationWrite): Promise<void>;
|
|
1250
|
+
deleteInsight(ref: ObjRef): Promise<void>;
|
|
1251
|
+
getInsightReferencedObjects(insight: IInsight, types?: SupportedInsightReferenceTypes[]): Promise<IInsightReferences>;
|
|
1252
|
+
getInsightReferencingObjects(ref: ObjRef): Promise<IInsightReferencing>;
|
|
1253
|
+
getInsightWithAddedFilters<T extends IInsightDefinition>(insight: T, filters: IFilter[]): Promise<T>;
|
|
1254
|
+
}
|
|
1255
|
+
|
|
1194
1256
|
/**
|
|
1195
1257
|
* @alpha
|
|
1196
1258
|
*/
|
|
@@ -1246,6 +1308,7 @@ export declare type DecoratorFactories = {
|
|
|
1246
1308
|
workspaceSettings?: WorkspaceSettingsDecoratorFactory;
|
|
1247
1309
|
attributes?: AttributesDecoratorFactory;
|
|
1248
1310
|
automations?: AutomationsDecoratorFactory;
|
|
1311
|
+
insights?: InsightsDecoratorFactory;
|
|
1249
1312
|
dashboards?: DashboardsDecoratorFactory;
|
|
1250
1313
|
geo?: GeoDecoratorFactory;
|
|
1251
1314
|
organizationExportTemplates?: OrganizationExportTemplatesDecoratorFactory;
|
|
@@ -1678,6 +1741,11 @@ export declare interface INormalizerOptions {
|
|
|
1678
1741
|
keepRemovableProperties?: boolean;
|
|
1679
1742
|
}
|
|
1680
1743
|
|
|
1744
|
+
/**
|
|
1745
|
+
* @alpha
|
|
1746
|
+
*/
|
|
1747
|
+
export declare type InsightsDecoratorFactory = (insights: IWorkspaceInsightsService, workspace: string) => IWorkspaceInsightsService;
|
|
1748
|
+
|
|
1681
1749
|
/**
|
|
1682
1750
|
* @alpha
|
|
1683
1751
|
*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gooddata/sdk-backend-base",
|
|
3
|
-
"version": "11.44.0-alpha.
|
|
3
|
+
"version": "11.44.0-alpha.2",
|
|
4
4
|
"description": "GoodData.UI SDK - Base for backend implementations",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "GoodData",
|
|
@@ -29,9 +29,9 @@
|
|
|
29
29
|
"ts-invariant": "0.10.3",
|
|
30
30
|
"tslib": "2.8.1",
|
|
31
31
|
"uuid": "11.1.1",
|
|
32
|
-
"@gooddata/sdk-backend-spi": "11.44.0-alpha.
|
|
33
|
-
"@gooddata/sdk-model": "11.44.0-alpha.
|
|
34
|
-
"@gooddata/util": "11.44.0-alpha.
|
|
32
|
+
"@gooddata/sdk-backend-spi": "11.44.0-alpha.2",
|
|
33
|
+
"@gooddata/sdk-model": "11.44.0-alpha.2",
|
|
34
|
+
"@gooddata/util": "11.44.0-alpha.2"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"@microsoft/api-documenter": "^7.17.0",
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
"oxlint-tsgolint": "0.15.0",
|
|
57
57
|
"typescript": "5.9.3",
|
|
58
58
|
"vitest": "4.1.8",
|
|
59
|
-
"@gooddata/
|
|
60
|
-
"@gooddata/
|
|
61
|
-
"@gooddata/reference-workspace": "11.44.0-alpha.
|
|
59
|
+
"@gooddata/oxlint-config": "11.44.0-alpha.2",
|
|
60
|
+
"@gooddata/eslint-config": "11.44.0-alpha.2",
|
|
61
|
+
"@gooddata/reference-workspace": "11.44.0-alpha.2"
|
|
62
62
|
},
|
|
63
63
|
"scripts": {
|
|
64
64
|
"_phase:build": "npm run build",
|