quidproquo-core 0.1.11 → 0.1.13
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/lib/commonjs/actions/crypto/CryptoActionType.d.ts +4 -0
- package/lib/commonjs/actions/crypto/CryptoActionType.js +9 -0
- package/lib/commonjs/actions/crypto/CryptoActionType.js.map +1 -0
- package/lib/commonjs/actions/crypto/CryptoContext.d.ts +1 -0
- package/lib/commonjs/actions/crypto/CryptoContext.js +3 -0
- package/lib/commonjs/actions/crypto/CryptoContext.js.map +1 -0
- package/lib/commonjs/actions/crypto/CryptoDecryptActionRequester.d.ts +10 -0
- package/lib/commonjs/actions/crypto/CryptoDecryptActionRequester.js +17 -0
- package/lib/commonjs/actions/crypto/CryptoDecryptActionRequester.js.map +1 -0
- package/lib/commonjs/actions/crypto/CryptoDecryptActionTypes.d.ts +14 -0
- package/lib/commonjs/actions/crypto/CryptoDecryptActionTypes.js +3 -0
- package/lib/commonjs/actions/crypto/CryptoDecryptActionTypes.js.map +1 -0
- package/lib/commonjs/actions/crypto/CryptoEncryptActionRequester.d.ts +8 -0
- package/lib/commonjs/actions/crypto/CryptoEncryptActionRequester.js +15 -0
- package/lib/commonjs/actions/crypto/CryptoEncryptActionRequester.js.map +1 -0
- package/lib/commonjs/actions/crypto/CryptoEncryptActionTypes.d.ts +14 -0
- package/lib/commonjs/actions/crypto/CryptoEncryptActionTypes.js +3 -0
- package/lib/commonjs/actions/crypto/CryptoEncryptActionTypes.js.map +1 -0
- package/lib/commonjs/actions/crypto/index.d.ts +6 -0
- package/lib/commonjs/actions/crypto/index.js +23 -0
- package/lib/commonjs/actions/crypto/index.js.map +1 -0
- package/lib/commonjs/actions/index.d.ts +1 -0
- package/lib/commonjs/actions/index.js +1 -0
- package/lib/commonjs/actions/index.js.map +1 -1
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreActionType.d.ts +2 -1
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreActionType.js +1 -0
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreActionType.js.map +1 -1
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreScanAllScopesActionRequester.d.ts +32 -0
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreScanAllScopesActionRequester.js +47 -0
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreScanAllScopesActionRequester.js.map +1 -0
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreScanAllScopesActionTypes.d.ts +23 -0
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreScanAllScopesActionTypes.js +3 -0
- package/lib/commonjs/actions/keyValueStore/KeyValueStoreScanAllScopesActionTypes.js.map +1 -0
- package/lib/commonjs/actions/keyValueStore/index.d.ts +2 -0
- package/lib/commonjs/actions/keyValueStore/index.js +2 -0
- package/lib/commonjs/actions/keyValueStore/index.js.map +1 -1
- package/lib/commonjs/actions/keyValueStore/types/KvsQueryOperation.d.ts +2 -2
- package/lib/commonjs/actions/keyValueStore/types/KvsQueryOperation.js.map +1 -1
- package/lib/commonjs/config/QPQConfig.d.ts +1 -0
- package/lib/commonjs/config/QPQConfig.js +1 -0
- package/lib/commonjs/config/QPQConfig.js.map +1 -1
- package/lib/commonjs/config/settings/cryptoKey.d.ts +9 -0
- package/lib/commonjs/config/settings/cryptoKey.js +13 -0
- package/lib/commonjs/config/settings/cryptoKey.js.map +1 -0
- package/lib/commonjs/config/settings/index.d.ts +1 -0
- package/lib/commonjs/config/settings/index.js +1 -0
- package/lib/commonjs/config/settings/index.js.map +1 -1
- package/lib/commonjs/config/settings/keyValueStore.d.ts +38 -1
- package/lib/commonjs/config/settings/keyValueStore.js +1 -0
- package/lib/commonjs/config/settings/keyValueStore.js.map +1 -1
- package/lib/commonjs/logic/scope/scopedKvsValue.d.ts +4 -0
- package/lib/commonjs/logic/scope/scopedKvsValue.js +19 -1
- package/lib/commonjs/logic/scope/scopedKvsValue.js.map +1 -1
- package/lib/commonjs/qpqCoreUtils.d.ts +4 -1
- package/lib/commonjs/qpqCoreUtils.js +21 -2
- package/lib/commonjs/qpqCoreUtils.js.map +1 -1
- package/lib/commonjs/qpqCoreUtilsLib.d.ts +3 -0
- package/lib/commonjs/types/KvsStreamEvent.d.ts +14 -0
- package/lib/commonjs/types/KvsStreamEvent.js +16 -0
- package/lib/commonjs/types/KvsStreamEvent.js.map +1 -0
- package/lib/commonjs/types/StorySession.d.ts +1 -0
- package/lib/commonjs/types/StorySession.js +1 -0
- package/lib/commonjs/types/StorySession.js.map +1 -1
- package/lib/commonjs/types/index.d.ts +1 -0
- package/lib/commonjs/types/index.js +1 -0
- package/lib/commonjs/types/index.js.map +1 -1
- package/lib/esm/actions/crypto/CryptoActionType.d.ts +4 -0
- package/lib/esm/actions/crypto/CryptoActionType.js +6 -0
- package/lib/esm/actions/crypto/CryptoActionType.js.map +1 -0
- package/lib/esm/actions/crypto/CryptoContext.d.ts +1 -0
- package/lib/esm/actions/crypto/CryptoContext.js +2 -0
- package/lib/esm/actions/crypto/CryptoContext.js.map +1 -0
- package/lib/esm/actions/crypto/CryptoDecryptActionRequester.d.ts +10 -0
- package/lib/esm/actions/crypto/CryptoDecryptActionRequester.js +13 -0
- package/lib/esm/actions/crypto/CryptoDecryptActionRequester.js.map +1 -0
- package/lib/esm/actions/crypto/CryptoDecryptActionTypes.d.ts +14 -0
- package/lib/esm/actions/crypto/CryptoDecryptActionTypes.js +2 -0
- package/lib/esm/actions/crypto/CryptoDecryptActionTypes.js.map +1 -0
- package/lib/esm/actions/crypto/CryptoEncryptActionRequester.d.ts +8 -0
- package/lib/esm/actions/crypto/CryptoEncryptActionRequester.js +11 -0
- package/lib/esm/actions/crypto/CryptoEncryptActionRequester.js.map +1 -0
- package/lib/esm/actions/crypto/CryptoEncryptActionTypes.d.ts +14 -0
- package/lib/esm/actions/crypto/CryptoEncryptActionTypes.js +2 -0
- package/lib/esm/actions/crypto/CryptoEncryptActionTypes.js.map +1 -0
- package/lib/esm/actions/crypto/index.d.ts +6 -0
- package/lib/esm/actions/crypto/index.js +7 -0
- package/lib/esm/actions/crypto/index.js.map +1 -0
- package/lib/esm/actions/index.d.ts +1 -0
- package/lib/esm/actions/index.js +1 -0
- package/lib/esm/actions/index.js.map +1 -1
- package/lib/esm/actions/keyValueStore/KeyValueStoreActionType.d.ts +2 -1
- package/lib/esm/actions/keyValueStore/KeyValueStoreActionType.js +1 -0
- package/lib/esm/actions/keyValueStore/KeyValueStoreActionType.js.map +1 -1
- package/lib/esm/actions/keyValueStore/KeyValueStoreScanAllScopesActionRequester.d.ts +32 -0
- package/lib/esm/actions/keyValueStore/KeyValueStoreScanAllScopesActionRequester.js +43 -0
- package/lib/esm/actions/keyValueStore/KeyValueStoreScanAllScopesActionRequester.js.map +1 -0
- package/lib/esm/actions/keyValueStore/KeyValueStoreScanAllScopesActionTypes.d.ts +23 -0
- package/lib/esm/actions/keyValueStore/KeyValueStoreScanAllScopesActionTypes.js +2 -0
- package/lib/esm/actions/keyValueStore/KeyValueStoreScanAllScopesActionTypes.js.map +1 -0
- package/lib/esm/actions/keyValueStore/index.d.ts +2 -0
- package/lib/esm/actions/keyValueStore/index.js +2 -0
- package/lib/esm/actions/keyValueStore/index.js.map +1 -1
- package/lib/esm/actions/keyValueStore/types/KvsQueryOperation.d.ts +2 -2
- package/lib/esm/actions/keyValueStore/types/KvsQueryOperation.js.map +1 -1
- package/lib/esm/config/QPQConfig.d.ts +1 -0
- package/lib/esm/config/QPQConfig.js +1 -0
- package/lib/esm/config/QPQConfig.js.map +1 -1
- package/lib/esm/config/settings/cryptoKey.d.ts +9 -0
- package/lib/esm/config/settings/cryptoKey.js +9 -0
- package/lib/esm/config/settings/cryptoKey.js.map +1 -0
- package/lib/esm/config/settings/index.d.ts +1 -0
- package/lib/esm/config/settings/index.js +1 -0
- package/lib/esm/config/settings/index.js.map +1 -1
- package/lib/esm/config/settings/keyValueStore.d.ts +38 -1
- package/lib/esm/config/settings/keyValueStore.js +1 -0
- package/lib/esm/config/settings/keyValueStore.js.map +1 -1
- package/lib/esm/logic/scope/scopedKvsValue.d.ts +4 -0
- package/lib/esm/logic/scope/scopedKvsValue.js +17 -0
- package/lib/esm/logic/scope/scopedKvsValue.js.map +1 -1
- package/lib/esm/qpqCoreUtils.d.ts +4 -1
- package/lib/esm/qpqCoreUtils.js +16 -0
- package/lib/esm/qpqCoreUtils.js.map +1 -1
- package/lib/esm/qpqCoreUtilsLib.d.ts +3 -0
- package/lib/esm/types/KvsStreamEvent.d.ts +14 -0
- package/lib/esm/types/KvsStreamEvent.js +13 -0
- package/lib/esm/types/KvsStreamEvent.js.map +1 -0
- package/lib/esm/types/StorySession.d.ts +1 -0
- package/lib/esm/types/StorySession.js +1 -0
- package/lib/esm/types/StorySession.js.map +1 -1
- package/lib/esm/types/index.d.ts +1 -0
- package/lib/esm/types/index.js +1 -0
- package/lib/esm/types/index.js.map +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CryptoActionType = void 0;
|
|
4
|
+
var CryptoActionType;
|
|
5
|
+
(function (CryptoActionType) {
|
|
6
|
+
CryptoActionType["Encrypt"] = "@quidproquo-core/Crypto/Encrypt";
|
|
7
|
+
CryptoActionType["Decrypt"] = "@quidproquo-core/Crypto/Decrypt";
|
|
8
|
+
})(CryptoActionType || (exports.CryptoActionType = CryptoActionType = {}));
|
|
9
|
+
//# sourceMappingURL=CryptoActionType.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CryptoActionType.js","sourceRoot":"","sources":["../../../../src/actions/crypto/CryptoActionType.ts"],"names":[],"mappings":";;;AAAA,IAAY,gBAGX;AAHD,WAAY,gBAAgB;IAC1B,+DAA2C,CAAA;IAC3C,+DAA2C,CAAA;AAC7C,CAAC,EAHW,gBAAgB,gCAAhB,gBAAgB,QAG3B","sourcesContent":["export enum CryptoActionType {\n Encrypt = '@quidproquo-core/Crypto/Encrypt',\n Decrypt = '@quidproquo-core/Crypto/Decrypt',\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type CryptoContext = Record<string, string>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CryptoContext.js","sourceRoot":"","sources":["../../../../src/actions/crypto/CryptoContext.ts"],"names":[],"mappings":"","sourcesContent":["// Opaque additional-authenticated-data for crypto operations: the same pairs\n// must be supplied at encrypt and decrypt or decryption fails. Values are NOT\n// encrypted and NOT secret (they appear in provider audit logs in the clear).\nexport type CryptoContext = Record<string, string>;\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { CryptoContext } from './CryptoContext';
|
|
2
|
+
import { CryptoDecryptActionRequester } from './CryptoDecryptActionTypes';
|
|
3
|
+
export declare const CryptoDecryptErrorTypeEnum: {
|
|
4
|
+
Throttling: string;
|
|
5
|
+
KeyNotConfigured: string;
|
|
6
|
+
ContextMismatch: string;
|
|
7
|
+
MalformedCiphertext: string;
|
|
8
|
+
KeyUnavailable: string;
|
|
9
|
+
};
|
|
10
|
+
export declare function askCryptoDecrypt(keyName: string, ciphertext: string, context?: CryptoContext): CryptoDecryptActionRequester;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CryptoDecryptErrorTypeEnum = void 0;
|
|
4
|
+
exports.askCryptoDecrypt = askCryptoDecrypt;
|
|
5
|
+
const types_1 = require("../../types");
|
|
6
|
+
const CryptoActionType_1 = require("./CryptoActionType");
|
|
7
|
+
exports.CryptoDecryptErrorTypeEnum = (0, types_1.createErrorEnumForAction)(CryptoActionType_1.CryptoActionType.Decrypt, [
|
|
8
|
+
'KeyNotConfigured', // no defineCryptoKey for keyName in the service config
|
|
9
|
+
'ContextMismatch', // supplied context differs from the encrypt-time context; probable scoping bug, do not retry
|
|
10
|
+
'MalformedCiphertext', // ciphertext is corrupt, truncated, or not a qpq crypto blob
|
|
11
|
+
'KeyUnavailable', // key disabled, deleted, or access denied
|
|
12
|
+
'Throttling', // request rate exceeded
|
|
13
|
+
]);
|
|
14
|
+
function* askCryptoDecrypt(keyName, ciphertext, context) {
|
|
15
|
+
return yield { type: CryptoActionType_1.CryptoActionType.Decrypt, payload: { keyName, ciphertext, context } };
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=CryptoDecryptActionRequester.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CryptoDecryptActionRequester.js","sourceRoot":"","sources":["../../../../src/actions/crypto/CryptoDecryptActionRequester.ts"],"names":[],"mappings":";;;AAaA,4CAEC;AAfD,uCAAuD;AACvD,yDAAsD;AAIzC,QAAA,0BAA0B,GAAG,IAAA,gCAAwB,EAAC,mCAAgB,CAAC,OAAO,EAAE;IAC3F,kBAAkB,EAAE,uDAAuD;IAC3E,iBAAiB,EAAE,6FAA6F;IAChH,qBAAqB,EAAE,6DAA6D;IACpF,gBAAgB,EAAE,0CAA0C;IAC5D,YAAY,EAAE,wBAAwB;CACvC,CAAC,CAAC;AAEH,QAAe,CAAC,CAAC,gBAAgB,CAAC,OAAe,EAAE,UAAkB,EAAE,OAAuB;IAC5F,OAAO,MAAM,EAAE,IAAI,EAAE,mCAAgB,CAAC,OAAO,EAAE,OAAO,EAAE,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,CAAC;AAC7F,CAAC","sourcesContent":["import { createErrorEnumForAction } from '../../types';\nimport { CryptoActionType } from './CryptoActionType';\nimport { CryptoContext } from './CryptoContext';\nimport { CryptoDecryptActionRequester } from './CryptoDecryptActionTypes';\n\nexport const CryptoDecryptErrorTypeEnum = createErrorEnumForAction(CryptoActionType.Decrypt, [\n 'KeyNotConfigured', // no defineCryptoKey for keyName in the service config\n 'ContextMismatch', // supplied context differs from the encrypt-time context; probable scoping bug, do not retry\n 'MalformedCiphertext', // ciphertext is corrupt, truncated, or not a qpq crypto blob\n 'KeyUnavailable', // key disabled, deleted, or access denied\n 'Throttling', // request rate exceeded\n]);\n\nexport function* askCryptoDecrypt(keyName: string, ciphertext: string, context?: CryptoContext): CryptoDecryptActionRequester {\n return yield { type: CryptoActionType.Decrypt, payload: { keyName, ciphertext, context } };\n}\n"]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Action, ActionProcessor, ActionRequester } from '../../types/Action';
|
|
2
|
+
import { CryptoActionType } from './CryptoActionType';
|
|
3
|
+
import { CryptoContext } from './CryptoContext';
|
|
4
|
+
export interface CryptoDecryptActionPayload {
|
|
5
|
+
keyName: string;
|
|
6
|
+
ciphertext: string;
|
|
7
|
+
context?: CryptoContext;
|
|
8
|
+
}
|
|
9
|
+
export interface CryptoDecryptAction extends Action<CryptoDecryptActionPayload> {
|
|
10
|
+
type: CryptoActionType.Decrypt;
|
|
11
|
+
payload: CryptoDecryptActionPayload;
|
|
12
|
+
}
|
|
13
|
+
export type CryptoDecryptActionProcessor = ActionProcessor<CryptoDecryptAction, string>;
|
|
14
|
+
export type CryptoDecryptActionRequester = ActionRequester<CryptoDecryptAction, string>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CryptoDecryptActionTypes.js","sourceRoot":"","sources":["../../../../src/actions/crypto/CryptoDecryptActionTypes.ts"],"names":[],"mappings":"","sourcesContent":["import { Action, ActionProcessor, ActionRequester } from '../../types/Action';\nimport { CryptoActionType } from './CryptoActionType';\nimport { CryptoContext } from './CryptoContext';\n\n// Payload\nexport interface CryptoDecryptActionPayload {\n keyName: string;\n ciphertext: string;\n context?: CryptoContext;\n}\n\n// Action\nexport interface CryptoDecryptAction extends Action<CryptoDecryptActionPayload> {\n type: CryptoActionType.Decrypt;\n payload: CryptoDecryptActionPayload;\n}\n\n// Function Types\nexport type CryptoDecryptActionProcessor = ActionProcessor<CryptoDecryptAction, string>;\nexport type CryptoDecryptActionRequester = ActionRequester<CryptoDecryptAction, string>;\n"]}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { CryptoContext } from './CryptoContext';
|
|
2
|
+
import { CryptoEncryptActionRequester } from './CryptoEncryptActionTypes';
|
|
3
|
+
export declare const CryptoEncryptErrorTypeEnum: {
|
|
4
|
+
Throttling: string;
|
|
5
|
+
KeyNotConfigured: string;
|
|
6
|
+
KeyUnavailable: string;
|
|
7
|
+
};
|
|
8
|
+
export declare function askCryptoEncrypt(keyName: string, plaintext: string, context?: CryptoContext): CryptoEncryptActionRequester;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CryptoEncryptErrorTypeEnum = void 0;
|
|
4
|
+
exports.askCryptoEncrypt = askCryptoEncrypt;
|
|
5
|
+
const types_1 = require("../../types");
|
|
6
|
+
const CryptoActionType_1 = require("./CryptoActionType");
|
|
7
|
+
exports.CryptoEncryptErrorTypeEnum = (0, types_1.createErrorEnumForAction)(CryptoActionType_1.CryptoActionType.Encrypt, [
|
|
8
|
+
'KeyNotConfigured', // no defineCryptoKey for keyName in the service config
|
|
9
|
+
'KeyUnavailable', // key disabled, deleted, or access denied
|
|
10
|
+
'Throttling', // request rate exceeded
|
|
11
|
+
]);
|
|
12
|
+
function* askCryptoEncrypt(keyName, plaintext, context) {
|
|
13
|
+
return yield { type: CryptoActionType_1.CryptoActionType.Encrypt, payload: { keyName, plaintext, context } };
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=CryptoEncryptActionRequester.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CryptoEncryptActionRequester.js","sourceRoot":"","sources":["../../../../src/actions/crypto/CryptoEncryptActionRequester.ts"],"names":[],"mappings":";;;AAWA,4CAEC;AAbD,uCAAuD;AACvD,yDAAsD;AAIzC,QAAA,0BAA0B,GAAG,IAAA,gCAAwB,EAAC,mCAAgB,CAAC,OAAO,EAAE;IAC3F,kBAAkB,EAAE,uDAAuD;IAC3E,gBAAgB,EAAE,0CAA0C;IAC5D,YAAY,EAAE,wBAAwB;CACvC,CAAC,CAAC;AAEH,QAAe,CAAC,CAAC,gBAAgB,CAAC,OAAe,EAAE,SAAiB,EAAE,OAAuB;IAC3F,OAAO,MAAM,EAAE,IAAI,EAAE,mCAAgB,CAAC,OAAO,EAAE,OAAO,EAAE,EAAE,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,CAAC;AAC5F,CAAC","sourcesContent":["import { createErrorEnumForAction } from '../../types';\nimport { CryptoActionType } from './CryptoActionType';\nimport { CryptoContext } from './CryptoContext';\nimport { CryptoEncryptActionRequester } from './CryptoEncryptActionTypes';\n\nexport const CryptoEncryptErrorTypeEnum = createErrorEnumForAction(CryptoActionType.Encrypt, [\n 'KeyNotConfigured', // no defineCryptoKey for keyName in the service config\n 'KeyUnavailable', // key disabled, deleted, or access denied\n 'Throttling', // request rate exceeded\n]);\n\nexport function* askCryptoEncrypt(keyName: string, plaintext: string, context?: CryptoContext): CryptoEncryptActionRequester {\n return yield { type: CryptoActionType.Encrypt, payload: { keyName, plaintext, context } };\n}\n"]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Action, ActionProcessor, ActionRequester } from '../../types/Action';
|
|
2
|
+
import { CryptoActionType } from './CryptoActionType';
|
|
3
|
+
import { CryptoContext } from './CryptoContext';
|
|
4
|
+
export interface CryptoEncryptActionPayload {
|
|
5
|
+
keyName: string;
|
|
6
|
+
plaintext: string;
|
|
7
|
+
context?: CryptoContext;
|
|
8
|
+
}
|
|
9
|
+
export interface CryptoEncryptAction extends Action<CryptoEncryptActionPayload> {
|
|
10
|
+
type: CryptoActionType.Encrypt;
|
|
11
|
+
payload: CryptoEncryptActionPayload;
|
|
12
|
+
}
|
|
13
|
+
export type CryptoEncryptActionProcessor = ActionProcessor<CryptoEncryptAction, string>;
|
|
14
|
+
export type CryptoEncryptActionRequester = ActionRequester<CryptoEncryptAction, string>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CryptoEncryptActionTypes.js","sourceRoot":"","sources":["../../../../src/actions/crypto/CryptoEncryptActionTypes.ts"],"names":[],"mappings":"","sourcesContent":["import { Action, ActionProcessor, ActionRequester } from '../../types/Action';\nimport { CryptoActionType } from './CryptoActionType';\nimport { CryptoContext } from './CryptoContext';\n\n// Payload\nexport interface CryptoEncryptActionPayload {\n keyName: string;\n plaintext: string;\n context?: CryptoContext;\n}\n\n// Action\nexport interface CryptoEncryptAction extends Action<CryptoEncryptActionPayload> {\n type: CryptoActionType.Encrypt;\n payload: CryptoEncryptActionPayload;\n}\n\n// Function Types\nexport type CryptoEncryptActionProcessor = ActionProcessor<CryptoEncryptAction, string>;\nexport type CryptoEncryptActionRequester = ActionRequester<CryptoEncryptAction, string>;\n"]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./CryptoActionType"), exports);
|
|
18
|
+
__exportStar(require("./CryptoContext"), exports);
|
|
19
|
+
__exportStar(require("./CryptoDecryptActionRequester"), exports);
|
|
20
|
+
__exportStar(require("./CryptoDecryptActionTypes"), exports);
|
|
21
|
+
__exportStar(require("./CryptoEncryptActionRequester"), exports);
|
|
22
|
+
__exportStar(require("./CryptoEncryptActionTypes"), exports);
|
|
23
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/actions/crypto/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,kDAAgC;AAChC,iEAA+C;AAC/C,6DAA2C;AAC3C,iEAA+C;AAC/C,6DAA2C","sourcesContent":["export * from './CryptoActionType';\nexport * from './CryptoContext';\nexport * from './CryptoDecryptActionRequester';\nexport * from './CryptoDecryptActionTypes';\nexport * from './CryptoEncryptActionRequester';\nexport * from './CryptoEncryptActionTypes';\n"]}
|
|
@@ -18,6 +18,7 @@ __exportStar(require("./ai"), exports);
|
|
|
18
18
|
__exportStar(require("./claudeAi"), exports);
|
|
19
19
|
__exportStar(require("./config"), exports);
|
|
20
20
|
__exportStar(require("./context"), exports);
|
|
21
|
+
__exportStar(require("./crypto"), exports);
|
|
21
22
|
__exportStar(require("./date"), exports);
|
|
22
23
|
__exportStar(require("./error"), exports);
|
|
23
24
|
__exportStar(require("./event"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/actions/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uCAAqB;AACrB,6CAA2B;AAC3B,2CAAyB;AACzB,4CAA0B;AAC1B,yCAAuB;AACvB,0CAAwB;AACxB,0CAAwB;AACxB,6CAA2B;AAC3B,yCAAuB;AACvB,kDAAgC;AAChC,yCAAuB;AACvB,mDAAiC;AACjC,kDAAgC;AAChC,wCAAsB;AACtB,yCAAuB;AACvB,2CAAyB;AACzB,4CAA0B;AAC1B,6CAA2B;AAC3B,0CAAwB;AACxB,0CAAwB;AACxB,2CAAyB;AACzB,2CAAyB;AACzB,kDAAgC","sourcesContent":["export * from './ai';\nexport * from './claudeAi';\nexport * from './config';\nexport * from './context';\nexport * from './date';\nexport * from './error';\nexport * from './event';\nexport * from './eventBus';\nexport * from './file';\nexport * from './graphDatabase';\nexport * from './guid';\nexport * from './inlineFunction';\nexport * from './keyValueStore';\nexport * from './log';\nexport * from './math';\nexport * from './metric';\nexport * from './network';\nexport * from './platform';\nexport * from './queue';\nexport * from './state';\nexport * from './stream';\nexport * from './system';\nexport * from './userDirectory';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/actions/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uCAAqB;AACrB,6CAA2B;AAC3B,2CAAyB;AACzB,4CAA0B;AAC1B,2CAAyB;AACzB,yCAAuB;AACvB,0CAAwB;AACxB,0CAAwB;AACxB,6CAA2B;AAC3B,yCAAuB;AACvB,kDAAgC;AAChC,yCAAuB;AACvB,mDAAiC;AACjC,kDAAgC;AAChC,wCAAsB;AACtB,yCAAuB;AACvB,2CAAyB;AACzB,4CAA0B;AAC1B,6CAA2B;AAC3B,0CAAwB;AACxB,0CAAwB;AACxB,2CAAyB;AACzB,2CAAyB;AACzB,kDAAgC","sourcesContent":["export * from './ai';\nexport * from './claudeAi';\nexport * from './config';\nexport * from './context';\nexport * from './crypto';\nexport * from './date';\nexport * from './error';\nexport * from './event';\nexport * from './eventBus';\nexport * from './file';\nexport * from './graphDatabase';\nexport * from './guid';\nexport * from './inlineFunction';\nexport * from './keyValueStore';\nexport * from './log';\nexport * from './math';\nexport * from './metric';\nexport * from './network';\nexport * from './platform';\nexport * from './queue';\nexport * from './state';\nexport * from './stream';\nexport * from './system';\nexport * from './userDirectory';\n"]}
|
|
@@ -5,5 +5,6 @@ export declare enum KeyValueStoreActionType {
|
|
|
5
5
|
Delete = "@quidproquo-core/KeyValueStore/Delete",
|
|
6
6
|
Update = "@quidproquo-core/KeyValueStore/Update",
|
|
7
7
|
Query = "@quidproquo-core/KeyValueStore/Query",
|
|
8
|
-
Scan = "@quidproquo-core/KeyValueStore/Scan"
|
|
8
|
+
Scan = "@quidproquo-core/KeyValueStore/Scan",
|
|
9
|
+
ScanAllScopes = "@quidproquo-core/KeyValueStore/ScanAllScopes"
|
|
9
10
|
}
|
|
@@ -10,5 +10,6 @@ var KeyValueStoreActionType;
|
|
|
10
10
|
KeyValueStoreActionType["Update"] = "@quidproquo-core/KeyValueStore/Update";
|
|
11
11
|
KeyValueStoreActionType["Query"] = "@quidproquo-core/KeyValueStore/Query";
|
|
12
12
|
KeyValueStoreActionType["Scan"] = "@quidproquo-core/KeyValueStore/Scan";
|
|
13
|
+
KeyValueStoreActionType["ScanAllScopes"] = "@quidproquo-core/KeyValueStore/ScanAllScopes";
|
|
13
14
|
})(KeyValueStoreActionType || (exports.KeyValueStoreActionType = KeyValueStoreActionType = {}));
|
|
14
15
|
//# sourceMappingURL=KeyValueStoreActionType.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KeyValueStoreActionType.js","sourceRoot":"","sources":["../../../../src/actions/keyValueStore/KeyValueStoreActionType.ts"],"names":[],"mappings":";;;AAAA,IAAY,
|
|
1
|
+
{"version":3,"file":"KeyValueStoreActionType.js","sourceRoot":"","sources":["../../../../src/actions/keyValueStore/KeyValueStoreActionType.ts"],"names":[],"mappings":";;;AAAA,IAAY,uBASX;AATD,WAAY,uBAAuB;IACjC,2EAAgD,CAAA;IAChD,qEAA0C,CAAA;IAC1C,2EAAgD,CAAA;IAChD,2EAAgD,CAAA;IAChD,2EAAgD,CAAA;IAChD,yEAA8C,CAAA;IAC9C,uEAA4C,CAAA;IAC5C,yFAA8D,CAAA;AAChE,CAAC,EATW,uBAAuB,uCAAvB,uBAAuB,QASlC","sourcesContent":["export enum KeyValueStoreActionType {\n Upsert = '@quidproquo-core/KeyValueStore/Upsert',\n Get = '@quidproquo-core/KeyValueStore/Get',\n GetAll = '@quidproquo-core/KeyValueStore/GetAll',\n Delete = '@quidproquo-core/KeyValueStore/Delete',\n Update = '@quidproquo-core/KeyValueStore/Update',\n Query = '@quidproquo-core/KeyValueStore/Query',\n Scan = '@quidproquo-core/KeyValueStore/Scan',\n ScanAllScopes = '@quidproquo-core/KeyValueStore/ScanAllScopes',\n}\n"]}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { KeyValueStoreScanAllScopesActionRequester, KeyValueStoreScanAllScopesOptions } from './KeyValueStoreScanAllScopesActionTypes';
|
|
2
|
+
import { KvsQueryOperation } from './types';
|
|
3
|
+
export declare const KeyValueStoreScanAllScopesErrorTypeEnum: {
|
|
4
|
+
ResourceNotFound: string;
|
|
5
|
+
ServiceUnavailable: string;
|
|
6
|
+
StoreNotFound: string;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Read EVERY row in a store, across every scope, each paired with the scope it lives under.
|
|
10
|
+
*
|
|
11
|
+
* This deliberately crosses the tenant boundary that the rest of the KVS layer works hard to
|
|
12
|
+
* hold. An ordinary unscoped Scan cannot see scoped rows at all: the translator ANDs on a
|
|
13
|
+
* predicate that excludes them, precisely so one tenant's request can never read another's.
|
|
14
|
+
* That is the right default and nothing about it changes.
|
|
15
|
+
*
|
|
16
|
+
* The exception exists for MIGRATIONS, where the job is "rewrite every row" and any row you
|
|
17
|
+
* cannot see is data you silently leave behind. The alternative is asking the app to
|
|
18
|
+
* enumerate its own tenants and loop, which fails quietly the moment that list is incomplete.
|
|
19
|
+
*
|
|
20
|
+
* So: reach for this only from a migration or an equivalent whole-store operation, never on a
|
|
21
|
+
* request path. Nothing in the framework calls it, and a caller with a user's request in hand
|
|
22
|
+
* has no business using it — scope is what keeps tenants apart, and this steps over it.
|
|
23
|
+
*
|
|
24
|
+
* The scope comes back per row rather than being discarded, so a caller can write each row
|
|
25
|
+
* back where it came from.
|
|
26
|
+
*
|
|
27
|
+
* DRAIN THE PAGE KEY: loop until `nextPageKey` comes back undefined. Every backend pages,
|
|
28
|
+
* including the local one, deliberately so — a backend that returned everything in one call
|
|
29
|
+
* would let a caller stop after the first page, be right locally, and silently skip most of
|
|
30
|
+
* the data deployed. A local run has to be able to prove the loop.
|
|
31
|
+
*/
|
|
32
|
+
export declare function askKeyValueStoreScanAllScopes<KvsItem>(keyValueStoreName: string, filterCondition?: KvsQueryOperation, nextPageKey?: string, options?: KeyValueStoreScanAllScopesOptions): KeyValueStoreScanAllScopesActionRequester<KvsItem>;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.KeyValueStoreScanAllScopesErrorTypeEnum = void 0;
|
|
4
|
+
exports.askKeyValueStoreScanAllScopes = askKeyValueStoreScanAllScopes;
|
|
5
|
+
const types_1 = require("../../types");
|
|
6
|
+
const KeyValueStoreActionType_1 = require("./KeyValueStoreActionType");
|
|
7
|
+
exports.KeyValueStoreScanAllScopesErrorTypeEnum = (0, types_1.createErrorEnumForAction)(KeyValueStoreActionType_1.KeyValueStoreActionType.ScanAllScopes, [
|
|
8
|
+
'ServiceUnavailable', // DynamoDB internal error / throttling
|
|
9
|
+
'ResourceNotFound', // the underlying table does not exist
|
|
10
|
+
'StoreNotFound', // the store is not declared in the qpq config (misconfiguration)
|
|
11
|
+
]);
|
|
12
|
+
/**
|
|
13
|
+
* Read EVERY row in a store, across every scope, each paired with the scope it lives under.
|
|
14
|
+
*
|
|
15
|
+
* This deliberately crosses the tenant boundary that the rest of the KVS layer works hard to
|
|
16
|
+
* hold. An ordinary unscoped Scan cannot see scoped rows at all: the translator ANDs on a
|
|
17
|
+
* predicate that excludes them, precisely so one tenant's request can never read another's.
|
|
18
|
+
* That is the right default and nothing about it changes.
|
|
19
|
+
*
|
|
20
|
+
* The exception exists for MIGRATIONS, where the job is "rewrite every row" and any row you
|
|
21
|
+
* cannot see is data you silently leave behind. The alternative is asking the app to
|
|
22
|
+
* enumerate its own tenants and loop, which fails quietly the moment that list is incomplete.
|
|
23
|
+
*
|
|
24
|
+
* So: reach for this only from a migration or an equivalent whole-store operation, never on a
|
|
25
|
+
* request path. Nothing in the framework calls it, and a caller with a user's request in hand
|
|
26
|
+
* has no business using it — scope is what keeps tenants apart, and this steps over it.
|
|
27
|
+
*
|
|
28
|
+
* The scope comes back per row rather than being discarded, so a caller can write each row
|
|
29
|
+
* back where it came from.
|
|
30
|
+
*
|
|
31
|
+
* DRAIN THE PAGE KEY: loop until `nextPageKey` comes back undefined. Every backend pages,
|
|
32
|
+
* including the local one, deliberately so — a backend that returned everything in one call
|
|
33
|
+
* would let a caller stop after the first page, be right locally, and silently skip most of
|
|
34
|
+
* the data deployed. A local run has to be able to prove the loop.
|
|
35
|
+
*/
|
|
36
|
+
function* askKeyValueStoreScanAllScopes(keyValueStoreName, filterCondition, nextPageKey, options) {
|
|
37
|
+
return yield {
|
|
38
|
+
type: KeyValueStoreActionType_1.KeyValueStoreActionType.ScanAllScopes,
|
|
39
|
+
payload: {
|
|
40
|
+
keyValueStoreName,
|
|
41
|
+
filterCondition,
|
|
42
|
+
nextPageKey,
|
|
43
|
+
options,
|
|
44
|
+
},
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
//# sourceMappingURL=KeyValueStoreScanAllScopesActionRequester.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KeyValueStoreScanAllScopesActionRequester.js","sourceRoot":"","sources":["../../../../src/actions/keyValueStore/KeyValueStoreScanAllScopesActionRequester.ts"],"names":[],"mappings":";;;AAmCA,sEAkBC;AArDD,uCAAuD;AACvD,uEAAoE;AAIvD,QAAA,uCAAuC,GAAG,IAAA,gCAAwB,EAAC,iDAAuB,CAAC,aAAa,EAAE;IACrH,oBAAoB,EAAE,uCAAuC;IAC7D,kBAAkB,EAAE,sCAAsC;IAC1D,eAAe,EAAE,iEAAiE;CACnF,CAAC,CAAC;AAEH;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,QAAe,CAAC,CAAC,6BAA6B,CAC5C,iBAAyB,EACzB,eAAmC,EACnC,WAAoB,EACpB,OAA2C;IAE3C,OAAO,MAAM;QACX,IAAI,EAAE,iDAAuB,CAAC,aAAa;QAC3C,OAAO,EAAE;YACP,iBAAiB;YAEjB,eAAe;YAEf,WAAW;YAEX,OAAO;SACR;KACF,CAAC;AACJ,CAAC","sourcesContent":["import { createErrorEnumForAction } from '../../types';\nimport { KeyValueStoreActionType } from './KeyValueStoreActionType';\nimport { KeyValueStoreScanAllScopesActionRequester, KeyValueStoreScanAllScopesOptions } from './KeyValueStoreScanAllScopesActionTypes';\nimport { KvsQueryOperation } from './types';\n\nexport const KeyValueStoreScanAllScopesErrorTypeEnum = createErrorEnumForAction(KeyValueStoreActionType.ScanAllScopes, [\n 'ServiceUnavailable', // DynamoDB internal error / throttling\n 'ResourceNotFound', // the underlying table does not exist\n 'StoreNotFound', // the store is not declared in the qpq config (misconfiguration)\n]);\n\n/**\n * Read EVERY row in a store, across every scope, each paired with the scope it lives under.\n *\n * This deliberately crosses the tenant boundary that the rest of the KVS layer works hard to\n * hold. An ordinary unscoped Scan cannot see scoped rows at all: the translator ANDs on a\n * predicate that excludes them, precisely so one tenant's request can never read another's.\n * That is the right default and nothing about it changes.\n *\n * The exception exists for MIGRATIONS, where the job is \"rewrite every row\" and any row you\n * cannot see is data you silently leave behind. The alternative is asking the app to\n * enumerate its own tenants and loop, which fails quietly the moment that list is incomplete.\n *\n * So: reach for this only from a migration or an equivalent whole-store operation, never on a\n * request path. Nothing in the framework calls it, and a caller with a user's request in hand\n * has no business using it — scope is what keeps tenants apart, and this steps over it.\n *\n * The scope comes back per row rather than being discarded, so a caller can write each row\n * back where it came from.\n *\n * DRAIN THE PAGE KEY: loop until `nextPageKey` comes back undefined. Every backend pages,\n * including the local one, deliberately so — a backend that returned everything in one call\n * would let a caller stop after the first page, be right locally, and silently skip most of\n * the data deployed. A local run has to be able to prove the loop.\n */\nexport function* askKeyValueStoreScanAllScopes<KvsItem>(\n keyValueStoreName: string,\n filterCondition?: KvsQueryOperation,\n nextPageKey?: string,\n options?: KeyValueStoreScanAllScopesOptions,\n): KeyValueStoreScanAllScopesActionRequester<KvsItem> {\n return yield {\n type: KeyValueStoreActionType.ScanAllScopes,\n payload: {\n keyValueStoreName,\n\n filterCondition,\n\n nextPageKey,\n\n options,\n },\n };\n}\n"]}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { QpqPagedData } from '../../types';
|
|
2
|
+
import { Action, ActionProcessor, ActionRequester } from '../../types/Action';
|
|
3
|
+
import { KeyValueStoreActionType } from './KeyValueStoreActionType';
|
|
4
|
+
import { KvsQueryOperation } from './types';
|
|
5
|
+
export type KvsScopedItem<KvsItem> = {
|
|
6
|
+
scope?: string;
|
|
7
|
+
item: KvsItem;
|
|
8
|
+
};
|
|
9
|
+
export interface KeyValueStoreScanAllScopesOptions {
|
|
10
|
+
limit?: number;
|
|
11
|
+
}
|
|
12
|
+
export interface KeyValueStoreScanAllScopesActionPayload {
|
|
13
|
+
keyValueStoreName: string;
|
|
14
|
+
filterCondition?: KvsQueryOperation;
|
|
15
|
+
nextPageKey?: string;
|
|
16
|
+
options?: KeyValueStoreScanAllScopesOptions;
|
|
17
|
+
}
|
|
18
|
+
export interface KeyValueStoreScanAllScopesAction extends Action<KeyValueStoreScanAllScopesActionPayload> {
|
|
19
|
+
type: KeyValueStoreActionType.ScanAllScopes;
|
|
20
|
+
payload: KeyValueStoreScanAllScopesActionPayload;
|
|
21
|
+
}
|
|
22
|
+
export type KeyValueStoreScanAllScopesActionProcessor<KvsItem> = ActionProcessor<KeyValueStoreScanAllScopesAction, QpqPagedData<KvsScopedItem<KvsItem>>>;
|
|
23
|
+
export type KeyValueStoreScanAllScopesActionRequester<KvsItem> = ActionRequester<KeyValueStoreScanAllScopesAction, QpqPagedData<KvsScopedItem<KvsItem>>>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KeyValueStoreScanAllScopesActionTypes.js","sourceRoot":"","sources":["../../../../src/actions/keyValueStore/KeyValueStoreScanAllScopesActionTypes.ts"],"names":[],"mappings":"","sourcesContent":["import { QpqPagedData } from '../../types';\nimport { Action, ActionProcessor, ActionRequester } from '../../types/Action';\nimport { KeyValueStoreActionType } from './KeyValueStoreActionType';\nimport { KvsQueryOperation } from './types';\n\n// One row and the scope it lives under. `scope` is absent for an unscoped row.\n//\n// The scope is reported rather than dropped BECAUSE this crosses scopes: a caller that reads\n// every tenant's rows in one pass has to know which tenant each belongs to, or anything it\n// writes back lands in the wrong partition. Handing back bare items would make silent\n// cross-tenant corruption the easy mistake.\nexport type KvsScopedItem<KvsItem> = {\n scope?: string;\n item: KvsItem;\n};\n\n// Options Type\nexport interface KeyValueStoreScanAllScopesOptions {\n limit?: number;\n}\n\n// Payload\nexport interface KeyValueStoreScanAllScopesActionPayload {\n keyValueStoreName: string;\n\n filterCondition?: KvsQueryOperation;\n\n nextPageKey?: string;\n\n options?: KeyValueStoreScanAllScopesOptions;\n}\n\n// Action\nexport interface KeyValueStoreScanAllScopesAction extends Action<KeyValueStoreScanAllScopesActionPayload> {\n type: KeyValueStoreActionType.ScanAllScopes;\n payload: KeyValueStoreScanAllScopesActionPayload;\n}\n\n// Function Types\nexport type KeyValueStoreScanAllScopesActionProcessor<KvsItem> = ActionProcessor<\n KeyValueStoreScanAllScopesAction,\n QpqPagedData<KvsScopedItem<KvsItem>>\n>;\nexport type KeyValueStoreScanAllScopesActionRequester<KvsItem> = ActionRequester<\n KeyValueStoreScanAllScopesAction,\n QpqPagedData<KvsScopedItem<KvsItem>>\n>;\n"]}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
export * from './KeyValueStoreScanAllScopesActionTypes';
|
|
2
|
+
export * from './KeyValueStoreScanAllScopesActionRequester';
|
|
1
3
|
export * from './KeyValueStoreActionType';
|
|
2
4
|
export * from './KeyValueStoreDeleteActionRequester';
|
|
3
5
|
export * from './KeyValueStoreDeleteActionTypes';
|
|
@@ -14,6 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./KeyValueStoreScanAllScopesActionTypes"), exports);
|
|
18
|
+
__exportStar(require("./KeyValueStoreScanAllScopesActionRequester"), exports);
|
|
17
19
|
__exportStar(require("./KeyValueStoreActionType"), exports);
|
|
18
20
|
__exportStar(require("./KeyValueStoreDeleteActionRequester"), exports);
|
|
19
21
|
__exportStar(require("./KeyValueStoreDeleteActionTypes"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/actions/keyValueStore/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4DAA0C;AAC1C,uEAAqD;AACrD,mEAAiD;AACjD,oEAAkD;AAClD,gEAA8C;AAC9C,uEAAqD;AACrD,mEAAiD;AACjD,sEAAoD;AACpD,kEAAgD;AAChD,qEAAmD;AACnD,iEAA+C;AAC/C,uEAAqD;AACrD,mEAAiD;AACjD,uEAAqD;AACrD,mEAAiD;AACjD,0CAAwB;AACxB,0CAAwB","sourcesContent":["export * from './KeyValueStoreActionType';\nexport * from './KeyValueStoreDeleteActionRequester';\nexport * from './KeyValueStoreDeleteActionTypes';\nexport * from './KeyValueStoreGetActionRequester';\nexport * from './KeyValueStoreGetActionTypes';\nexport * from './KeyValueStoreGetAllActionRequester';\nexport * from './KeyValueStoreGetAllActionTypes';\nexport * from './KeyValueStoreQueryActionRequester';\nexport * from './KeyValueStoreQueryActionTypes';\nexport * from './KeyValueStoreScanActionRequester';\nexport * from './KeyValueStoreScanActionTypes';\nexport * from './KeyValueStoreUpdateActionRequester';\nexport * from './KeyValueStoreUpdateActionTypes';\nexport * from './KeyValueStoreUpsertActionRequester';\nexport * from './KeyValueStoreUpsertActionTypes';\nexport * from './types';\nexport * from './utils';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/actions/keyValueStore/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0EAAwD;AACxD,8EAA4D;AAC5D,4DAA0C;AAC1C,uEAAqD;AACrD,mEAAiD;AACjD,oEAAkD;AAClD,gEAA8C;AAC9C,uEAAqD;AACrD,mEAAiD;AACjD,sEAAoD;AACpD,kEAAgD;AAChD,qEAAmD;AACnD,iEAA+C;AAC/C,uEAAqD;AACrD,mEAAiD;AACjD,uEAAqD;AACrD,mEAAiD;AACjD,0CAAwB;AACxB,0CAAwB","sourcesContent":["export * from './KeyValueStoreScanAllScopesActionTypes';\nexport * from './KeyValueStoreScanAllScopesActionRequester';\nexport * from './KeyValueStoreActionType';\nexport * from './KeyValueStoreDeleteActionRequester';\nexport * from './KeyValueStoreDeleteActionTypes';\nexport * from './KeyValueStoreGetActionRequester';\nexport * from './KeyValueStoreGetActionTypes';\nexport * from './KeyValueStoreGetAllActionRequester';\nexport * from './KeyValueStoreGetAllActionTypes';\nexport * from './KeyValueStoreQueryActionRequester';\nexport * from './KeyValueStoreQueryActionTypes';\nexport * from './KeyValueStoreScanActionRequester';\nexport * from './KeyValueStoreScanActionTypes';\nexport * from './KeyValueStoreUpdateActionRequester';\nexport * from './KeyValueStoreUpdateActionTypes';\nexport * from './KeyValueStoreUpsertActionRequester';\nexport * from './KeyValueStoreUpsertActionTypes';\nexport * from './types';\nexport * from './utils';\n"]}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { KvsLogicalOperatorType, KvsQueryOperationType } from './KvsQueryOperationType';
|
|
2
2
|
export type KvsCoreDataType = string | number;
|
|
3
3
|
export type KvsBasicDataType = KvsCoreDataType | boolean;
|
|
4
|
-
export type KvsListDataType =
|
|
4
|
+
export type KvsListDataType = KvsAdvancedDataType[];
|
|
5
5
|
export interface KvsObjectDataType {
|
|
6
|
-
[key: string]: KvsAdvancedDataType;
|
|
6
|
+
[key: string]: KvsAdvancedDataType | undefined;
|
|
7
7
|
}
|
|
8
8
|
export type KvsAdvancedDataType = KvsBasicDataType | KvsListDataType | KvsObjectDataType;
|
|
9
9
|
export type KvsQueryCondition = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KvsQueryOperation.js","sourceRoot":"","sources":["../../../../../src/actions/keyValueStore/types/KvsQueryOperation.ts"],"names":[],"mappings":"","sourcesContent":["import { KvsLogicalOperatorType, KvsQueryOperationType } from './KvsQueryOperationType';\n\nexport type KvsCoreDataType = string | number;\nexport type KvsBasicDataType = KvsCoreDataType | boolean;\nexport type KvsListDataType =
|
|
1
|
+
{"version":3,"file":"KvsQueryOperation.js","sourceRoot":"","sources":["../../../../../src/actions/keyValueStore/types/KvsQueryOperation.ts"],"names":[],"mappings":"","sourcesContent":["import { KvsLogicalOperatorType, KvsQueryOperationType } from './KvsQueryOperationType';\n\nexport type KvsCoreDataType = string | number;\nexport type KvsBasicDataType = KvsCoreDataType | boolean;\n\nexport type KvsListDataType = KvsAdvancedDataType[];\n\n// Use an interface for the recursive data type. Members may be undefined so that a\n// domain model with OPTIONAL fields can be written directly; the marshaller drops\n// undefined members, since DynamoDB has no representation for them.\nexport interface KvsObjectDataType {\n [key: string]: KvsAdvancedDataType | undefined;\n}\n\nexport type KvsAdvancedDataType = KvsBasicDataType | KvsListDataType | KvsObjectDataType;\n\n// Type for individual query conditions\nexport type KvsQueryCondition = {\n key: string;\n operation: KvsQueryOperationType;\n valueA?: KvsAdvancedDataType;\n valueB?: KvsBasicDataType;\n};\n\n// Type for logical operators\nexport type KvsLogicalOperator = {\n operation: KvsLogicalOperatorType;\n conditions: (KvsQueryCondition | KvsLogicalOperator)[];\n};\n\n// Type for the overall query operation\nexport type KvsQueryOperation = KvsQueryCondition | KvsLogicalOperator;\n"]}
|
|
@@ -17,6 +17,7 @@ export declare enum QPQCoreConfigSettingType {
|
|
|
17
17
|
userDirectory = "@quidproquo-core/config/UserDirectory",
|
|
18
18
|
keyValueStore = "@quidproquo-core/config/KeyValueStore",
|
|
19
19
|
configValue = "@quidproquo-core/config/ConfigValue",
|
|
20
|
+
cryptoKey = "@quidproquo-core/config/cryptoKey",
|
|
20
21
|
environmentSettings = "@quidproquo-core/config/EnvironmentSettings",
|
|
21
22
|
serviceSettings = "@quidproquo-core/config/ServiceSettings",
|
|
22
23
|
deployEvent = "@quidproquo-core/config/DeployEvent",
|
|
@@ -20,6 +20,7 @@ var QPQCoreConfigSettingType;
|
|
|
20
20
|
QPQCoreConfigSettingType["userDirectory"] = "@quidproquo-core/config/UserDirectory";
|
|
21
21
|
QPQCoreConfigSettingType["keyValueStore"] = "@quidproquo-core/config/KeyValueStore";
|
|
22
22
|
QPQCoreConfigSettingType["configValue"] = "@quidproquo-core/config/ConfigValue";
|
|
23
|
+
QPQCoreConfigSettingType["cryptoKey"] = "@quidproquo-core/config/cryptoKey";
|
|
23
24
|
QPQCoreConfigSettingType["environmentSettings"] = "@quidproquo-core/config/EnvironmentSettings";
|
|
24
25
|
QPQCoreConfigSettingType["serviceSettings"] = "@quidproquo-core/config/ServiceSettings";
|
|
25
26
|
QPQCoreConfigSettingType["deployEvent"] = "@quidproquo-core/config/DeployEvent";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QPQConfig.js","sourceRoot":"","sources":["../../../src/config/QPQConfig.ts"],"names":[],"mappings":";;;AAEA,IAAY,
|
|
1
|
+
{"version":3,"file":"QPQConfig.js","sourceRoot":"","sources":["../../../src/config/QPQConfig.ts"],"names":[],"mappings":";;;AAEA,IAAY,wBA6BX;AA7BD,WAAY,wBAAwB;IAClC,6DAAiC,CAAA;IACjC,uEAA2C,CAAA;IAC3C,6EAAiD,CAAA;IACjD,iFAAqD,CAAA;IACrD,yEAA6C,CAAA;IAC7C,qEAAyC,CAAA;IACzC,qEAAyC,CAAA;IACzC,2EAA+C,CAAA;IAC/C,yFAA6D,CAAA;IAC7D,iFAAqD,CAAA;IACrD,iGAAqE,CAAA;IACrE,mGAAuE,CAAA;IACvE,mEAAuC,CAAA;IACvC,yEAA6C,CAAA;IAC7C,mFAAuD,CAAA;IACvD,mFAAuD,CAAA;IACvD,+EAAmD,CAAA;IACnD,2EAA+C,CAAA;IAC/C,+FAAmE,CAAA;IACnE,uFAA2D,CAAA;IAC3D,+EAAmD,CAAA;IACnD,yEAA6C,CAAA;IAC7C,mFAAuD,CAAA;IACvD,qFAAyD,CAAA;IACzD,+EAAmD,CAAA;IACnD,qFAAyD,CAAA;IACzD,2FAA+D,CAAA;IAC/D,iGAAqE,CAAA;AACvE,CAAC,EA7BW,wBAAwB,wCAAxB,wBAAwB,QA6BnC","sourcesContent":["import { CrossModuleOwner } from '../types';\n\nexport enum QPQCoreConfigSettingType {\n ai = '@quidproquo-core/config/Ai',\n appName = '@quidproquo-core/config/AppName',\n moduleName = '@quidproquo-core/config/moduleName',\n storageDrive = '@quidproquo-core/config/storageDrive',\n schedule = '@quidproquo-core/config/schedule',\n secret = '@quidproquo-core/config/secret',\n global = '@quidproquo-core/config/global',\n parameter = '@quidproquo-core/config/parameter',\n actionProcessors = '@quidproquo-core/config/actionProcessors',\n apiBuildPath = '@quidproquo-core/config/apiBuildPath',\n backendBundleOptions = '@quidproquo-core/config/BackendBundleOptions',\n frontendBundleOptions = '@quidproquo-core/config/FrontendBundleOptions',\n queue = '@quidproquo-core/config/Queue',\n eventBus = '@quidproquo-core/config/EventBus',\n userDirectory = '@quidproquo-core/config/UserDirectory',\n keyValueStore = '@quidproquo-core/config/KeyValueStore',\n configValue = '@quidproquo-core/config/ConfigValue',\n cryptoKey = '@quidproquo-core/config/cryptoKey',\n environmentSettings = '@quidproquo-core/config/EnvironmentSettings',\n serviceSettings = '@quidproquo-core/config/ServiceSettings',\n deployEvent = '@quidproquo-core/config/DeployEvent',\n claudeAi = '@quidproquo-core/config/ClaudeAi',\n graphDatabase = '@quidproquo-core/config/GraphDatabase',\n virtualNetwork = '@quidproquo-core/config/VirtualNetwork',\n notifyError = '@quidproquo-core/config/notifyError',\n inlineFunction = '@quidproquo-core/config/InlineFunction',\n javascriptRuntime = '@quidproquo-core/config/JavascriptRuntime',\n federatedModuleStore = '@quidproquo-core/config/FederatedModuleStore',\n}\n\nexport interface QPQConfigSetting {\n configSettingType: string;\n uniqueKey: string;\n\n owner?: CrossModuleOwner;\n}\n\nexport interface QPQConfigAdvancedSettings {\n deprecated?: boolean;\n}\n\nexport type QPQConfigItem = QPQConfigSetting | QPQConfigItem[];\nexport type QPQConfig = QPQConfigItem[];\n"]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { CrossModuleOwner } from '../../types';
|
|
2
|
+
import { QPQConfigAdvancedSettings, QPQConfigSetting } from '../QPQConfig';
|
|
3
|
+
export interface QPQConfigAdvancedCryptoKeySettings extends QPQConfigAdvancedSettings {
|
|
4
|
+
owner?: CrossModuleOwner<'cryptoKeyName'>;
|
|
5
|
+
}
|
|
6
|
+
export interface CryptoKeyQPQConfigSetting extends QPQConfigSetting {
|
|
7
|
+
keyName: string;
|
|
8
|
+
}
|
|
9
|
+
export declare const defineCryptoKey: (keyName: string, options?: QPQConfigAdvancedCryptoKeySettings) => CryptoKeyQPQConfigSetting;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.defineCryptoKey = void 0;
|
|
4
|
+
const QPQConfig_1 = require("../QPQConfig");
|
|
5
|
+
const crossModuleUtils_1 = require("../utils/crossModuleUtils");
|
|
6
|
+
const defineCryptoKey = (keyName, options) => ({
|
|
7
|
+
configSettingType: QPQConfig_1.QPQCoreConfigSettingType.cryptoKey,
|
|
8
|
+
uniqueKey: keyName,
|
|
9
|
+
keyName,
|
|
10
|
+
owner: (0, crossModuleUtils_1.convertCrossModuleOwnerToGenericResourceNameOverride)(options === null || options === void 0 ? void 0 : options.owner),
|
|
11
|
+
});
|
|
12
|
+
exports.defineCryptoKey = defineCryptoKey;
|
|
13
|
+
//# sourceMappingURL=cryptoKey.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cryptoKey.js","sourceRoot":"","sources":["../../../../src/config/settings/cryptoKey.ts"],"names":[],"mappings":";;;AACA,4CAAqG;AACrG,gEAAiG;AAU1F,MAAM,eAAe,GAAG,CAAC,OAAe,EAAE,OAA4C,EAA6B,EAAE,CAAC,CAAC;IAC5H,iBAAiB,EAAE,oCAAwB,CAAC,SAAS;IACrD,SAAS,EAAE,OAAO;IAElB,OAAO;IAEP,KAAK,EAAE,IAAA,uEAAoD,EAAC,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,KAAK,CAAC;CAC5E,CAAC,CAAC;AAPU,QAAA,eAAe,mBAOzB","sourcesContent":["import { CrossModuleOwner } from '../../types';\nimport { QPQConfigAdvancedSettings, QPQConfigSetting, QPQCoreConfigSettingType } from '../QPQConfig';\nimport { convertCrossModuleOwnerToGenericResourceNameOverride } from '../utils/crossModuleUtils';\n\nexport interface QPQConfigAdvancedCryptoKeySettings extends QPQConfigAdvancedSettings {\n owner?: CrossModuleOwner<'cryptoKeyName'>;\n}\n\nexport interface CryptoKeyQPQConfigSetting extends QPQConfigSetting {\n keyName: string;\n}\n\nexport const defineCryptoKey = (keyName: string, options?: QPQConfigAdvancedCryptoKeySettings): CryptoKeyQPQConfigSetting => ({\n configSettingType: QPQCoreConfigSettingType.cryptoKey,\n uniqueKey: keyName,\n\n keyName,\n\n owner: convertCrossModuleOwnerToGenericResourceNameOverride(options?.owner),\n});\n"]}
|
|
@@ -7,6 +7,7 @@ export * from './applicationVersion';
|
|
|
7
7
|
export * from './bundleOptions';
|
|
8
8
|
export * from './claudeAi';
|
|
9
9
|
export * from './configValue';
|
|
10
|
+
export * from './cryptoKey';
|
|
10
11
|
export * from './definePromiseMode';
|
|
11
12
|
export * from './deployEvent';
|
|
12
13
|
export * from './emailTemplates';
|
|
@@ -23,6 +23,7 @@ __exportStar(require("./applicationVersion"), exports);
|
|
|
23
23
|
__exportStar(require("./bundleOptions"), exports);
|
|
24
24
|
__exportStar(require("./claudeAi"), exports);
|
|
25
25
|
__exportStar(require("./configValue"), exports);
|
|
26
|
+
__exportStar(require("./cryptoKey"), exports);
|
|
26
27
|
__exportStar(require("./definePromiseMode"), exports);
|
|
27
28
|
__exportStar(require("./deployEvent"), exports);
|
|
28
29
|
__exportStar(require("./emailTemplates"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/config/settings/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,uCAAqB;AACrB,iDAA+B;AAC/B,sDAAoC;AACpC,oDAAkC;AAClC,uDAAqC;AACrC,kDAAgC;AAChC,6CAA2B;AAC3B,gDAA8B;AAC9B,sDAAoC;AACpC,gDAA8B;AAC9B,mDAAiC;AACjC,wDAAsC;AACtC,6CAA2B;AAC3B,yDAAuC;AACvC,2CAAyB;AACzB,kDAAgC;AAChC,mDAAiC;AACjC,sDAAoC;AACpC,kDAAgC;AAChC,+CAA6B;AAC7B,gDAA8B;AAC9B,8CAA4B;AAC5B,0CAAwB;AACxB,6CAA2B;AAC3B,2CAAyB;AACzB,oDAAkC;AAClC,iDAA+B;AAC/B,kDAAgC;AAChC,mDAAiC","sourcesContent":["export * from './actionProcessors';\nexport * from './ai';\nexport * from './apiBuildPath';\nexport * from './applicationModule';\nexport * from './applicationName';\nexport * from './applicationVersion';\nexport * from './bundleOptions';\nexport * from './claudeAi';\nexport * from './configValue';\nexport * from './definePromiseMode';\nexport * from './deployEvent';\nexport * from './emailTemplates';\nexport * from './environmentSettings';\nexport * from './eventBus';\nexport * from './federatedModuleStore';\nexport * from './global';\nexport * from './graphDatabase';\nexport * from './inlineFunction';\nexport * from './javascriptRuntime';\nexport * from './keyValueStore';\nexport * from './moduleName';\nexport * from './notifyError';\nexport * from './parameter';\nexport * from './queue';\nexport * from './schedule';\nexport * from './secret';\nexport * from './serviceSettings';\nexport * from './storageDrive';\nexport * from './userDirectory';\nexport * from './virtualNetwork';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/config/settings/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC;AACnC,uCAAqB;AACrB,iDAA+B;AAC/B,sDAAoC;AACpC,oDAAkC;AAClC,uDAAqC;AACrC,kDAAgC;AAChC,6CAA2B;AAC3B,gDAA8B;AAC9B,8CAA4B;AAC5B,sDAAoC;AACpC,gDAA8B;AAC9B,mDAAiC;AACjC,wDAAsC;AACtC,6CAA2B;AAC3B,yDAAuC;AACvC,2CAAyB;AACzB,kDAAgC;AAChC,mDAAiC;AACjC,sDAAoC;AACpC,kDAAgC;AAChC,+CAA6B;AAC7B,gDAA8B;AAC9B,8CAA4B;AAC5B,0CAAwB;AACxB,6CAA2B;AAC3B,2CAAyB;AACzB,oDAAkC;AAClC,iDAA+B;AAC/B,kDAAgC;AAChC,mDAAiC","sourcesContent":["export * from './actionProcessors';\nexport * from './ai';\nexport * from './apiBuildPath';\nexport * from './applicationModule';\nexport * from './applicationName';\nexport * from './applicationVersion';\nexport * from './bundleOptions';\nexport * from './claudeAi';\nexport * from './configValue';\nexport * from './cryptoKey';\nexport * from './definePromiseMode';\nexport * from './deployEvent';\nexport * from './emailTemplates';\nexport * from './environmentSettings';\nexport * from './eventBus';\nexport * from './federatedModuleStore';\nexport * from './global';\nexport * from './graphDatabase';\nexport * from './inlineFunction';\nexport * from './javascriptRuntime';\nexport * from './keyValueStore';\nexport * from './moduleName';\nexport * from './notifyError';\nexport * from './parameter';\nexport * from './queue';\nexport * from './schedule';\nexport * from './secret';\nexport * from './serviceSettings';\nexport * from './storageDrive';\nexport * from './userDirectory';\nexport * from './virtualNetwork';\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CrossModuleOwner, KeyOf } from '../../types';
|
|
1
|
+
import { CrossModuleOwner, KeyOf, QpqFunctionRuntime } from '../../types';
|
|
2
2
|
import { QPQConfigAdvancedSettings, QPQConfigSetting } from '../QPQConfig';
|
|
3
3
|
export type KvsKeyType = 'string' | 'number' | 'binary';
|
|
4
4
|
export type KvsKey<T extends object = any> = {
|
|
@@ -16,6 +16,41 @@ type CompositeCompositeKvsIndex<T extends object = any> = {
|
|
|
16
16
|
sortKey?: CompositeKvsKey<T>;
|
|
17
17
|
};
|
|
18
18
|
export type CompositeKvsIndex<T extends object = any> = KeyOf<T> | CompositeCompositeKvsIndex<T>;
|
|
19
|
+
/**
|
|
20
|
+
* Change data capture on a store: the table gets a stream (NEW_AND_OLD_IMAGES) and
|
|
21
|
+
* `runtime` is invoked with the changes.
|
|
22
|
+
*
|
|
23
|
+
* Records arrive in order PER PARTITION KEY, and different partition keys are processed
|
|
24
|
+
* concurrently. A stream handler therefore gets one-writer-per-item serialisation for
|
|
25
|
+
* free, which is what makes a stream the natural place to maintain a projection of a table
|
|
26
|
+
* you only ever append to — no queue, no extra write on the append path, and no trigger to
|
|
27
|
+
* lose, because the record exists precisely because the write happened.
|
|
28
|
+
*
|
|
29
|
+
* Mirrors defineStorageDrive's `onEvent`.
|
|
30
|
+
*/
|
|
31
|
+
export type KvsStreamSettings = {
|
|
32
|
+
runtime: QpqFunctionRuntime;
|
|
33
|
+
/**
|
|
34
|
+
* Collapse each delivered batch down to ONE record per partition key, keeping the latest.
|
|
35
|
+
*
|
|
36
|
+
* Off by default: a generic consumer (audit trail, change notifications) needs to see
|
|
37
|
+
* every change, and the framework should never silently drop records.
|
|
38
|
+
*
|
|
39
|
+
* On for a PROJECTION, where the payload that matters is "this key changed" and the
|
|
40
|
+
* handler re-derives from source anyway. Without it, the batch is fanned back out into
|
|
41
|
+
* one story run per record and the batching bought nothing: 500 appends to one document
|
|
42
|
+
* would mean 500 re-derivations, each reading a log that grows as it goes. With it, that
|
|
43
|
+
* batch is a single re-derivation.
|
|
44
|
+
*/
|
|
45
|
+
coalesceByPartitionKey?: boolean;
|
|
46
|
+
/** Records per invocation. DynamoDB streams allow up to 1000; the mapping default is 100. */
|
|
47
|
+
batchSize?: number;
|
|
48
|
+
/**
|
|
49
|
+
* How long to wait accumulating records before invoking, 0 to 300 seconds. Trades
|
|
50
|
+
* projection latency for far fewer invocations, and gives coalescing more to collapse.
|
|
51
|
+
*/
|
|
52
|
+
maximumBatchingWindowInSeconds?: number;
|
|
53
|
+
};
|
|
19
54
|
export interface QPQConfigAdvancedKeyValueStoreSettings<T extends object = any> extends QPQConfigAdvancedSettings {
|
|
20
55
|
indexes?: CompositeKvsIndex<T>[];
|
|
21
56
|
global?: boolean;
|
|
@@ -23,6 +58,7 @@ export interface QPQConfigAdvancedKeyValueStoreSettings<T extends object = any>
|
|
|
23
58
|
ttlAttribute?: string;
|
|
24
59
|
disablePointInTimeRecovery?: boolean;
|
|
25
60
|
encryption?: boolean;
|
|
61
|
+
onStream?: KvsStreamSettings;
|
|
26
62
|
}
|
|
27
63
|
export interface KeyValueStoreQPQConfigSetting<T extends object = any> extends QPQConfigSetting {
|
|
28
64
|
keyValueStoreName: string;
|
|
@@ -33,6 +69,7 @@ export interface KeyValueStoreQPQConfigSetting<T extends object = any> extends Q
|
|
|
33
69
|
ttlAttribute?: string;
|
|
34
70
|
disablePointInTimeRecovery: boolean;
|
|
35
71
|
encryption: boolean;
|
|
72
|
+
onStream?: KvsStreamSettings;
|
|
36
73
|
}
|
|
37
74
|
export declare const defineKeyValueStore: <T extends object = any>(keyValueStoreName: string, partitionKey: CompositeKvsKey<T>, sortKeys?: CompositeKvsKey<T>[], options?: QPQConfigAdvancedKeyValueStoreSettings<T>) => KeyValueStoreQPQConfigSetting<T>;
|
|
38
75
|
export {};
|
|
@@ -43,6 +43,7 @@ const defineKeyValueStore = (keyValueStoreName, partitionKey, sortKeys = [], opt
|
|
|
43
43
|
ttlAttribute: options === null || options === void 0 ? void 0 : options.ttlAttribute,
|
|
44
44
|
disablePointInTimeRecovery: (_c = options === null || options === void 0 ? void 0 : options.disablePointInTimeRecovery) !== null && _c !== void 0 ? _c : false,
|
|
45
45
|
encryption: (_d = options === null || options === void 0 ? void 0 : options.encryption) !== null && _d !== void 0 ? _d : false,
|
|
46
|
+
onStream: options === null || options === void 0 ? void 0 : options.onStream,
|
|
46
47
|
});
|
|
47
48
|
};
|
|
48
49
|
exports.defineKeyValueStore = defineKeyValueStore;
|