@gooddata/sdk-backend-base 11.48.0-alpha.3 → 11.48.0-alpha.5
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 +65 -0
- package/esm/cachingBackend/index.d.ts.map +1 -1
- package/esm/cachingBackend/index.js +186 -0
- package/esm/decoratedBackend/analyticalWorkspace.d.ts.map +1 -1
- package/esm/decoratedBackend/analyticalWorkspace.js +8 -0
- package/esm/decoratedBackend/facts.d.ts +16 -0
- package/esm/decoratedBackend/facts.d.ts.map +1 -0
- package/esm/decoratedBackend/facts.js +22 -0
- package/esm/decoratedBackend/measures.d.ts +23 -0
- package/esm/decoratedBackend/measures.d.ts.map +1 -0
- package/esm/decoratedBackend/measures.js +43 -0
- package/esm/decoratedBackend/types.d.ts +11 -1
- package/esm/decoratedBackend/types.d.ts.map +1 -1
- package/esm/index.d.ts +1 -1
- package/esm/index.d.ts.map +1 -1
- package/esm/sdk-backend-base.d.ts +79 -0
- package/package.json +7 -7
|
@@ -25,6 +25,10 @@ export type CacheControl = {
|
|
|
25
25
|
* Resets all workspace attribute caches.
|
|
26
26
|
*/
|
|
27
27
|
resetAttributes: () => void;
|
|
28
|
+
/**
|
|
29
|
+
* Resets all workspace facts caches.
|
|
30
|
+
*/
|
|
31
|
+
resetFacts: () => void;
|
|
28
32
|
/**
|
|
29
33
|
* Resets all workspace settings caches.
|
|
30
34
|
*/
|
|
@@ -41,6 +45,10 @@ export type CacheControl = {
|
|
|
41
45
|
* Resets all workspace insight caches.
|
|
42
46
|
*/
|
|
43
47
|
resetInsights: () => void;
|
|
48
|
+
/**
|
|
49
|
+
* Resets all workspace measures caches.
|
|
50
|
+
*/
|
|
51
|
+
resetMeasures: () => void;
|
|
44
52
|
/**
|
|
45
53
|
* Convenience method to reset all caches (calls all the particular resets).
|
|
46
54
|
*/
|
|
@@ -220,6 +228,63 @@ export type CachingConfiguration = {
|
|
|
220
228
|
* When non-positive number is specified, then no caching of insights will be done.
|
|
221
229
|
*/
|
|
222
230
|
maxInsightsPerWorkspace?: number;
|
|
231
|
+
/**
|
|
232
|
+
* Maximum number of workspaces for which to cache selected {@link @gooddata/sdk-backend-spi#IWorkspaceFactsService} calls.
|
|
233
|
+
* The workspace identifier is used as cache key.
|
|
234
|
+
* For each workspace, there will be a cache entry holding `maxFactsPerWorkspace` entries for fact-related calls.
|
|
235
|
+
*
|
|
236
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
237
|
+
*
|
|
238
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
239
|
+
* cache may be OK in applications where number of workspaces is small - the cache will be limited
|
|
240
|
+
* naturally and will not grow uncontrollably.
|
|
241
|
+
*
|
|
242
|
+
* When non-positive number is specified, then no caching will be done.
|
|
243
|
+
*/
|
|
244
|
+
maxFactsWorkspaces?: number;
|
|
245
|
+
/**
|
|
246
|
+
* Maximum number of facts to cache per workspace.
|
|
247
|
+
*
|
|
248
|
+
* This limit applies independently to the cache of facts (`getFact`) and the cache of fact dataset
|
|
249
|
+
* metadata (`getFactDatasetMeta`).
|
|
250
|
+
*
|
|
251
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
252
|
+
*
|
|
253
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
254
|
+
* facts cache may be OK in applications where number of facts is small and/or they are requested
|
|
255
|
+
* infrequently - the cache will be limited naturally and will not grow uncontrollably.
|
|
256
|
+
*
|
|
257
|
+
* Setting non-positive number here is invalid. If you want to turn off facts caching,
|
|
258
|
+
* tweak the `maxFactsWorkspaces` value.
|
|
259
|
+
*/
|
|
260
|
+
maxFactsPerWorkspace?: number;
|
|
261
|
+
/**
|
|
262
|
+
* Maximum number of workspaces for which to cache selected {@link @gooddata/sdk-backend-spi#IWorkspaceMeasuresService} calls.
|
|
263
|
+
* The workspace identifier is used as cache key.
|
|
264
|
+
* For each workspace, there will be a cache entry holding `maxMeasuresPerWorkspace` entries.
|
|
265
|
+
*
|
|
266
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
267
|
+
*
|
|
268
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
269
|
+
* cache may be OK in applications where number of workspaces is small - the cache will be limited
|
|
270
|
+
* naturally and will not grow uncontrollably.
|
|
271
|
+
*
|
|
272
|
+
* When non-positive number is specified, then no caching will be done.
|
|
273
|
+
*/
|
|
274
|
+
maxMeasuresWorkspaces?: number;
|
|
275
|
+
/**
|
|
276
|
+
* Maximum number of measures to cache per workspace.
|
|
277
|
+
*
|
|
278
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
279
|
+
*
|
|
280
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
281
|
+
* measures cache may be OK in applications where number of measures is small and/or they are requested
|
|
282
|
+
* infrequently - the cache will be limited naturally and will not grow uncontrollably.
|
|
283
|
+
*
|
|
284
|
+
* Setting non-positive number here is invalid. If you want to turn off measures caching,
|
|
285
|
+
* tweak the `maxMeasuresWorkspaces` value.
|
|
286
|
+
*/
|
|
287
|
+
maxMeasuresPerWorkspace?: number;
|
|
223
288
|
/**
|
|
224
289
|
* Maximum number of organizations for which to cache organization-level export templates.
|
|
225
290
|
* Organization 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,EA+C1B,MAAM,2BAA2B,CAAC;AA2zEnC;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GAAG;IACvB;;;;;OAKG;IACH,eAAe,EAAE,MAAM,IAAI,CAAC;IAE5B;;OAEG;I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AE,MAAM,CAAC;IAEhC;;;;;;;;;;;OAWG;IACH,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAElC;;;;;;;;;;;;;OAaG;IACH,uBAAuB,CAAC,EAAE,MAAM,CAAC;IAEjC;;;;;;;;;;;;OAYG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAE5B;;;;;;;;;;;;;;OAcG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAE9B;;;;;;;;;;;;OAYG;IACH,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAE/B;;;;;;;;;;;OAWG;IACH,uBAAuB,CAAC,EAAE,MAAM,CAAC;IAEjC;;;;;OAKG;IACH,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAEhC;;;;;;;;;;OAUG;IACH,4BAA4B,CAAC,EAAE,MAAM,CAAC;IAEtC;;;;;;;;;;;OAWG;IACH,oCAAoC,CAAC,EAAE,MAAM,CAAC;IAE9C;;;;;;;;;;;OAWG;IACH,yBAAyB,CAAC,EAAE,MAAM,CAAC;IAEnC;;;;;;;;;;;;;OAaG;IACH,sCAAsC,CAAC,EAAE,MAAM,CAAC;IAEhD;;;;;;;;;;OAUG;IACH,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAE9B;;;;;;;;;;OAUG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;CAC5B,CAAC;AASF;;;;;;;GAOG;AACH,eAAO,MAAM,+BAA+B,EAAE,oBAuB7C,CAAC;AAEF;;;;;;;;GAQG;AACH,wBAAgB,WAAW,CACvB,WAAW,EAAE,kBAAkB,EAC/B,MAAM,EAAE,oBAAoB,GAC7B,kBAAkB,CAyGpB"}
|
|
@@ -11,8 +11,10 @@ import { DecoratedAutomationsQuery, DecoratedWorkspaceAutomationsService, } from
|
|
|
11
11
|
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
|
+
import { DecoratedWorkspaceFactsService } from "../decoratedBackend/facts.js";
|
|
14
15
|
import { decoratedBackend } from "../decoratedBackend/index.js";
|
|
15
16
|
import { DecoratedWorkspaceInsightsService } from "../decoratedBackend/insights.js";
|
|
17
|
+
import { DecoratedWorkspaceMeasuresService } from "../decoratedBackend/measures.js";
|
|
16
18
|
import { DecoratedOrganizationExportTemplatesService } from "../decoratedBackend/organizationExportTemplates.js";
|
|
17
19
|
import { DecoratedSecuritySettingsService } from "../decoratedBackend/securitySettings.js";
|
|
18
20
|
import { DecoratedWorkspaceExportTemplatesService } from "../decoratedBackend/workspaceExportTemplates.js";
|
|
@@ -1262,6 +1264,165 @@ function cachedInsights(ctx) {
|
|
|
1262
1264
|
return (original, workspace) => new WithInsightsCaching(original, ctx, workspace);
|
|
1263
1265
|
}
|
|
1264
1266
|
//
|
|
1267
|
+
// FACTS CACHING
|
|
1268
|
+
//
|
|
1269
|
+
function factsIncludeKeySuffix(opts) {
|
|
1270
|
+
return opts?.include?.length ? `:${opts.include.join(",")}` : "";
|
|
1271
|
+
}
|
|
1272
|
+
function getOrCreateFactsCache(ctx, workspace) {
|
|
1273
|
+
const cache = ctx.caches.workspaceFacts;
|
|
1274
|
+
let cacheEntry = cache.get(workspace);
|
|
1275
|
+
if (!cacheEntry) {
|
|
1276
|
+
cacheEntry = {
|
|
1277
|
+
facts: new LRUCache({
|
|
1278
|
+
max: ctx.config.maxFactsPerWorkspace,
|
|
1279
|
+
}),
|
|
1280
|
+
factDatasetsMeta: new LRUCache({
|
|
1281
|
+
max: ctx.config.maxFactsPerWorkspace,
|
|
1282
|
+
}),
|
|
1283
|
+
};
|
|
1284
|
+
cache.set(workspace, cacheEntry);
|
|
1285
|
+
}
|
|
1286
|
+
return cacheEntry;
|
|
1287
|
+
}
|
|
1288
|
+
class WithFactsCaching extends DecoratedWorkspaceFactsService {
|
|
1289
|
+
ctx;
|
|
1290
|
+
workspace;
|
|
1291
|
+
constructor(decorated, ctx, workspace) {
|
|
1292
|
+
super(decorated);
|
|
1293
|
+
this.ctx = ctx;
|
|
1294
|
+
this.workspace = workspace;
|
|
1295
|
+
}
|
|
1296
|
+
getFact = (ref, opts) => {
|
|
1297
|
+
const cache = getOrCreateFactsCache(this.ctx, this.workspace).facts;
|
|
1298
|
+
const suffix = factsIncludeKeySuffix(opts);
|
|
1299
|
+
const idCacheKey = isIdentifierRef(ref) ? `${ref.identifier}${suffix}` : undefined;
|
|
1300
|
+
const uriCacheKey = isUriRef(ref) ? `${ref.uri}${suffix}` : undefined;
|
|
1301
|
+
let cacheItem = firstDefined([idCacheKey, uriCacheKey].map((key) => key && cache.get(key)));
|
|
1302
|
+
if (!cacheItem) {
|
|
1303
|
+
cacheItem = super.getFact(ref, opts).catch((e) => {
|
|
1304
|
+
if (idCacheKey) {
|
|
1305
|
+
cache.delete(idCacheKey);
|
|
1306
|
+
}
|
|
1307
|
+
if (uriCacheKey) {
|
|
1308
|
+
cache.delete(uriCacheKey);
|
|
1309
|
+
}
|
|
1310
|
+
throw e;
|
|
1311
|
+
});
|
|
1312
|
+
if (idCacheKey) {
|
|
1313
|
+
cache.set(idCacheKey, cacheItem);
|
|
1314
|
+
}
|
|
1315
|
+
if (uriCacheKey) {
|
|
1316
|
+
cache.set(uriCacheKey, cacheItem);
|
|
1317
|
+
}
|
|
1318
|
+
}
|
|
1319
|
+
return cacheItem;
|
|
1320
|
+
};
|
|
1321
|
+
getFactDatasetMeta = (ref) => {
|
|
1322
|
+
const cache = getOrCreateFactsCache(this.ctx, this.workspace).factDatasetsMeta;
|
|
1323
|
+
const idCacheKey = isIdentifierRef(ref) ? ref.identifier : undefined;
|
|
1324
|
+
const uriCacheKey = isUriRef(ref) ? ref.uri : undefined;
|
|
1325
|
+
let cacheItem = firstDefined([idCacheKey, uriCacheKey].map((key) => key && cache.get(key)));
|
|
1326
|
+
if (!cacheItem) {
|
|
1327
|
+
cacheItem = super.getFactDatasetMeta(ref).catch((e) => {
|
|
1328
|
+
if (idCacheKey) {
|
|
1329
|
+
cache.delete(idCacheKey);
|
|
1330
|
+
}
|
|
1331
|
+
if (uriCacheKey) {
|
|
1332
|
+
cache.delete(uriCacheKey);
|
|
1333
|
+
}
|
|
1334
|
+
throw e;
|
|
1335
|
+
});
|
|
1336
|
+
if (idCacheKey) {
|
|
1337
|
+
cache.set(idCacheKey, cacheItem);
|
|
1338
|
+
}
|
|
1339
|
+
if (uriCacheKey) {
|
|
1340
|
+
cache.set(uriCacheKey, cacheItem);
|
|
1341
|
+
}
|
|
1342
|
+
}
|
|
1343
|
+
return cacheItem;
|
|
1344
|
+
};
|
|
1345
|
+
}
|
|
1346
|
+
//
|
|
1347
|
+
// MEASURES CACHING
|
|
1348
|
+
//
|
|
1349
|
+
function getOrCreateMeasuresCache(ctx, workspace) {
|
|
1350
|
+
const cache = ctx.caches.workspaceMeasures;
|
|
1351
|
+
let cacheEntry = cache.get(workspace);
|
|
1352
|
+
if (!cacheEntry) {
|
|
1353
|
+
cacheEntry = {
|
|
1354
|
+
expressionTokens: new LRUCache({
|
|
1355
|
+
max: ctx.config.maxMeasuresPerWorkspace,
|
|
1356
|
+
}),
|
|
1357
|
+
referencingObjects: new LRUCache({
|
|
1358
|
+
max: ctx.config.maxMeasuresPerWorkspace,
|
|
1359
|
+
}),
|
|
1360
|
+
};
|
|
1361
|
+
cache.set(workspace, cacheEntry);
|
|
1362
|
+
}
|
|
1363
|
+
return cacheEntry;
|
|
1364
|
+
}
|
|
1365
|
+
class WithMeasuresCaching extends DecoratedWorkspaceMeasuresService {
|
|
1366
|
+
ctx;
|
|
1367
|
+
workspace;
|
|
1368
|
+
constructor(decorated, ctx, workspace) {
|
|
1369
|
+
super(decorated);
|
|
1370
|
+
this.ctx = ctx;
|
|
1371
|
+
this.workspace = workspace;
|
|
1372
|
+
}
|
|
1373
|
+
getMeasureExpressionTokens = (ref) => {
|
|
1374
|
+
const cache = getOrCreateMeasuresCache(this.ctx, this.workspace).expressionTokens;
|
|
1375
|
+
const idCacheKey = isIdentifierRef(ref) ? ref.identifier : undefined;
|
|
1376
|
+
const uriCacheKey = isUriRef(ref) ? ref.uri : undefined;
|
|
1377
|
+
let cacheItem = firstDefined([idCacheKey, uriCacheKey].map((key) => key && cache.get(key)));
|
|
1378
|
+
if (!cacheItem) {
|
|
1379
|
+
cacheItem = super.getMeasureExpressionTokens(ref).catch((e) => {
|
|
1380
|
+
if (idCacheKey) {
|
|
1381
|
+
cache.delete(idCacheKey);
|
|
1382
|
+
}
|
|
1383
|
+
if (uriCacheKey) {
|
|
1384
|
+
cache.delete(uriCacheKey);
|
|
1385
|
+
}
|
|
1386
|
+
throw e;
|
|
1387
|
+
});
|
|
1388
|
+
if (idCacheKey) {
|
|
1389
|
+
cache.set(idCacheKey, cacheItem);
|
|
1390
|
+
}
|
|
1391
|
+
if (uriCacheKey) {
|
|
1392
|
+
cache.set(uriCacheKey, cacheItem);
|
|
1393
|
+
}
|
|
1394
|
+
}
|
|
1395
|
+
return cacheItem;
|
|
1396
|
+
};
|
|
1397
|
+
getMeasureReferencingObjects = (measureRef) => {
|
|
1398
|
+
const cache = getOrCreateMeasuresCache(this.ctx, this.workspace).referencingObjects;
|
|
1399
|
+
const idCacheKey = isIdentifierRef(measureRef) ? measureRef.identifier : undefined;
|
|
1400
|
+
const uriCacheKey = isUriRef(measureRef) ? measureRef.uri : undefined;
|
|
1401
|
+
let cacheItem = firstDefined([idCacheKey, uriCacheKey].map((key) => key && cache.get(key)));
|
|
1402
|
+
if (!cacheItem) {
|
|
1403
|
+
cacheItem = super.getMeasureReferencingObjects(measureRef).catch((e) => {
|
|
1404
|
+
if (idCacheKey) {
|
|
1405
|
+
cache.delete(idCacheKey);
|
|
1406
|
+
}
|
|
1407
|
+
if (uriCacheKey) {
|
|
1408
|
+
cache.delete(uriCacheKey);
|
|
1409
|
+
}
|
|
1410
|
+
throw e;
|
|
1411
|
+
});
|
|
1412
|
+
if (idCacheKey) {
|
|
1413
|
+
cache.set(idCacheKey, cacheItem);
|
|
1414
|
+
}
|
|
1415
|
+
if (uriCacheKey) {
|
|
1416
|
+
cache.set(uriCacheKey, cacheItem);
|
|
1417
|
+
}
|
|
1418
|
+
}
|
|
1419
|
+
return cacheItem;
|
|
1420
|
+
};
|
|
1421
|
+
}
|
|
1422
|
+
function cachedMeasures(ctx) {
|
|
1423
|
+
return (original, workspace) => new WithMeasuresCaching(original, ctx, workspace);
|
|
1424
|
+
}
|
|
1425
|
+
//
|
|
1265
1426
|
// ORGANIZATION EXPORT TEMPLATES CACHING
|
|
1266
1427
|
//
|
|
1267
1428
|
class WithOrganizationExportTemplatesCaching extends DecoratedOrganizationExportTemplatesService {
|
|
@@ -1412,6 +1573,9 @@ function cachedAttributes(ctx) {
|
|
|
1412
1573
|
function cachedAutomations(ctx) {
|
|
1413
1574
|
return (original, workspace) => new WithAutomationsCaching(original, ctx, workspace);
|
|
1414
1575
|
}
|
|
1576
|
+
function cachedFacts(ctx) {
|
|
1577
|
+
return (original, workspace) => new WithFactsCaching(original, ctx, workspace);
|
|
1578
|
+
}
|
|
1415
1579
|
//
|
|
1416
1580
|
// Geo caching
|
|
1417
1581
|
//
|
|
@@ -1497,6 +1661,9 @@ function cacheControl(ctx) {
|
|
|
1497
1661
|
resetAttributes: () => {
|
|
1498
1662
|
ctx.caches.workspaceAttributes?.clear();
|
|
1499
1663
|
},
|
|
1664
|
+
resetFacts: () => {
|
|
1665
|
+
ctx.caches.workspaceFacts?.clear();
|
|
1666
|
+
},
|
|
1500
1667
|
resetWorkspaceSettings: () => {
|
|
1501
1668
|
ctx.caches.workspaceSettings?.clear();
|
|
1502
1669
|
},
|
|
@@ -1513,15 +1680,20 @@ function cacheControl(ctx) {
|
|
|
1513
1680
|
resetInsights: () => {
|
|
1514
1681
|
ctx.caches.workspaceInsights?.clear();
|
|
1515
1682
|
},
|
|
1683
|
+
resetMeasures: () => {
|
|
1684
|
+
ctx.caches.workspaceMeasures?.clear();
|
|
1685
|
+
},
|
|
1516
1686
|
resetAll: () => {
|
|
1517
1687
|
control.resetExecutions();
|
|
1518
1688
|
control.resetCatalogs();
|
|
1519
1689
|
control.resetSecuritySettings();
|
|
1520
1690
|
control.resetAttributes();
|
|
1691
|
+
control.resetFacts();
|
|
1521
1692
|
control.resetWorkspaceSettings();
|
|
1522
1693
|
control.resetGeoStyles();
|
|
1523
1694
|
control.resetExportTemplates();
|
|
1524
1695
|
control.resetInsights();
|
|
1696
|
+
control.resetMeasures();
|
|
1525
1697
|
},
|
|
1526
1698
|
};
|
|
1527
1699
|
return control;
|
|
@@ -1553,6 +1725,10 @@ export const RecommendedCachingConfiguration = {
|
|
|
1553
1725
|
maxWorkspaceSettings: 1,
|
|
1554
1726
|
maxAutomationsWorkspaces: 1,
|
|
1555
1727
|
maxInsightsPerWorkspace: 50,
|
|
1728
|
+
maxFactsWorkspaces: 1,
|
|
1729
|
+
maxFactsPerWorkspace: 500,
|
|
1730
|
+
maxMeasuresWorkspaces: 1,
|
|
1731
|
+
maxMeasuresPerWorkspace: 100,
|
|
1556
1732
|
maxExportTemplatesOrgs: 1,
|
|
1557
1733
|
maxExportTemplatesWorkspaces: 1,
|
|
1558
1734
|
cacheGeoStyles: true,
|
|
@@ -1580,6 +1756,8 @@ export function withCaching(realBackend, config) {
|
|
|
1580
1756
|
const workspaceSettingsCaching = cachingEnabled(config.maxWorkspaceSettings);
|
|
1581
1757
|
const automationsCaching = cachingEnabled(config.maxAutomationsWorkspaces);
|
|
1582
1758
|
const insightsCaching = cachingEnabled(config.maxInsightsPerWorkspace);
|
|
1759
|
+
const factsCaching = cachingEnabled(config.maxFactsWorkspaces);
|
|
1760
|
+
const measuresCaching = cachingEnabled(config.maxMeasuresWorkspaces);
|
|
1583
1761
|
// Backward compatibility: `maxExportTemplatesWorkspaces` used to be the (deprecated) alias that
|
|
1584
1762
|
// sized the org export-templates cache. It now primarily drives workspace caching, but callers
|
|
1585
1763
|
// that only set the old name must keep getting org caching until the alias is removed.
|
|
@@ -1610,6 +1788,10 @@ export function withCaching(realBackend, config) {
|
|
|
1610
1788
|
workspaceInsights: insightsCaching
|
|
1611
1789
|
? new LRUCache({ max: config.maxInsightsPerWorkspace })
|
|
1612
1790
|
: undefined,
|
|
1791
|
+
workspaceFacts: factsCaching ? new LRUCache({ max: config.maxFactsWorkspaces }) : undefined,
|
|
1792
|
+
workspaceMeasures: measuresCaching
|
|
1793
|
+
? new LRUCache({ max: config.maxMeasuresWorkspaces })
|
|
1794
|
+
: undefined,
|
|
1613
1795
|
organizationExportTemplates: exportTemplatesCaching
|
|
1614
1796
|
? new LRUCache({ max: orgExportTemplatesMax })
|
|
1615
1797
|
: undefined,
|
|
@@ -1632,6 +1814,8 @@ export function withCaching(realBackend, config) {
|
|
|
1632
1814
|
const attributes = attributeCaching ? cachedAttributes(ctx) : (v) => v;
|
|
1633
1815
|
const automations = automationsCaching ? cachedAutomations(ctx) : (v) => v;
|
|
1634
1816
|
const insights = insightsCaching ? cachedInsights(ctx) : (v) => v;
|
|
1817
|
+
const facts = factsCaching ? cachedFacts(ctx) : (v) => v;
|
|
1818
|
+
const measures = measuresCaching ? cachedMeasures(ctx) : (v) => v;
|
|
1635
1819
|
const organizationExportTemplates = exportTemplatesCaching
|
|
1636
1820
|
? cachedOrganizationExportTemplates(ctx)
|
|
1637
1821
|
: undefined;
|
|
@@ -1651,6 +1835,8 @@ export function withCaching(realBackend, config) {
|
|
|
1651
1835
|
workspaceSettings,
|
|
1652
1836
|
automations,
|
|
1653
1837
|
insights,
|
|
1838
|
+
facts,
|
|
1839
|
+
measures,
|
|
1654
1840
|
organizationExportTemplates,
|
|
1655
1841
|
workspaceExportTemplates,
|
|
1656
1842
|
geo,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"analyticalWorkspace.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/analyticalWorkspace.ts"],"names":[],"mappings":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
47
|
+
return measures(this.decorated.measures(), this.workspace);
|
|
48
|
+
}
|
|
45
49
|
return this.decorated.measures();
|
|
46
50
|
}
|
|
47
51
|
parameters() {
|
|
48
52
|
return this.decorated.parameters();
|
|
49
53
|
}
|
|
50
54
|
facts() {
|
|
55
|
+
const { facts } = this.factories;
|
|
56
|
+
if (facts) {
|
|
57
|
+
return facts(this.decorated.facts(), this.workspace);
|
|
58
|
+
}
|
|
51
59
|
return this.decorated.facts();
|
|
52
60
|
}
|
|
53
61
|
insights() {
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type IFactsQuery, type IWorkspaceFactsService } from "@gooddata/sdk-backend-spi";
|
|
2
|
+
import { type IFactMetadataObject, type IMetadataObject, type IMetadataObjectBase, type IMetadataObjectIdentity, type ObjRef } from "@gooddata/sdk-model";
|
|
3
|
+
/**
|
|
4
|
+
* @alpha
|
|
5
|
+
*/
|
|
6
|
+
export declare abstract class DecoratedWorkspaceFactsService implements IWorkspaceFactsService {
|
|
7
|
+
protected readonly decorated: IWorkspaceFactsService;
|
|
8
|
+
protected constructor(decorated: IWorkspaceFactsService);
|
|
9
|
+
getFactDatasetMeta(ref: ObjRef): Promise<IMetadataObject>;
|
|
10
|
+
getFactsQuery(): IFactsQuery;
|
|
11
|
+
getFact(ref: ObjRef, opts?: {
|
|
12
|
+
include?: ["dataset"];
|
|
13
|
+
}): Promise<IFactMetadataObject>;
|
|
14
|
+
updateFactMeta(updatedFact: Partial<IMetadataObjectBase> & IMetadataObjectIdentity): Promise<IFactMetadataObject>;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=facts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"facts.d.ts","sourceRoot":"","sources":["../../src/decoratedBackend/facts.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,WAAW,EAAE,KAAK,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AAC1F,OAAO,EACH,KAAK,mBAAmB,EACxB,KAAK,eAAe,EACpB,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,MAAM,EACd,MAAM,qBAAqB,CAAC;AAE7B;;GAEG;AACH,8BAAsB,8BAA+B,YAAW,sBAAsB;IAC5D,SAAS,CAAC,QAAQ,CAAC,SAAS,EAAE,sBAAsB;IAA1E,SAAS,aAAgC,SAAS,EAAE,sBAAsB,EAAI;IAEvE,kBAAkB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC,CAE/D;IAEM,aAAa,IAAI,WAAW,CAElC;IAEM,OAAO,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE;QAAE,OAAO,CAAC,EAAE,CAAC,SAAS,CAAC,CAAA;KAAE,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAE1F;IAEM,cAAc,CACjB,WAAW,EAAE,OAAO,CAAC,mBAAmB,CAAC,GAAG,uBAAuB,GACpE,OAAO,CAAC,mBAAmB,CAAC,CAE9B;CACJ"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
// (C) 2025-2026 GoodData Corporation
|
|
2
|
+
/**
|
|
3
|
+
* @alpha
|
|
4
|
+
*/
|
|
5
|
+
export class DecoratedWorkspaceFactsService {
|
|
6
|
+
decorated;
|
|
7
|
+
constructor(decorated) {
|
|
8
|
+
this.decorated = decorated;
|
|
9
|
+
}
|
|
10
|
+
getFactDatasetMeta(ref) {
|
|
11
|
+
return this.decorated.getFactDatasetMeta(ref);
|
|
12
|
+
}
|
|
13
|
+
getFactsQuery() {
|
|
14
|
+
return this.decorated.getFactsQuery();
|
|
15
|
+
}
|
|
16
|
+
getFact(ref, opts) {
|
|
17
|
+
return this.decorated.getFact(ref, opts);
|
|
18
|
+
}
|
|
19
|
+
updateFactMeta(updatedFact) {
|
|
20
|
+
return this.decorated.updateFactMeta(updatedFact);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type IGetMeasureOptions, type IMeasureExpressionToken, type IMeasureKeyDrivers, type IMeasureReferencing, type IMeasuresQuery, type IWorkspaceMeasuresService } from "@gooddata/sdk-backend-spi";
|
|
2
|
+
import { type IMeasure, type IMeasureMetadataObject, type IMeasureMetadataObjectDefinition, type IMetadataObjectBase, type IMetadataObjectIdentity, type IObjectCertificationWrite, type ObjRef } from "@gooddata/sdk-model";
|
|
3
|
+
/**
|
|
4
|
+
* @alpha
|
|
5
|
+
*/
|
|
6
|
+
export declare abstract class DecoratedWorkspaceMeasuresService implements IWorkspaceMeasuresService {
|
|
7
|
+
protected readonly decorated: IWorkspaceMeasuresService;
|
|
8
|
+
protected constructor(decorated: IWorkspaceMeasuresService);
|
|
9
|
+
computeKeyDrivers(measure: IMeasure, options?: {
|
|
10
|
+
sortDirection: "ASC" | "DESC";
|
|
11
|
+
}): Promise<IMeasureKeyDrivers>;
|
|
12
|
+
getMeasureExpressionTokens(ref: ObjRef): Promise<IMeasureExpressionToken[]>;
|
|
13
|
+
createMeasure(measure: IMeasureMetadataObjectDefinition): Promise<IMeasureMetadataObject>;
|
|
14
|
+
updateMeasure(measure: IMeasureMetadataObject): Promise<IMeasureMetadataObject>;
|
|
15
|
+
updateMeasureMeta(measure: Partial<IMetadataObjectBase> & IMetadataObjectIdentity): Promise<IMeasureMetadataObject>;
|
|
16
|
+
setCertification(ref: ObjRef, certification?: IObjectCertificationWrite): Promise<void>;
|
|
17
|
+
deleteMeasure(measureRef: ObjRef): Promise<void>;
|
|
18
|
+
getMeasureReferencingObjects(measureRef: ObjRef): Promise<IMeasureReferencing>;
|
|
19
|
+
getMeasuresQuery(): IMeasuresQuery;
|
|
20
|
+
getMeasure(ref: ObjRef, options?: IGetMeasureOptions): Promise<IMeasureMetadataObject>;
|
|
21
|
+
getConnectedAttributes(definition: IMeasure, auxMeasures?: IMeasure[]): Promise<ObjRef[]>;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=measures.d.ts.map
|
|
@@ -0,0 +1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C,IAAI,CAAC,CAE/C;IAED,4BAA4B,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAE7E;IAED,gBAAgB,IAAI,cAAc,CAEjC;IAED,UAAU,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,kBAAkB,GAAG,OAAO,CAAC,sBAAsB,CAAC,CAErF;IAED,sBAAsB,CAAC,UAAU,EAAE,QAAQ,EAAE,WAAW,CAAC,EAAE,QAAQ,EAAE,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAExF;CACJ"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// (C) 2026 GoodData Corporation
|
|
2
|
+
/**
|
|
3
|
+
* @alpha
|
|
4
|
+
*/
|
|
5
|
+
export class DecoratedWorkspaceMeasuresService {
|
|
6
|
+
decorated;
|
|
7
|
+
constructor(decorated) {
|
|
8
|
+
this.decorated = decorated;
|
|
9
|
+
}
|
|
10
|
+
computeKeyDrivers(measure, options) {
|
|
11
|
+
return this.decorated.computeKeyDrivers(measure, options);
|
|
12
|
+
}
|
|
13
|
+
getMeasureExpressionTokens(ref) {
|
|
14
|
+
return this.decorated.getMeasureExpressionTokens(ref);
|
|
15
|
+
}
|
|
16
|
+
createMeasure(measure) {
|
|
17
|
+
return this.decorated.createMeasure(measure);
|
|
18
|
+
}
|
|
19
|
+
updateMeasure(measure) {
|
|
20
|
+
return this.decorated.updateMeasure(measure);
|
|
21
|
+
}
|
|
22
|
+
updateMeasureMeta(measure) {
|
|
23
|
+
return this.decorated.updateMeasureMeta(measure);
|
|
24
|
+
}
|
|
25
|
+
setCertification(ref, certification) {
|
|
26
|
+
return this.decorated.setCertification(ref, certification);
|
|
27
|
+
}
|
|
28
|
+
deleteMeasure(measureRef) {
|
|
29
|
+
return this.decorated.deleteMeasure(measureRef);
|
|
30
|
+
}
|
|
31
|
+
getMeasureReferencingObjects(measureRef) {
|
|
32
|
+
return this.decorated.getMeasureReferencingObjects(measureRef);
|
|
33
|
+
}
|
|
34
|
+
getMeasuresQuery() {
|
|
35
|
+
return this.decorated.getMeasuresQuery();
|
|
36
|
+
}
|
|
37
|
+
getMeasure(ref, options) {
|
|
38
|
+
return this.decorated.getMeasure(ref, options);
|
|
39
|
+
}
|
|
40
|
+
getConnectedAttributes(definition, auxMeasures) {
|
|
41
|
+
return this.decorated.getConnectedAttributes(definition, auxMeasures);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type IExecutionFactory, type IGeoService, type IOrganizationExportTemplatesService, type ISecuritySettingsService, type IWorkspaceAttributesService, type IWorkspaceAutomationService, type IWorkspaceCatalogFactory, type IWorkspaceDashboardsService, type IWorkspaceExportTemplatesService, type IWorkspaceInsightsService, 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 IWorkspaceExportTemplatesService, type IWorkspaceFactsService, type IWorkspaceInsightsService, type IWorkspaceMeasuresService, type IWorkspaceSettingsService } from "@gooddata/sdk-backend-spi";
|
|
2
2
|
/**
|
|
3
3
|
* @alpha
|
|
4
4
|
*/
|
|
@@ -23,6 +23,10 @@ export type AttributesDecoratorFactory = (attributes: IWorkspaceAttributesServic
|
|
|
23
23
|
* @alpha
|
|
24
24
|
*/
|
|
25
25
|
export type AutomationsDecoratorFactory = (automations: IWorkspaceAutomationService, workspace: string) => IWorkspaceAutomationService;
|
|
26
|
+
/**
|
|
27
|
+
* @alpha
|
|
28
|
+
*/
|
|
29
|
+
export type MeasuresDecoratorFactory = (measures: IWorkspaceMeasuresService, workspace: string) => IWorkspaceMeasuresService;
|
|
26
30
|
/**
|
|
27
31
|
* @alpha
|
|
28
32
|
*/
|
|
@@ -31,6 +35,10 @@ export type DashboardsDecoratorFactory = (dashboards: IWorkspaceDashboardsServic
|
|
|
31
35
|
* @alpha
|
|
32
36
|
*/
|
|
33
37
|
export type InsightsDecoratorFactory = (insights: IWorkspaceInsightsService, workspace: string) => IWorkspaceInsightsService;
|
|
38
|
+
/**
|
|
39
|
+
* @alpha
|
|
40
|
+
*/
|
|
41
|
+
export type FactsDecoratorFactory = (facts: IWorkspaceFactsService, workspace: string) => IWorkspaceFactsService;
|
|
34
42
|
/**
|
|
35
43
|
* @alpha
|
|
36
44
|
*/
|
|
@@ -58,7 +66,9 @@ export type DecoratorFactories = {
|
|
|
58
66
|
attributes?: AttributesDecoratorFactory;
|
|
59
67
|
automations?: AutomationsDecoratorFactory;
|
|
60
68
|
insights?: InsightsDecoratorFactory;
|
|
69
|
+
measures?: MeasuresDecoratorFactory;
|
|
61
70
|
dashboards?: DashboardsDecoratorFactory;
|
|
71
|
+
facts?: FactsDecoratorFactory;
|
|
62
72
|
geo?: GeoDecoratorFactory;
|
|
63
73
|
organizationExportTemplates?: OrganizationExportTemplatesDecoratorFactory;
|
|
64
74
|
workspaceExportTemplates?: WorkspaceExportTemplatesDecoratorFactory;
|
|
@@ -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,EAC7B,KAAK,2BAA2B,EAChC,KAAK,gCAAgC,EACrC,KAAK,yBAAyB,EAC9B,KAAK,yBAAyB,EACjC,MAAM,2BAA2B,CAAC;AAEnC;;GAEG;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,gBAAgB,EAAE,iBAAiB,KAAK,iBAAiB,CAAC;AAEnG;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,OAAO,EAAE,wBAAwB,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AAE,wBAAwB,CAAC;IACpC,UAAU,CAAC,EAAE,0BAA0B,CAAC;IACxC,KAAK,CAAC,EAAE,qBAAqB,CAAC;IAC9B,GAAG,CAAC,EAAE,mBAAmB,CAAC;IAC1B,2BAA2B,CAAC,EAAE,2CAA2C,CAAC;IAC1E,wBAAwB,CAAC,EAAE,wCAAwC,CAAC;CACvE,CAAC"}
|
package/esm/index.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ 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, InsightsDecoratorFactory, DashboardsDecoratorFactory, GeoDecoratorFactory, OrganizationExportTemplatesDecoratorFactory, WorkspaceExportTemplatesDecoratorFactory, } from "./decoratedBackend/types.js";
|
|
15
|
+
export type { DecoratorFactories, CatalogDecoratorFactory, ExecutionDecoratorFactory, SecuritySettingsDecoratorFactory, WorkspaceSettingsDecoratorFactory, AutomationsDecoratorFactory, AttributesDecoratorFactory, InsightsDecoratorFactory, MeasuresDecoratorFactory, DashboardsDecoratorFactory, FactsDecoratorFactory, GeoDecoratorFactory, OrganizationExportTemplatesDecoratorFactory, WorkspaceExportTemplatesDecoratorFactory, } 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
18
|
export { DecoratedWorkspaceInsightsService } from "./decoratedBackend/insights.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,aAAa,GAChB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAE,+BAA+B,EAAE,MAAM,uCAAuC,CAAC;AACxF,OAAO,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAEtG,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAE/D,YAAY,EACR,kBAAkB,EAClB,uBAAuB,EACvB,yBAAyB,EACzB,gCAAgC,EAChC,iCAAiC,EACjC,2BAA2B,EAC3B,0BAA0B,EAC1B,wBAAwB,EACxB,0BAA0B,EAC1B,mBAAmB,EACnB,2CAA2C,EAC3C,wCAAwC,GAC3C,MAAM,6BAA6B,CAAC;AAErC,OAAO,EACH,KAAK,wBAAwB,EAC7B,yBAAyB,EACzB,0BAA0B,EAC1B,wBAAwB,GAC3B,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,mCAAmC,EAAE,MAAM,kCAAkC,CAAC;AAEvF,OAAO,EAAE,iCAAiC,EAAE,MAAM,gCAAgC,CAAC;AAEnF,OAAO,EACH,KAAK,uBAAuB,EAC5B,gCAAgC,EAChC,yBAAyB,GAC5B,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EAAE,gCAAgC,EAAE,MAAM,wCAAwC,CAAC;AAE1F,OAAO,EAAE,2CAA2C,EAAE,MAAM,mDAAmD,CAAC;AAEhH,OAAO,EAAE,wCAAwC,EAAE,MAAM,gDAAgD,CAAC;AAE1G,OAAO,EAAE,iCAAiC,EAAE,MAAM,yCAAyC,CAAC;AAE5F,OAAO,EAAE,KAAK,0BAA0B,EAAE,YAAY,EAAE,MAAM,4BAA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AAM,2CAA2C,CAAC;AACnD,OAAO,EACH,yCAAyC,EACzC,qCAAqC,GACxC,MAAM,+CAA+C,CAAC;AACvD,OAAO,EAAE,KAAK,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAC;AACxG,OAAO,EAAE,qBAAqB,EAAE,yBAAyB,EAAE,MAAM,wCAAwC,CAAC;AAC1G,OAAO,EACH,4BAA4B,EAC5B,wBAAwB,GAC3B,MAAM,2CAA2C,CAAC;AACnD,OAAO,EACH,yBAAyB,EACzB,6BAA6B,GAChC,MAAM,4CAA4C,CAAC;AACpD,OAAO,EACH,0BAA0B,EAC1B,8BAA8B,GACjC,MAAM,6CAA6C,CAAC;AAErD,OAAO,EAAE,KAAK,uBAAuB,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAE9G,OAAO,EAAE,iCAAiC,EAAE,MAAM,2CAA2C,CAAC"}
|
|
@@ -168,7 +168,9 @@ import { IWorkspaceCatalogFactory } from '@gooddata/sdk-backend-spi';
|
|
|
168
168
|
import { IWorkspaceCatalogFactoryOptions } from '@gooddata/sdk-backend-spi';
|
|
169
169
|
import { IWorkspaceDashboardsService } from '@gooddata/sdk-backend-spi';
|
|
170
170
|
import { IWorkspaceExportTemplatesService } from '@gooddata/sdk-backend-spi';
|
|
171
|
+
import { IWorkspaceFactsService } from '@gooddata/sdk-backend-spi';
|
|
171
172
|
import { IWorkspaceInsightsService } from '@gooddata/sdk-backend-spi';
|
|
173
|
+
import { IWorkspaceMeasuresService } from '@gooddata/sdk-backend-spi';
|
|
172
174
|
import { IWorkspaceSettings } from '@gooddata/sdk-backend-spi';
|
|
173
175
|
import { IWorkspaceSettingsService } from '@gooddata/sdk-backend-spi';
|
|
174
176
|
import { KpiDrillDefinition } from '@gooddata/sdk-model';
|
|
@@ -455,6 +457,10 @@ export declare type CacheControl = {
|
|
|
455
457
|
* Resets all workspace attribute caches.
|
|
456
458
|
*/
|
|
457
459
|
resetAttributes: () => void;
|
|
460
|
+
/**
|
|
461
|
+
* Resets all workspace facts caches.
|
|
462
|
+
*/
|
|
463
|
+
resetFacts: () => void;
|
|
458
464
|
/**
|
|
459
465
|
* Resets all workspace settings caches.
|
|
460
466
|
*/
|
|
@@ -471,6 +477,10 @@ export declare type CacheControl = {
|
|
|
471
477
|
* Resets all workspace insight caches.
|
|
472
478
|
*/
|
|
473
479
|
resetInsights: () => void;
|
|
480
|
+
/**
|
|
481
|
+
* Resets all workspace measures caches.
|
|
482
|
+
*/
|
|
483
|
+
resetMeasures: () => void;
|
|
474
484
|
/**
|
|
475
485
|
* Convenience method to reset all caches (calls all the particular resets).
|
|
476
486
|
*/
|
|
@@ -651,6 +661,63 @@ export declare type CachingConfiguration = {
|
|
|
651
661
|
* When non-positive number is specified, then no caching of insights will be done.
|
|
652
662
|
*/
|
|
653
663
|
maxInsightsPerWorkspace?: number;
|
|
664
|
+
/**
|
|
665
|
+
* Maximum number of workspaces for which to cache selected {@link @gooddata/sdk-backend-spi#IWorkspaceFactsService} calls.
|
|
666
|
+
* The workspace identifier is used as cache key.
|
|
667
|
+
* For each workspace, there will be a cache entry holding `maxFactsPerWorkspace` entries for fact-related calls.
|
|
668
|
+
*
|
|
669
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
670
|
+
*
|
|
671
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
672
|
+
* cache may be OK in applications where number of workspaces is small - the cache will be limited
|
|
673
|
+
* naturally and will not grow uncontrollably.
|
|
674
|
+
*
|
|
675
|
+
* When non-positive number is specified, then no caching will be done.
|
|
676
|
+
*/
|
|
677
|
+
maxFactsWorkspaces?: number;
|
|
678
|
+
/**
|
|
679
|
+
* Maximum number of facts to cache per workspace.
|
|
680
|
+
*
|
|
681
|
+
* This limit applies independently to the cache of facts (`getFact`) and the cache of fact dataset
|
|
682
|
+
* metadata (`getFactDatasetMeta`).
|
|
683
|
+
*
|
|
684
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
685
|
+
*
|
|
686
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
687
|
+
* facts cache may be OK in applications where number of facts is small and/or they are requested
|
|
688
|
+
* infrequently - the cache will be limited naturally and will not grow uncontrollably.
|
|
689
|
+
*
|
|
690
|
+
* Setting non-positive number here is invalid. If you want to turn off facts caching,
|
|
691
|
+
* tweak the `maxFactsWorkspaces` value.
|
|
692
|
+
*/
|
|
693
|
+
maxFactsPerWorkspace?: number;
|
|
694
|
+
/**
|
|
695
|
+
* Maximum number of workspaces for which to cache selected {@link @gooddata/sdk-backend-spi#IWorkspaceMeasuresService} calls.
|
|
696
|
+
* The workspace identifier is used as cache key.
|
|
697
|
+
* For each workspace, there will be a cache entry holding `maxMeasuresPerWorkspace` entries.
|
|
698
|
+
*
|
|
699
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
700
|
+
*
|
|
701
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
702
|
+
* cache may be OK in applications where number of workspaces is small - the cache will be limited
|
|
703
|
+
* naturally and will not grow uncontrollably.
|
|
704
|
+
*
|
|
705
|
+
* When non-positive number is specified, then no caching will be done.
|
|
706
|
+
*/
|
|
707
|
+
maxMeasuresWorkspaces?: number;
|
|
708
|
+
/**
|
|
709
|
+
* Maximum number of measures to cache per workspace.
|
|
710
|
+
*
|
|
711
|
+
* When limit is reached, cache entries will be evicted using LRU policy.
|
|
712
|
+
*
|
|
713
|
+
* When no maximum number is specified, the cache will be unbounded and no evictions will happen. Unbounded
|
|
714
|
+
* measures cache may be OK in applications where number of measures is small and/or they are requested
|
|
715
|
+
* infrequently - the cache will be limited naturally and will not grow uncontrollably.
|
|
716
|
+
*
|
|
717
|
+
* Setting non-positive number here is invalid. If you want to turn off measures caching,
|
|
718
|
+
* tweak the `maxMeasuresWorkspaces` value.
|
|
719
|
+
*/
|
|
720
|
+
maxMeasuresPerWorkspace?: number;
|
|
654
721
|
/**
|
|
655
722
|
* Maximum number of organizations for which to cache organization-level export templates.
|
|
656
723
|
* Organization export templates are organization-level, so typically a single entry suffices.
|
|
@@ -1340,7 +1407,9 @@ export declare type DecoratorFactories = {
|
|
|
1340
1407
|
attributes?: AttributesDecoratorFactory;
|
|
1341
1408
|
automations?: AutomationsDecoratorFactory;
|
|
1342
1409
|
insights?: InsightsDecoratorFactory;
|
|
1410
|
+
measures?: MeasuresDecoratorFactory;
|
|
1343
1411
|
dashboards?: DashboardsDecoratorFactory;
|
|
1412
|
+
facts?: FactsDecoratorFactory;
|
|
1344
1413
|
geo?: GeoDecoratorFactory;
|
|
1345
1414
|
organizationExportTemplates?: OrganizationExportTemplatesDecoratorFactory;
|
|
1346
1415
|
workspaceExportTemplates?: WorkspaceExportTemplatesDecoratorFactory;
|
|
@@ -1564,6 +1633,11 @@ export declare class FactMetadataObjectBuilder<T extends IFactMetadataObject = I
|
|
|
1564
1633
|
dataSet(value: IDataSetMetadataObject | undefined): this;
|
|
1565
1634
|
}
|
|
1566
1635
|
|
|
1636
|
+
/**
|
|
1637
|
+
* @alpha
|
|
1638
|
+
*/
|
|
1639
|
+
export declare type FactsDecoratorFactory = (facts: IWorkspaceFactsService, workspace: string) => IWorkspaceFactsService;
|
|
1640
|
+
|
|
1567
1641
|
/**
|
|
1568
1642
|
* Date filter local identifier generator.
|
|
1569
1643
|
*
|
|
@@ -1892,6 +1966,11 @@ export declare class MeasureMetadataObjectBuilder<T extends IMeasureMetadataObje
|
|
|
1892
1966
|
updatedBy(updatedBy?: IUser): this;
|
|
1893
1967
|
}
|
|
1894
1968
|
|
|
1969
|
+
/**
|
|
1970
|
+
* @alpha
|
|
1971
|
+
*/
|
|
1972
|
+
export declare type MeasuresDecoratorFactory = (measures: IWorkspaceMeasuresService, workspace: string) => IWorkspaceMeasuresService;
|
|
1973
|
+
|
|
1895
1974
|
/**
|
|
1896
1975
|
* Merge two bounding boxes into a single covering bounding box.
|
|
1897
1976
|
*
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gooddata/sdk-backend-base",
|
|
3
|
-
"version": "11.48.0-alpha.
|
|
3
|
+
"version": "11.48.0-alpha.5",
|
|
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.48.0-alpha.
|
|
33
|
-
"@gooddata/sdk-model": "11.48.0-alpha.
|
|
34
|
-
"@gooddata/util": "11.48.0-alpha.
|
|
32
|
+
"@gooddata/sdk-backend-spi": "11.48.0-alpha.5",
|
|
33
|
+
"@gooddata/sdk-model": "11.48.0-alpha.5",
|
|
34
|
+
"@gooddata/util": "11.48.0-alpha.5"
|
|
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/eslint-config": "11.48.0-alpha.
|
|
60
|
-
"@gooddata/oxlint-config": "11.48.0-alpha.
|
|
61
|
-
"@gooddata/reference-workspace": "11.48.0-alpha.
|
|
59
|
+
"@gooddata/eslint-config": "11.48.0-alpha.5",
|
|
60
|
+
"@gooddata/oxlint-config": "11.48.0-alpha.5",
|
|
61
|
+
"@gooddata/reference-workspace": "11.48.0-alpha.5"
|
|
62
62
|
},
|
|
63
63
|
"scripts": {
|
|
64
64
|
"_phase:build": "npm run build",
|