@salesforce/lds-runtime-aura 1.457.0 → 1.458.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ldsEngineCreator.js +19 -250
- package/dist/types/network-fetch.d.ts +2 -28
- package/dist/types/retry-policies/luvio-fetch-throttling-retry-policy.d.ts +3 -3
- package/package.json +43 -43
- package/dist/types/__mocks__/@salesforce/lds-ads-bridge.d.ts +0 -2
- package/dist/types/__mocks__/@salesforce/lds-durable-storage.d.ts +0 -5
- package/dist/types/__mocks__/@salesforce/lds-environment-settings.d.ts +0 -2
- package/dist/types/__mocks__/@salesforce/lds-instrumentation.d.ts +0 -15
- package/dist/types/__mocks__/@salesforce/lds-network-aura.d.ts +0 -4
- package/dist/types/__mocks__/@salesforce/lds-network-fetch.d.ts +0 -2
- package/dist/types/__mocks__/aura.d.ts +0 -3
- package/dist/types/__mocks__/force/ldsGraphqlParser.d.ts +0 -3
- package/dist/types/__mocks__/instrumentation/service.d.ts +0 -33
- package/dist/types/__mocks__/instrumentation:thirdPartyTracker.d.ts +0 -4
- package/dist/types/__mocks__/lwc.d.ts +0 -6
- package/dist/types/__mocks__/o11y/activity.d.ts +0 -12
- package/dist/types/__mocks__/o11y/client.d.ts +0 -11
- package/dist/types/__mocks__/o11y/idleDetector.d.ts +0 -18
- package/dist/types/__mocks__/o11y/instrumentation.d.ts +0 -15
- package/dist/types/__mocks__/o11y_schema/sf_lds.d.ts +0 -1
- package/dist/types/http-utils.d.ts +0 -30
package/dist/ldsEngineCreator.js
CHANGED
|
@@ -28,7 +28,7 @@ import { assertIsValid, JsonSchemaViolationError, MissingRequiredPropertyError }
|
|
|
28
28
|
import auraNetworkAdapter, { dispatchAuraAction, defaultActionConfig, instrument as instrument$1, forceRecordTransactionsDisabled as forceRecordTransactionsDisabled$1, ldsNetworkAdapterInstrument, CrudEventState, CrudEventType, UIAPI_RECORDS_PATH, UIAPI_RELATED_LIST_RECORDS_BATCH_PATH, UIAPI_RELATED_LIST_RECORDS_PATH } from 'force/ldsNetwork';
|
|
29
29
|
import { ThirdPartyTracker } from 'instrumentation:thirdPartyTracker';
|
|
30
30
|
import { markStart, markEnd, counter, registerCacheStats, perfStart, perfEnd, registerPeriodicLogger, interaction, timer, mark } from 'instrumentation/service';
|
|
31
|
-
import { instrument as instrument$2, setupLexNetworkAdapter } from 'force/ldsNetworkFetch';
|
|
31
|
+
import { instrument as instrument$2, isCsrfMethod, getFetchMethod, isRetryableMethod, isRetryableReadPost, compilePathMatchers, setupLexNetworkAdapter, UIAPI_PUBLIC_PATHS, UIAPI_PRIVATE_PATHS, isRetryableOperationType } from 'force/ldsNetworkFetch';
|
|
32
32
|
import { REFRESH_ADAPTER_EVENT, ADAPTER_UNFULFILLED_ERROR, instrument as instrument$3 } from 'force/ldsBindings';
|
|
33
33
|
import { stateManagerInstrumentation, OperationTypeValue, LRUCache, instrumentAdapter, instrumentLuvio, logMessage as logMessage$1, setupInstrumentation as setupInstrumentation$1, logObjectInfoChanged as logObjectInfoChanged$1, updatePercentileHistogramMetric, incrementCounterMetric, incrementGetRecordNotifyChangeAllowCount, incrementGetRecordNotifyChangeDropCount, incrementNotifyRecordUpdateAvailableAllowCount, incrementNotifyRecordUpdateAvailableDropCount, setLdsAdaptersUiapiInstrumentation, logError as logError$2, setLdsNetworkAdapterInstrumentation, executeAsyncActivity, METRIC_KEYS, onIdleDetected } from 'force/ldsInstrumentation';
|
|
34
34
|
import { instrument as instrument$4 } from 'force/adsBridge';
|
|
@@ -2602,7 +2602,7 @@ function buildServiceDescriptor$d(luvio) {
|
|
|
2602
2602
|
},
|
|
2603
2603
|
};
|
|
2604
2604
|
}
|
|
2605
|
-
// version: 1.
|
|
2605
|
+
// version: 1.458.0-5aef0572f2
|
|
2606
2606
|
|
|
2607
2607
|
class AuraGraphQLNormalizedCacheControlCommand extends AuraNormalizedCacheControlCommand {
|
|
2608
2608
|
constructor(config, documentRootType, services) {
|
|
@@ -2941,7 +2941,7 @@ function buildServiceDescriptor$9(notifyRecordUpdateAvailable, getNormalizedLuvi
|
|
|
2941
2941
|
},
|
|
2942
2942
|
};
|
|
2943
2943
|
}
|
|
2944
|
-
// version: 1.
|
|
2944
|
+
// version: 1.458.0-5aef0572f2
|
|
2945
2945
|
|
|
2946
2946
|
class RetryService {
|
|
2947
2947
|
constructor(defaultRetryPolicy) {
|
|
@@ -5947,7 +5947,7 @@ function getEnvironmentSetting(name) {
|
|
|
5947
5947
|
}
|
|
5948
5948
|
return undefined;
|
|
5949
5949
|
}
|
|
5950
|
-
// version: 1.
|
|
5950
|
+
// version: 1.458.0-6d15707ed2
|
|
5951
5951
|
|
|
5952
5952
|
const auraClientService = getAuraClientService();
|
|
5953
5953
|
const defaultConfig = {
|
|
@@ -6484,57 +6484,6 @@ function getCsrfTokenManager() {
|
|
|
6484
6484
|
return cached;
|
|
6485
6485
|
}
|
|
6486
6486
|
|
|
6487
|
-
/**
|
|
6488
|
-
* Extracts the HTTP method from FetchParameters, matching the Fetch API's own
|
|
6489
|
-
* precedence: an options.method override wins over a Request object's method
|
|
6490
|
-
* (e.g. `fetch(new Request(url, { method: 'GET' }), { method: 'POST' })`
|
|
6491
|
-
* resolves to `POST`).
|
|
6492
|
-
*/
|
|
6493
|
-
function getFetchMethod([urlOrRequest, options]) {
|
|
6494
|
-
if (options && 'method' in options) {
|
|
6495
|
-
return options.method;
|
|
6496
|
-
}
|
|
6497
|
-
if (typeof urlOrRequest !== 'string' && 'method' in urlOrRequest) {
|
|
6498
|
-
return urlOrRequest.method;
|
|
6499
|
-
}
|
|
6500
|
-
return undefined;
|
|
6501
|
-
}
|
|
6502
|
-
/**
|
|
6503
|
-
* Only GET requests are safe to replay automatically on 429/503 — replaying a
|
|
6504
|
-
* write (POST/PUT/PATCH/DELETE) risks executing a mutation more than once.
|
|
6505
|
-
* Shared by both the Luvio and generic-fetch throttling retry policies so the
|
|
6506
|
-
* write-guard rule lives in exactly one place.
|
|
6507
|
-
*/
|
|
6508
|
-
function isRetryableMethod(method) {
|
|
6509
|
-
return method?.toLowerCase() === 'get';
|
|
6510
|
-
}
|
|
6511
|
-
/**
|
|
6512
|
-
* A request whose operationType is `query` is a read, so it is safe to replay
|
|
6513
|
-
* automatically on 429/503 even when the transport uses a non-GET method (e.g.
|
|
6514
|
-
* a GraphQL/aggregate-ui read issued as a POST). This complements
|
|
6515
|
-
* `isRetryableMethod`: OneStore seeds the command's operationType into the
|
|
6516
|
-
* per-request context, and the throttling policy retries when either the method
|
|
6517
|
-
* is GET or the operationType is `query`. Only `query` is retryable — `mutation`
|
|
6518
|
-
* and an absent/`graphql` operationType are never replayed.
|
|
6519
|
-
*/
|
|
6520
|
-
function isRetryableOperationType(operationType) {
|
|
6521
|
-
return operationType === 'query';
|
|
6522
|
-
}
|
|
6523
|
-
/**
|
|
6524
|
-
* Determines if the HTTP method requires CSRF protection.
|
|
6525
|
-
* Only mutating operations (POST, PUT, PATCH, DELETE) require CSRF tokens.
|
|
6526
|
-
*/
|
|
6527
|
-
function isCsrfMethod(method) {
|
|
6528
|
-
if (!method) {
|
|
6529
|
-
return false;
|
|
6530
|
-
}
|
|
6531
|
-
const normalizedMethod = method.toLowerCase();
|
|
6532
|
-
return (normalizedMethod === 'post' ||
|
|
6533
|
-
normalizedMethod === 'put' ||
|
|
6534
|
-
normalizedMethod === 'patch' ||
|
|
6535
|
-
normalizedMethod === 'delete');
|
|
6536
|
-
}
|
|
6537
|
-
|
|
6538
6487
|
const CSRF_TOKEN_HEADER = 'X-CSRF-Token';
|
|
6539
6488
|
/**
|
|
6540
6489
|
* Resolves the CSRF token manager and returns the current token. Returns
|
|
@@ -6989,13 +6938,22 @@ const DEFAULT_CONFIG$2 = {
|
|
|
6989
6938
|
jitterPercent: 0.5,
|
|
6990
6939
|
};
|
|
6991
6940
|
class LuvioFetchThrottlingRetryPolicy extends RetryPolicy {
|
|
6992
|
-
|
|
6941
|
+
// The request is read-only here: `shouldRetry` only inspects its `method` and
|
|
6942
|
+
// `basePath` to decide replay safety, and neither changes across retries. This
|
|
6943
|
+
// is why we take the plain `ResourceRequest` rather than the mutable-container
|
|
6944
|
+
// pattern the CSRF policy uses — that policy rewrites the request (new token)
|
|
6945
|
+
// between attempts; this one never mutates it.
|
|
6946
|
+
constructor(config = DEFAULT_CONFIG$2, request) {
|
|
6993
6947
|
super();
|
|
6994
6948
|
this.config = config;
|
|
6995
|
-
this.
|
|
6949
|
+
this.request = request;
|
|
6996
6950
|
}
|
|
6997
6951
|
async shouldRetry(result, context) {
|
|
6998
|
-
|
|
6952
|
+
// A request is safe to replay when it's a GET or when its path is a known
|
|
6953
|
+
// read issued over POST (e.g. GraphQL, aggregate-ui, search). Writes stay
|
|
6954
|
+
// non-retryable.
|
|
6955
|
+
return ((isRetryableMethod(this.request?.method) ||
|
|
6956
|
+
isRetryableReadPost(this.request?.basePath)) &&
|
|
6999
6957
|
(result.status === 429 || result.status === 503) &&
|
|
7000
6958
|
context.attempt < this.config.maxRetries &&
|
|
7001
6959
|
context.totalElapsedMs <= this.config.maxTimeToRetry);
|
|
@@ -7059,7 +7017,7 @@ function buildLuvioFetchRetryInterceptor() {
|
|
|
7059
7017
|
return (request, doFetch) => {
|
|
7060
7018
|
const csrfPolicy = new LuvioCsrfTokenRetryPolicy();
|
|
7061
7019
|
const composedPolicy = new ComposedRetryPolicy([
|
|
7062
|
-
new LuvioFetchThrottlingRetryPolicy(undefined, request
|
|
7020
|
+
new LuvioFetchThrottlingRetryPolicy(undefined, request),
|
|
7063
7021
|
csrfPolicy,
|
|
7064
7022
|
]);
|
|
7065
7023
|
const retryService = new RetryService(composedPolicy);
|
|
@@ -7173,189 +7131,6 @@ function buildLuvioActionMarksSendInterceptor() {
|
|
|
7173
7131
|
function isOneRuntime() {
|
|
7174
7132
|
return !!globalThis.LWR;
|
|
7175
7133
|
}
|
|
7176
|
-
/**
|
|
7177
|
-
* Public UIAPI url paths verified for HTTP transport.
|
|
7178
|
-
*
|
|
7179
|
-
* Inclusion criteria:
|
|
7180
|
-
* 1. The path's underlying Connect resource does NOT carry
|
|
7181
|
-
* `clientFilters=@ConnectClientFilters({@ConnectClientFilter(key = "UiTier")...})`.
|
|
7182
|
-
* 2. LDS actually invokes this URL via a Luvio adapter wired into
|
|
7183
|
-
* `ldsEngineCreator.js` (i.e. there is a corresponding `*AdapterFactory`
|
|
7184
|
-
* import). Connect resources with no LDS adapter are intentionally
|
|
7185
|
-
* excluded — adding them produces no traffic and just bloats the matcher.
|
|
7186
|
-
*
|
|
7187
|
-
* Where a single Connect resource exposes multiple URL shapes (e.g. a 4-segment
|
|
7188
|
-
* GET form alongside a 3-segment POST form), all forms LDS adapters can hit at
|
|
7189
|
-
* runtime are registered.
|
|
7190
|
-
*/
|
|
7191
|
-
const UIAPI_PUBLIC_PATHS = [
|
|
7192
|
-
// ----- Object Info -----
|
|
7193
|
-
// getObjectInfo — IObjectInfoResource
|
|
7194
|
-
'/ui-api/object-info/{objectApiName}',
|
|
7195
|
-
// getObjectInfos (batch) — IObjectInfoBatchResource
|
|
7196
|
-
'/ui-api/object-info/batch/{objectApiNames}',
|
|
7197
|
-
// getPicklistValues — IPicklistValuesResource
|
|
7198
|
-
'/ui-api/object-info/{objectApiName}/picklist-values/{recordTypeId}/{fieldApiName}',
|
|
7199
|
-
// getPicklistValuesByRecordType — IPicklistValuesByRecordTypeResource
|
|
7200
|
-
'/ui-api/object-info/{objectApiName}/picklist-values/{recordTypeId}',
|
|
7201
|
-
// ----- Records -----
|
|
7202
|
-
// createRecord (POST) — IRecordDataCollectionResource
|
|
7203
|
-
'/ui-api/records',
|
|
7204
|
-
// getRecord / updateRecord (PATCH) / deleteRecord (DELETE) — IRecordDataResource
|
|
7205
|
-
'/ui-api/records/{recordId}',
|
|
7206
|
-
// getRecords (batch GET) — IBatchRecordDataResource
|
|
7207
|
-
'/ui-api/records/batch/{recordIds}',
|
|
7208
|
-
// executeBatchRecordOperations (POST, no recordIds segment) — IBatchRecordResource
|
|
7209
|
-
'/ui-api/records/batch',
|
|
7210
|
-
// getRecordUi — IRecordUiResource
|
|
7211
|
-
'/ui-api/record-ui/{recordIds}',
|
|
7212
|
-
// ----- Layout -----
|
|
7213
|
-
// getLayout — ILayoutResource
|
|
7214
|
-
'/ui-api/layout/{objectApiName}',
|
|
7215
|
-
// getPathLayout — IPathLayoutResource
|
|
7216
|
-
'/ui-api/path/layout/{objectApiName}',
|
|
7217
|
-
// ----- Record Defaults -----
|
|
7218
|
-
// getRecordCreateDefaults — IRecordCreateDefaultsResource
|
|
7219
|
-
'/ui-api/record-defaults/create/{objectApiName}',
|
|
7220
|
-
// getRecordDefaultsTemplateForCreate — IRecordDefaultsTemplateCreateResource
|
|
7221
|
-
'/ui-api/record-defaults/template/create/{objectApiName}',
|
|
7222
|
-
// getRecordDefaultsTemplateClone — IRecordDefaultsTemplateCloneResource
|
|
7223
|
-
'/ui-api/record-defaults/template/clone/{recordId}',
|
|
7224
|
-
// ----- Duplicates -----
|
|
7225
|
-
// getDuplicateConfig — IDuplicateConfigResource
|
|
7226
|
-
'/ui-api/duplicates/{objectApiName}',
|
|
7227
|
-
// findDuplicates (POST) — IPredupeResource
|
|
7228
|
-
'/ui-api/predupe',
|
|
7229
|
-
// ----- GraphQL -----
|
|
7230
|
-
// executeGraphQL (POST) — IGraphQLResource (no /ui-api prefix)
|
|
7231
|
-
'/graphql',
|
|
7232
|
-
// ----- List UI -----
|
|
7233
|
-
// getListUiByName (2-segment form) — IListUiResource212
|
|
7234
|
-
'/ui-api/list-ui/{objectApiName}/{listViewApiName}',
|
|
7235
|
-
// 1-segment form covers both:
|
|
7236
|
-
// /ui-api/list-ui/{listViewId} — IListUiResource
|
|
7237
|
-
// /ui-api/list-ui/{objectApiName} — IListCollectionResource
|
|
7238
|
-
'/ui-api/list-ui/{objectApiNameOrListViewId}',
|
|
7239
|
-
// getListInfoByName (GET) / updateListInfoByApiName (PATCH) / deleteListInfo (DELETE) — IListInfoResource
|
|
7240
|
-
// (Also covers /ui-api/list-info/{listViewId} via shape collision.)
|
|
7241
|
-
'/ui-api/list-info/{objectApiName}/{listViewApiName}',
|
|
7242
|
-
// getListInfosByObjectName (GET) / createListInfo (POST) — IListInfoCreationAndCollectionResource
|
|
7243
|
-
// (Also covers /ui-api/list-info/batch — IListInfoBatchResource — via shape collision.)
|
|
7244
|
-
'/ui-api/list-info/{objectApiName}',
|
|
7245
|
-
// getListObjectInfo — IListObjectInfoResource
|
|
7246
|
-
'/ui-api/list-object-info/{objectApiName}',
|
|
7247
|
-
// postListRecordsByName (POST) — IListRecordsResource
|
|
7248
|
-
'/ui-api/list-records/{objectApiName}/{listViewApiName}',
|
|
7249
|
-
// getListPreferences (GET) / updateListPreferences (PATCH) — IListPreferencesResource
|
|
7250
|
-
'/ui-api/list-preferences/{objectApiName}/{listViewApiName}',
|
|
7251
|
-
// ----- Related List UI -----
|
|
7252
|
-
// getRelatedListInfo (GET) / updateRelatedListInfo (PATCH) — IRelatedListInfoResource
|
|
7253
|
-
// (Also covers /ui-api/related-list-info/{parentRecordId}/{relatedListId} via shape collision.)
|
|
7254
|
-
'/ui-api/related-list-info/{parentObjectApiName}/{relatedListId}',
|
|
7255
|
-
// getRelatedListInfoBatch — IRelatedListInfoBatchResource
|
|
7256
|
-
'/ui-api/related-list-info/batch/{parentObjectApiName}/{relatedListNames}',
|
|
7257
|
-
// getRelatedListsInfo (collection) — IRelatedListInfoCollectionResource
|
|
7258
|
-
'/ui-api/related-list-info/{parentObjectApiName}',
|
|
7259
|
-
// postRelatedListRecords (POST) — IRelatedListRecordsResource
|
|
7260
|
-
'/ui-api/related-list-records/{parentRecordId}/{relatedListId}',
|
|
7261
|
-
// postRelatedListRecordsBatch (POST, 3-segment form) — IRelatedListRecordsBatchResource
|
|
7262
|
-
'/ui-api/related-list-records/batch/{parentRecordId}',
|
|
7263
|
-
// getRelatedListRecordsBatch (GET, 4-segment form) — IRelatedListRecordsBatchResource [newly added]
|
|
7264
|
-
'/ui-api/related-list-records/batch/{parentRecordId}/{relatedListIds}',
|
|
7265
|
-
// getRelatedListCount — IRelatedListRecordCountResource
|
|
7266
|
-
'/ui-api/related-list-count/{parentRecordId}/{relatedListId}',
|
|
7267
|
-
// getRelatedListsCount (batch) — IRelatedListRecordCountBatchResource
|
|
7268
|
-
'/ui-api/related-list-count/batch/{parentRecordId}/{relatedListNames}',
|
|
7269
|
-
// getRelatedListPreferences (GET) / updateRelatedListPreferences (PATCH) — IRelatedListPreferencesResource
|
|
7270
|
-
'/ui-api/related-list-preferences/{preferencesId}',
|
|
7271
|
-
// getRelatedListPreferencesBatch — IRelatedListPreferencesBatchResource
|
|
7272
|
-
'/ui-api/related-list-preferences/batch/{preferencesIds}',
|
|
7273
|
-
// ----- Actions -----
|
|
7274
|
-
// getGlobalActions — IActionGlobalResource
|
|
7275
|
-
'/ui-api/actions/global',
|
|
7276
|
-
// getActionLayout — IActionLayoutResource
|
|
7277
|
-
'/ui-api/actions/layout/{actionApiName}',
|
|
7278
|
-
// getLookupActions — IActionLookupResource
|
|
7279
|
-
'/ui-api/actions/lookup/{objectApiNames}',
|
|
7280
|
-
// getObjectCreateActions — IActionObjectResource
|
|
7281
|
-
'/ui-api/actions/object/{objectApiName}/record-create',
|
|
7282
|
-
// getActionOverrides — IActionOverrideResource
|
|
7283
|
-
'/ui-api/actions/overrides/{objectApiName}',
|
|
7284
|
-
// performQuickAction (POST) / performUpdateRecordQuickAction (PATCH) — IActionPerformQuickActionResource
|
|
7285
|
-
'/ui-api/actions/perform-quick-action/{actionApiName}',
|
|
7286
|
-
// getQuickActionInfo — IActionQuickActionInfoResource
|
|
7287
|
-
'/ui-api/actions/quick-action-info/{actionApiName}',
|
|
7288
|
-
// getRecordActions — IActionRecordResource
|
|
7289
|
-
'/ui-api/actions/record/{recordIds}',
|
|
7290
|
-
// getRecordEditActions — IActionRecordEditResource
|
|
7291
|
-
'/ui-api/actions/record/{recordIds}/record-edit',
|
|
7292
|
-
// getAllRelatedListActionsForRecord (4-segment form) — IActionRelatedListResource [newly added]
|
|
7293
|
-
'/ui-api/actions/record/{recordIds}/related-list',
|
|
7294
|
-
// postRelatedListActions (POST) — IActionRelatedListResource
|
|
7295
|
-
'/ui-api/actions/record/{recordIds}/related-list/{relatedListId}',
|
|
7296
|
-
// postRelatedListsActions (POST) / getRelatedListsActions (GET, 5-segment form) — IActionRelatedListBatchResource
|
|
7297
|
-
'/ui-api/actions/record/{recordIds}/related-list/batch',
|
|
7298
|
-
// getRelatedListsActions (GET, 6-segment form) — IActionRelatedListBatchResource [newly added]
|
|
7299
|
-
'/ui-api/actions/record/{recordIds}/related-list/batch/{relatedListIds}',
|
|
7300
|
-
// getRelatedListRecordActions — IActionRelatedListRecordResource
|
|
7301
|
-
'/ui-api/actions/record/{recordIds}/related-list-record/{relatedListRecordIds}',
|
|
7302
|
-
// getQuickActionDefaults — IActionQuickActionDefaultsResource
|
|
7303
|
-
'/ui-api/actions/record-defaults/{actionApiName}',
|
|
7304
|
-
// getFlexipageFormulaOverrides — IActionFlexipageFormulaActivationResource
|
|
7305
|
-
'/ui-api/actions/formula-activation/{actionFeature}',
|
|
7306
|
-
// ----- Lookup / Search -----
|
|
7307
|
-
// lookup (POST) — ILookupEntityResource
|
|
7308
|
-
'/ui-api/lookups/{objectApiName}/{keyPrefix}/{targetApiName}',
|
|
7309
|
-
// searchResults (POST) — ISearchResultsResource
|
|
7310
|
-
'/ui-api/search/results',
|
|
7311
|
-
// searchKeywordResults (POST) — IKeywordSearchResultsResource
|
|
7312
|
-
'/ui-api/search/results/keyword',
|
|
7313
|
-
// getSearchFilterMetadata — ISearchInfoFilterMetadataCollectionResource
|
|
7314
|
-
'/ui-api/search-info/{objectApiName}/filters',
|
|
7315
|
-
// getSearchFilterOptions — ISearchInfoFilterOptionsResource
|
|
7316
|
-
'/ui-api/search-info/{objectApiName}/filters/{filterApiName}/options',
|
|
7317
|
-
// getLookupMetadata — ILookupMetadataResource
|
|
7318
|
-
'/ui-api/search-info/{objectApiName}/lookup/{fieldApiName}',
|
|
7319
|
-
// ----- MRU Lists -----
|
|
7320
|
-
// getMruListUi — IMruListUiResource
|
|
7321
|
-
'/ui-api/mru-list-ui/{objectApiName}',
|
|
7322
|
-
// getMruListRecords — IMruListRecordsResource
|
|
7323
|
-
'/ui-api/mru-list-records/{objectApiName}',
|
|
7324
|
-
// ----- Apps / Nav -----
|
|
7325
|
-
// getNavItems — INavItemsResource
|
|
7326
|
-
'/ui-api/nav-items',
|
|
7327
|
-
// getAllApps — IAppsResource
|
|
7328
|
-
'/ui-api/apps',
|
|
7329
|
-
// getAppDetails — IAppResource
|
|
7330
|
-
'/ui-api/apps/{appId}',
|
|
7331
|
-
];
|
|
7332
|
-
/**
|
|
7333
|
-
* Private UIAPI url paths gated by the private-endpoint gates per runtime.
|
|
7334
|
-
*
|
|
7335
|
-
* Inclusion criteria:
|
|
7336
|
-
* 1. The path's underlying Connect resource carries
|
|
7337
|
-
* `clientFilters=@ConnectClientFilters({@ConnectClientFilter(key = "UiTier")...})`,
|
|
7338
|
-
* which restricts callers to the UI tier (one.app / UISDK runtime) and
|
|
7339
|
-
* excludes the public REST API.
|
|
7340
|
-
* 2. LDS actually invokes this URL via a Luvio adapter wired into
|
|
7341
|
-
* `ldsEngineCreator.js`.
|
|
7342
|
-
*/
|
|
7343
|
-
const UIAPI_PRIVATE_PATHS = [
|
|
7344
|
-
// ----- Record Avatars -----
|
|
7345
|
-
// getRecordAvatars (batch) — IRecordAvatarsBatchResource
|
|
7346
|
-
'/ui-api/record-avatars/batch/{recordIds}',
|
|
7347
|
-
// updateRecordAvatar (POST) — IRecordAvatarsAssociationResource
|
|
7348
|
-
'/ui-api/record-avatars/{recordId}/association',
|
|
7349
|
-
// ----- Layout -----
|
|
7350
|
-
// getLayoutUserState (GET) / updateLayoutUserState (PATCH) — ILayoutUserStateResource
|
|
7351
|
-
'/ui-api/layout/{objectApiName}/user-state',
|
|
7352
|
-
// ----- GraphQL -----
|
|
7353
|
-
// executeGraphQLBatch (POST) — IGraphQLBatchResource (no /ui-api prefix)
|
|
7354
|
-
'/graphql/batch',
|
|
7355
|
-
// ----- Aggregate UI -----
|
|
7356
|
-
// executeAggregateUi (POST) — IAggregateUiResource
|
|
7357
|
-
'/ui-api/aggregate-ui',
|
|
7358
|
-
];
|
|
7359
7134
|
/**
|
|
7360
7135
|
* Single content documents version URL enabled/disabled by killswitch.
|
|
7361
7136
|
* Exported for reuse in tests.
|
|
@@ -7433,14 +7208,8 @@ function getEnabledPaths() {
|
|
|
7433
7208
|
}
|
|
7434
7209
|
return Array.from(enabled);
|
|
7435
7210
|
}
|
|
7436
|
-
function buildMatchers(paths) {
|
|
7437
|
-
return paths.map((path) => {
|
|
7438
|
-
const regexString = path.replace(/\{.+?\}/g, '[^/]+');
|
|
7439
|
-
return new RegExp(`^${regexString}$`);
|
|
7440
|
-
});
|
|
7441
|
-
}
|
|
7442
7211
|
// Precompute enabled path matchers at module load to avoid per-request rebuild
|
|
7443
|
-
const ENABLED_PATH_MATCHERS =
|
|
7212
|
+
const ENABLED_PATH_MATCHERS = compilePathMatchers(getEnabledPaths());
|
|
7444
7213
|
/**
|
|
7445
7214
|
* Indicates whether any predicate-enabled path sets are active.
|
|
7446
7215
|
* Used by adapter composition to decide whether to include the fetch adapter.
|
|
@@ -11688,4 +11457,4 @@ function ldsEngineCreator() {
|
|
|
11688
11457
|
}
|
|
11689
11458
|
|
|
11690
11459
|
export { LexRequestStrategy, PDL_ENGINE_REGISTRATION_ID, PdlPrefetcherEventType, PdlRequestPriority, buildPredictorForContext, configService, ldsEngineCreator as default, initializeLDS, initializeOneStore, notifyUpdateAvailableFactory, registerRequestStrategy, saveRequestAsPrediction, subscribeToPrefetcherEvents, unregisterRequestStrategy, whenPredictionsReady };
|
|
11691
|
-
// version: 1.
|
|
11460
|
+
// version: 1.458.0-5aef0572f2
|
|
@@ -1,34 +1,8 @@
|
|
|
1
1
|
import { type ResourceRequest } from '@luvio/engine';
|
|
2
|
+
import { UIAPI_PUBLIC_PATHS, UIAPI_PRIVATE_PATHS } from '@salesforce/lds-network-fetch';
|
|
2
3
|
import type { RequestLogger } from '@salesforce/lds-network-fetch';
|
|
3
4
|
import type { RequestTracker } from './instrumentation-utils';
|
|
4
|
-
|
|
5
|
-
* Public UIAPI url paths verified for HTTP transport.
|
|
6
|
-
*
|
|
7
|
-
* Inclusion criteria:
|
|
8
|
-
* 1. The path's underlying Connect resource does NOT carry
|
|
9
|
-
* `clientFilters=@ConnectClientFilters({@ConnectClientFilter(key = "UiTier")...})`.
|
|
10
|
-
* 2. LDS actually invokes this URL via a Luvio adapter wired into
|
|
11
|
-
* `ldsEngineCreator.js` (i.e. there is a corresponding `*AdapterFactory`
|
|
12
|
-
* import). Connect resources with no LDS adapter are intentionally
|
|
13
|
-
* excluded — adding them produces no traffic and just bloats the matcher.
|
|
14
|
-
*
|
|
15
|
-
* Where a single Connect resource exposes multiple URL shapes (e.g. a 4-segment
|
|
16
|
-
* GET form alongside a 3-segment POST form), all forms LDS adapters can hit at
|
|
17
|
-
* runtime are registered.
|
|
18
|
-
*/
|
|
19
|
-
export declare const UIAPI_PUBLIC_PATHS: string[];
|
|
20
|
-
/**
|
|
21
|
-
* Private UIAPI url paths gated by the private-endpoint gates per runtime.
|
|
22
|
-
*
|
|
23
|
-
* Inclusion criteria:
|
|
24
|
-
* 1. The path's underlying Connect resource carries
|
|
25
|
-
* `clientFilters=@ConnectClientFilters({@ConnectClientFilter(key = "UiTier")...})`,
|
|
26
|
-
* which restricts callers to the UI tier (one.app / UISDK runtime) and
|
|
27
|
-
* excludes the public REST API.
|
|
28
|
-
* 2. LDS actually invokes this URL via a Luvio adapter wired into
|
|
29
|
-
* `ldsEngineCreator.js`.
|
|
30
|
-
*/
|
|
31
|
-
export declare const UIAPI_PRIVATE_PATHS: string[];
|
|
5
|
+
export { UIAPI_PUBLIC_PATHS, UIAPI_PRIVATE_PATHS };
|
|
32
6
|
/**
|
|
33
7
|
* Single content documents version URL enabled/disabled by killswitch.
|
|
34
8
|
* Exported for reuse in tests.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { RetryPolicy, type RetryContext } from '@conduit-client/service-retry/v1';
|
|
2
|
-
import type { FetchResponse } from '@luvio/engine';
|
|
2
|
+
import type { FetchResponse, ResourceRequest } from '@luvio/engine';
|
|
3
3
|
type LuvioFetchThrottlingRetryPolicyConfig = {
|
|
4
4
|
maxRetries: number;
|
|
5
5
|
maxTimeToRetry: number;
|
|
@@ -10,8 +10,8 @@ type LuvioFetchThrottlingRetryPolicyConfig = {
|
|
|
10
10
|
};
|
|
11
11
|
export declare class LuvioFetchThrottlingRetryPolicy extends RetryPolicy<FetchResponse<any>> {
|
|
12
12
|
private config;
|
|
13
|
-
private
|
|
14
|
-
constructor(config?: LuvioFetchThrottlingRetryPolicyConfig,
|
|
13
|
+
private request?;
|
|
14
|
+
constructor(config?: LuvioFetchThrottlingRetryPolicyConfig, request?: ResourceRequest | undefined);
|
|
15
15
|
shouldRetry(result: FetchResponse<any>, context: RetryContext<FetchResponse<any>>): Promise<boolean>;
|
|
16
16
|
calculateDelay(result: FetchResponse<any>, context: RetryContext<FetchResponse<any>>): Promise<number>;
|
|
17
17
|
parseRetryAfterHeader(result: FetchResponse<any>): number | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-runtime-aura",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.458.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "LDS engine for Aura runtime.",
|
|
6
6
|
"main": "dist/ldsEngineCreator.js",
|
|
@@ -34,61 +34,61 @@
|
|
|
34
34
|
"release:corejar": "yarn build && ../core-build/scripts/core.js --name=lds-runtime-aura"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@conduit-client/service-provisioner": "3.27.
|
|
38
|
-
"@conduit-client/tools-core": "3.27.
|
|
39
|
-
"@salesforce/lds-adapters-apex": "^1.
|
|
40
|
-
"@salesforce/lds-adapters-uiapi": "^1.
|
|
41
|
-
"@salesforce/lds-ads-bridge": "^1.
|
|
42
|
-
"@salesforce/lds-aura-storage": "^1.
|
|
43
|
-
"@salesforce/lds-bindings": "^1.
|
|
44
|
-
"@salesforce/lds-instrumentation": "^1.
|
|
45
|
-
"@salesforce/lds-network-adapter": "^1.
|
|
46
|
-
"@salesforce/lds-network-aura": "^1.
|
|
47
|
-
"@salesforce/lds-network-fetch": "^1.
|
|
37
|
+
"@conduit-client/service-provisioner": "3.27.1",
|
|
38
|
+
"@conduit-client/tools-core": "3.27.1",
|
|
39
|
+
"@salesforce/lds-adapters-apex": "^1.458.0",
|
|
40
|
+
"@salesforce/lds-adapters-uiapi": "^1.458.0",
|
|
41
|
+
"@salesforce/lds-ads-bridge": "^1.458.0",
|
|
42
|
+
"@salesforce/lds-aura-storage": "^1.458.0",
|
|
43
|
+
"@salesforce/lds-bindings": "^1.458.0",
|
|
44
|
+
"@salesforce/lds-instrumentation": "^1.458.0",
|
|
45
|
+
"@salesforce/lds-network-adapter": "^1.458.0",
|
|
46
|
+
"@salesforce/lds-network-aura": "^1.458.0",
|
|
47
|
+
"@salesforce/lds-network-fetch": "^1.458.0",
|
|
48
48
|
"jwt-encode": "1.0.1"
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
|
-
"@conduit-client/command-aura-graphql-normalized-cache-control": "3.27.
|
|
52
|
-
"@conduit-client/command-aura-network": "3.27.
|
|
53
|
-
"@conduit-client/command-aura-normalized-cache-control": "3.27.
|
|
54
|
-
"@conduit-client/command-fetch-network": "3.27.
|
|
55
|
-
"@conduit-client/command-http-graphql-normalized-cache-control": "3.27.
|
|
56
|
-
"@conduit-client/command-http-normalized-cache-control": "3.27.
|
|
57
|
-
"@conduit-client/command-ndjson": "3.27.
|
|
58
|
-
"@conduit-client/command-network": "3.27.
|
|
59
|
-
"@conduit-client/command-sse": "3.27.
|
|
60
|
-
"@conduit-client/command-streaming": "3.27.
|
|
61
|
-
"@conduit-client/jwt-manager": "3.27.
|
|
62
|
-
"@conduit-client/service-aura-network": "3.27.
|
|
63
|
-
"@conduit-client/service-bindings-imperative": "3.27.
|
|
64
|
-
"@conduit-client/service-bindings-lwc": "3.27.
|
|
65
|
-
"@conduit-client/service-cache": "3.27.
|
|
66
|
-
"@conduit-client/service-cache-control": "3.27.
|
|
67
|
-
"@conduit-client/service-cache-inclusion-policy": "3.27.
|
|
68
|
-
"@conduit-client/service-config": "3.27.
|
|
69
|
-
"@conduit-client/service-feature-flags": "3.27.
|
|
70
|
-
"@conduit-client/service-fetch-network": "3.27.
|
|
71
|
-
"@conduit-client/service-instrument-command": "3.27.
|
|
72
|
-
"@conduit-client/service-pubsub": "3.27.
|
|
73
|
-
"@conduit-client/service-renewable-resource-manager": "3.27.
|
|
74
|
-
"@conduit-client/service-store": "3.27.
|
|
75
|
-
"@conduit-client/utils": "3.27.
|
|
51
|
+
"@conduit-client/command-aura-graphql-normalized-cache-control": "3.27.1",
|
|
52
|
+
"@conduit-client/command-aura-network": "3.27.1",
|
|
53
|
+
"@conduit-client/command-aura-normalized-cache-control": "3.27.1",
|
|
54
|
+
"@conduit-client/command-fetch-network": "3.27.1",
|
|
55
|
+
"@conduit-client/command-http-graphql-normalized-cache-control": "3.27.1",
|
|
56
|
+
"@conduit-client/command-http-normalized-cache-control": "3.27.1",
|
|
57
|
+
"@conduit-client/command-ndjson": "3.27.1",
|
|
58
|
+
"@conduit-client/command-network": "3.27.1",
|
|
59
|
+
"@conduit-client/command-sse": "3.27.1",
|
|
60
|
+
"@conduit-client/command-streaming": "3.27.1",
|
|
61
|
+
"@conduit-client/jwt-manager": "3.27.1",
|
|
62
|
+
"@conduit-client/service-aura-network": "3.27.1",
|
|
63
|
+
"@conduit-client/service-bindings-imperative": "3.27.1",
|
|
64
|
+
"@conduit-client/service-bindings-lwc": "3.27.1",
|
|
65
|
+
"@conduit-client/service-cache": "3.27.1",
|
|
66
|
+
"@conduit-client/service-cache-control": "3.27.1",
|
|
67
|
+
"@conduit-client/service-cache-inclusion-policy": "3.27.1",
|
|
68
|
+
"@conduit-client/service-config": "3.27.1",
|
|
69
|
+
"@conduit-client/service-feature-flags": "3.27.1",
|
|
70
|
+
"@conduit-client/service-fetch-network": "3.27.1",
|
|
71
|
+
"@conduit-client/service-instrument-command": "3.27.1",
|
|
72
|
+
"@conduit-client/service-pubsub": "3.27.1",
|
|
73
|
+
"@conduit-client/service-renewable-resource-manager": "3.27.1",
|
|
74
|
+
"@conduit-client/service-store": "3.27.1",
|
|
75
|
+
"@conduit-client/utils": "3.27.1",
|
|
76
76
|
"@luvio/network-adapter-composable": "0.161.2",
|
|
77
77
|
"@luvio/network-adapter-fetch": "0.161.2",
|
|
78
78
|
"@lwc/state": "^0.29.0",
|
|
79
|
-
"@salesforce/lds-adapters-onestore-graphql": "^1.
|
|
79
|
+
"@salesforce/lds-adapters-onestore-graphql": "^1.458.0",
|
|
80
80
|
"@salesforce/lds-adapters-uiapi-lex": "^1.415.0",
|
|
81
|
-
"@salesforce/lds-durable-storage": "^1.
|
|
82
|
-
"@salesforce/lds-luvio-service": "^1.
|
|
83
|
-
"@salesforce/lds-luvio-uiapi-records-service": "^1.
|
|
81
|
+
"@salesforce/lds-durable-storage": "^1.458.0",
|
|
82
|
+
"@salesforce/lds-luvio-service": "^1.458.0",
|
|
83
|
+
"@salesforce/lds-luvio-uiapi-records-service": "^1.458.0"
|
|
84
84
|
},
|
|
85
85
|
"luvioBundlesize": [
|
|
86
86
|
{
|
|
87
87
|
"path": "./dist/ldsEngineCreator.js",
|
|
88
88
|
"maxSize": {
|
|
89
|
-
"none": "
|
|
89
|
+
"none": "428 kB",
|
|
90
90
|
"min": "190 kB",
|
|
91
|
-
"compressed": "
|
|
91
|
+
"compressed": "77 kB"
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
],
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/// <reference types="jest" />
|
|
2
|
-
export declare const createStorage: jest.Mock<any, any, any>;
|
|
3
|
-
export declare const clearStorages: jest.Mock<any, any, any>;
|
|
4
|
-
export declare const setDurableStorageImplementation: jest.Mock<any, any, any>;
|
|
5
|
-
export declare const getDurableStorageImplementation: jest.Mock<any, any, any>;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export declare function setupInstrumentation(): void;
|
|
2
|
-
export declare function LRUCache(): Map<any, any>;
|
|
3
|
-
export declare function incrementCounterMetric(): void;
|
|
4
|
-
export declare function updatePercentileHistogramMetric(): void;
|
|
5
|
-
export declare function instrumentAdapter<_C, _D>(adapter: any, _metadata: any): any;
|
|
6
|
-
export declare function instrumentLuvio(): void;
|
|
7
|
-
export declare function instrumentStoreMethods(): void;
|
|
8
|
-
export declare function setLdsAdaptersUiapiInstrumentation(): void;
|
|
9
|
-
export declare function setLdsNetworkAdapterInstrumentation(): void;
|
|
10
|
-
export declare function logObjectInfoChanged(): void;
|
|
11
|
-
export declare function executeAsyncActivity(_name: string, execute: (act: any) => Promise<void>, _options?: any): Promise<void>;
|
|
12
|
-
export declare const METRIC_KEYS: {
|
|
13
|
-
PREDICTIVE_DATA_LOADING_PREDICT: string;
|
|
14
|
-
PREDICTIVE_DATA_LOADING_SAVE_REQUEST: string;
|
|
15
|
-
};
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
export declare function counter(): {
|
|
2
|
-
increment(): void;
|
|
3
|
-
decrement(): void;
|
|
4
|
-
getValue(): void;
|
|
5
|
-
reset(): void;
|
|
6
|
-
};
|
|
7
|
-
export declare function gauge(): {
|
|
8
|
-
setValue(): void;
|
|
9
|
-
getValue(): void;
|
|
10
|
-
reset(): void;
|
|
11
|
-
};
|
|
12
|
-
export declare function mark(): {};
|
|
13
|
-
export declare function markStart(): {};
|
|
14
|
-
export declare function markEnd(): {};
|
|
15
|
-
export declare function perfStart(): void;
|
|
16
|
-
export declare function perfEnd(): void;
|
|
17
|
-
export declare function percentileHistogram(): {
|
|
18
|
-
update(): void;
|
|
19
|
-
getValue(): void;
|
|
20
|
-
reset(): void;
|
|
21
|
-
};
|
|
22
|
-
export declare function time(): void;
|
|
23
|
-
export declare function timer(): {
|
|
24
|
-
addDuration(): void;
|
|
25
|
-
getValue(): void;
|
|
26
|
-
time(): void;
|
|
27
|
-
};
|
|
28
|
-
export declare function registerCacheStats(): {
|
|
29
|
-
logHits(): void;
|
|
30
|
-
logMisses(): void;
|
|
31
|
-
};
|
|
32
|
-
export declare function registerPlugin(): void;
|
|
33
|
-
export declare function registerPeriodicLogger(): void;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/// <reference types="jest" />
|
|
2
|
-
export declare const setTrustedSignalSet: jest.Mock<any, any, any>;
|
|
3
|
-
export declare const setTrustedContextSet: jest.Mock<any, any, any>;
|
|
4
|
-
export declare const setContextKeys: jest.Mock<any, any, any>;
|
|
5
|
-
export declare const __dangerous_do_not_use_addTrustedContext: jest.Mock<any, any, any>;
|
|
6
|
-
export declare const isTrustedSignal: jest.Mock<any, any, any>;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
declare function stop(_userSchemaOrText?: any | string, _userData?: any): void;
|
|
2
|
-
declare function error(_error: Error, _userSchemaOrText?: any | string, _userData?: any): void;
|
|
3
|
-
declare function discard(): void;
|
|
4
|
-
declare function terminate(): void;
|
|
5
|
-
export declare const activity: {
|
|
6
|
-
stop: typeof stop;
|
|
7
|
-
error: typeof error;
|
|
8
|
-
discard: typeof discard;
|
|
9
|
-
terminate: typeof terminate;
|
|
10
|
-
getId: () => string;
|
|
11
|
-
};
|
|
12
|
-
export {};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export { activity } from './activity';
|
|
2
|
-
export { instrumentation } from './instrumentation';
|
|
3
|
-
export { idleDetector } from './idleDetector';
|
|
4
|
-
export declare function getInstrumentation(_name: string): {
|
|
5
|
-
log: (_schema: any, _data?: any) => void;
|
|
6
|
-
error: (_error: unknown, _userSchemaOrText?: any, _userData?: any) => void;
|
|
7
|
-
startActivity: (_name: string) => any;
|
|
8
|
-
incrementCounter: (_operation: string, _increment?: number | undefined, _hasError?: boolean | undefined, _tags?: any) => void;
|
|
9
|
-
trackValue: (_operation: string, _value: number, _hasError?: boolean | undefined, _tags?: any) => void;
|
|
10
|
-
bucketValue: (_operation: string, _value: number, _buckets: number[]) => void;
|
|
11
|
-
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
declare function requestIdleDetectedCallback(_callback: any): void;
|
|
2
|
-
declare function declareNotifierTaskSingle(_name: string): {
|
|
3
|
-
isBusy: boolean;
|
|
4
|
-
done: () => void;
|
|
5
|
-
};
|
|
6
|
-
declare function declareNotifierTaskMulti(_name: string, _existingBusyCount?: number): {
|
|
7
|
-
isBusy: boolean;
|
|
8
|
-
add: () => void;
|
|
9
|
-
done: () => void;
|
|
10
|
-
};
|
|
11
|
-
declare function declarePollableTaskMulti(_name: string, _isBusyChecker: any): void;
|
|
12
|
-
export declare const idleDetector: {
|
|
13
|
-
requestIdleDetectedCallback: typeof requestIdleDetectedCallback;
|
|
14
|
-
declareNotifierTaskSingle: typeof declareNotifierTaskSingle;
|
|
15
|
-
declareNotifierTaskMulti: typeof declareNotifierTaskMulti;
|
|
16
|
-
declarePollableTaskMulti: typeof declarePollableTaskMulti;
|
|
17
|
-
};
|
|
18
|
-
export {};
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
declare function log(_schema: any, _data?: any): void;
|
|
2
|
-
declare function error(_error: unknown, _userSchemaOrText?: any | string, _userData?: any): void;
|
|
3
|
-
declare function startActivity(_name: string): any;
|
|
4
|
-
declare function incrementCounter(_operation: string, _increment?: number, _hasError?: boolean, _tags?: any): void;
|
|
5
|
-
declare function trackValue(_operation: string, _value: number, _hasError?: boolean, _tags?: any): void;
|
|
6
|
-
declare function bucketValue(_operation: string, _value: number, _buckets: number[]): void;
|
|
7
|
-
export declare const instrumentation: {
|
|
8
|
-
log: typeof log;
|
|
9
|
-
error: typeof error;
|
|
10
|
-
startActivity: typeof startActivity;
|
|
11
|
-
incrementCounter: typeof incrementCounter;
|
|
12
|
-
trackValue: typeof trackValue;
|
|
13
|
-
bucketValue: typeof bucketValue;
|
|
14
|
-
};
|
|
15
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const adapterUnfulfilledErrorSchema: {};
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import type { FetchParameters } from '@conduit-client/service-fetch-network/v1';
|
|
2
|
-
/**
|
|
3
|
-
* Extracts the HTTP method from FetchParameters, matching the Fetch API's own
|
|
4
|
-
* precedence: an options.method override wins over a Request object's method
|
|
5
|
-
* (e.g. `fetch(new Request(url, { method: 'GET' }), { method: 'POST' })`
|
|
6
|
-
* resolves to `POST`).
|
|
7
|
-
*/
|
|
8
|
-
export declare function getFetchMethod([urlOrRequest, options]: FetchParameters): string | undefined;
|
|
9
|
-
/**
|
|
10
|
-
* Only GET requests are safe to replay automatically on 429/503 — replaying a
|
|
11
|
-
* write (POST/PUT/PATCH/DELETE) risks executing a mutation more than once.
|
|
12
|
-
* Shared by both the Luvio and generic-fetch throttling retry policies so the
|
|
13
|
-
* write-guard rule lives in exactly one place.
|
|
14
|
-
*/
|
|
15
|
-
export declare function isRetryableMethod(method: string | undefined): boolean;
|
|
16
|
-
/**
|
|
17
|
-
* A request whose operationType is `query` is a read, so it is safe to replay
|
|
18
|
-
* automatically on 429/503 even when the transport uses a non-GET method (e.g.
|
|
19
|
-
* a GraphQL/aggregate-ui read issued as a POST). This complements
|
|
20
|
-
* `isRetryableMethod`: OneStore seeds the command's operationType into the
|
|
21
|
-
* per-request context, and the throttling policy retries when either the method
|
|
22
|
-
* is GET or the operationType is `query`. Only `query` is retryable — `mutation`
|
|
23
|
-
* and an absent/`graphql` operationType are never replayed.
|
|
24
|
-
*/
|
|
25
|
-
export declare function isRetryableOperationType(operationType: string | undefined): boolean;
|
|
26
|
-
/**
|
|
27
|
-
* Determines if the HTTP method requires CSRF protection.
|
|
28
|
-
* Only mutating operations (POST, PUT, PATCH, DELETE) require CSRF tokens.
|
|
29
|
-
*/
|
|
30
|
-
export declare function isCsrfMethod(method: string | undefined): boolean;
|