@sentio/runtime 3.4.0 → 3.4.1-rc.1
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/chunk-5BMC7M3M.js +60244 -0
- package/lib/{chunk-X5CIKWKP.js.map → chunk-5BMC7M3M.js.map} +1 -1
- package/lib/chunk-EXIISBRV.js +26084 -0
- package/lib/chunk-EXIISBRV.js.map +1 -0
- package/lib/chunk-I45UXGDM.js +1697 -0
- package/lib/{chunk-TW627LH5.js.map → chunk-I45UXGDM.js.map} +1 -1
- package/lib/chunk-KVSDPGUI.js +50 -0
- package/lib/chunk-L2A6JPIQ.js +21 -0
- package/lib/{chunk-CJDESLYQ.js.map → chunk-L2A6JPIQ.js.map} +1 -1
- package/lib/getMachineId-bsd-QYFPRONP.js +41 -0
- package/lib/{getMachineId-bsd-CDSZ2S36.js.map → getMachineId-bsd-QYFPRONP.js.map} +1 -1
- package/lib/getMachineId-darwin-XC67FIUW.js +41 -0
- package/lib/{getMachineId-darwin-LM5BSWCG.js.map → getMachineId-darwin-XC67FIUW.js.map} +1 -1
- package/lib/getMachineId-linux-4G7ZY7LQ.js +33 -0
- package/lib/{getMachineId-linux-UA53ZQFA.js.map → getMachineId-linux-4G7ZY7LQ.js.map} +1 -1
- package/lib/getMachineId-unsupported-5IH5IW7P.js +24 -0
- package/lib/{getMachineId-unsupported-LDR77GGJ.js.map → getMachineId-unsupported-5IH5IW7P.js.map} +1 -1
- package/lib/getMachineId-win-WSA3TUKL.js +43 -0
- package/lib/{getMachineId-win-XULW45X4.js.map → getMachineId-win-WSA3TUKL.js.map} +1 -1
- package/lib/index.js +139 -1
- package/lib/index.js.map +1 -1
- package/lib/processor-runner.js +30646 -73
- package/lib/processor-runner.js.map +1 -1
- package/lib/test-processor.test.js.map +1 -1
- package/package.json +1 -1
- package/src/gen/processor/protos/processor.ts +18 -1
- package/lib/chunk-AUPVVLD3.js +0 -3
- package/lib/chunk-CFG44J2I.js +0 -26
- package/lib/chunk-CFG44J2I.js.map +0 -1
- package/lib/chunk-CJDESLYQ.js +0 -3
- package/lib/chunk-TW627LH5.js +0 -3
- package/lib/chunk-X5CIKWKP.js +0 -117
- package/lib/getMachineId-bsd-CDSZ2S36.js +0 -3
- package/lib/getMachineId-darwin-LM5BSWCG.js +0 -4
- package/lib/getMachineId-linux-UA53ZQFA.js +0 -3
- package/lib/getMachineId-unsupported-LDR77GGJ.js +0 -3
- package/lib/getMachineId-win-XULW45X4.js +0 -3
- /package/lib/{chunk-AUPVVLD3.js.map → chunk-KVSDPGUI.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/test-processor.test.ts"],"sourcesContent":["import { Plugin, PluginManager } from './plugin.js'\nimport { DataBinding, HandlerType, ProcessResult } from './gen/processor/protos/processor.js'\nimport { AccountConfig, InitResponse, ProcessConfigResponse, ProcessStreamResponse_Partitions } from '@sentio/protos'\n\nexport class TestPlugin extends Plugin {\n async processBinding(request: DataBinding): Promise<ProcessResult> {\n const dbContext = PluginManager.INSTANCE.dbContextLocalStorage.getStore()\n if (dbContext) {\n await dbContext.sendRequest({\n get: {\n entity: 'Test',\n id: '1'\n }\n })\n }\n\n return ProcessResult.fromPartial({\n states: {\n configUpdated: true\n }\n })\n }\n supportedHandlers = [HandlerType.UNKNOWN, HandlerType.ETH_LOG]\n\n async partition(request: DataBinding): Promise<ProcessStreamResponse_Partitions> {\n return {\n partitions: request.handlerIds.reduce(\n (acc, id) => ({\n ...acc,\n [id]: {\n userValue: 'test'\n }\n }),\n {}\n )\n }\n }\n\n async init(config: InitResponse): Promise<void> {\n config.chainIds = ['1']\n }\n\n async configure(config: ProcessConfigResponse, forChainId?: string): Promise<void> {\n config.accountConfigs = [\n AccountConfig.fromPartial({\n address: '0x',\n chainId: '1'\n })\n ]\n }\n}\n\nPluginManager.INSTANCE.plugins = []\nPluginManager.INSTANCE.register(new TestPlugin())\n;import(\"node:process\").then((p) => p.stdout.write(\"\"));"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/test-processor.test.ts"],"sourcesContent":["import { Plugin, PluginManager } from './plugin.js'\nimport { DataBinding, HandlerType, ProcessResult } from './gen/processor/protos/processor.js'\nimport { AccountConfig, InitResponse, ProcessConfigResponse, ProcessStreamResponse_Partitions } from '@sentio/protos'\n\nexport class TestPlugin extends Plugin {\n async processBinding(request: DataBinding): Promise<ProcessResult> {\n const dbContext = PluginManager.INSTANCE.dbContextLocalStorage.getStore()\n if (dbContext) {\n await dbContext.sendRequest({\n get: {\n entity: 'Test',\n id: '1'\n }\n })\n }\n\n return ProcessResult.fromPartial({\n states: {\n configUpdated: true\n }\n })\n }\n supportedHandlers = [HandlerType.UNKNOWN, HandlerType.ETH_LOG]\n\n async partition(request: DataBinding): Promise<ProcessStreamResponse_Partitions> {\n return {\n partitions: request.handlerIds.reduce(\n (acc, id) => ({\n ...acc,\n [id]: {\n userValue: 'test'\n }\n }),\n {}\n )\n }\n }\n\n async init(config: InitResponse): Promise<void> {\n config.chainIds = ['1']\n }\n\n async configure(config: ProcessConfigResponse, forChainId?: string): Promise<void> {\n config.accountConfigs = [\n AccountConfig.fromPartial({\n address: '0x',\n chainId: '1'\n })\n ]\n }\n}\n\nPluginManager.INSTANCE.plugins = []\nPluginManager.INSTANCE.register(new TestPlugin())\n;import(\"node:process\").then((p) => p.stdout.write(\"\"));"],"mappings":";;;;;;;;;;AAIO,IAAM,aAAN,cAAyB,OAAO;AAAA,EACrC,MAAM,eAAe,SAA8C;AACjE,UAAM,YAAY,cAAc,SAAS,sBAAsB,SAAS;AACxE,QAAI,WAAW;AACb,YAAM,UAAU,YAAY;AAAA,QAC1B,KAAK;AAAA,UACH,QAAQ;AAAA,UACR,IAAI;AAAA,QACN;AAAA,MACF,CAAC;AAAA,IACH;AAEA,WAAO,cAAc,YAAY;AAAA,MAC/B,QAAQ;AAAA,QACN,eAAe;AAAA,MACjB;AAAA,IACF,CAAC;AAAA,EACH;AAAA,EACA,oBAAoB,iCAAyC;AAAA,EAE7D,MAAM,UAAU,SAAiE;AAC/E,WAAO;AAAA,MACL,YAAY,QAAQ,WAAW;AAAA,QAC7B,CAAC,KAAK,QAAQ;AAAA,UACZ,GAAG;AAAA,UACH,CAAC,EAAE,GAAG;AAAA,YACJ,WAAW;AAAA,UACb;AAAA,QACF;AAAA,QACA,CAAC;AAAA,MACH;AAAA,IACF;AAAA,EACF;AAAA,EAEA,MAAM,KAAK,QAAqC;AAC9C,WAAO,WAAW,CAAC,GAAG;AAAA,EACxB;AAAA,EAEA,MAAM,UAAU,QAA+B,YAAoC;AACjF,WAAO,iBAAiB;AAAA,MACtB,cAAc,YAAY;AAAA,QACxB,SAAS;AAAA,QACT,SAAS;AAAA,MACX,CAAC;AAAA,IACH;AAAA,EACF;AACF;AAEA,cAAc,SAAS,UAAU,CAAC;AAClC,cAAc,SAAS,SAAS,IAAI,WAAW,CAAC;AAC/C,OAAO,cAAc,EAAE,KAAK,CAAC,MAAM,EAAE,OAAO,MAAM,EAAE,CAAC;","names":[]}
|
package/package.json
CHANGED
|
@@ -834,7 +834,9 @@ export interface MoveCallHandlerConfig {
|
|
|
834
834
|
}
|
|
835
835
|
|
|
836
836
|
export interface MoveResourceChangeConfig {
|
|
837
|
+
/** @deprecated */
|
|
837
838
|
type: string;
|
|
839
|
+
types: string[];
|
|
838
840
|
includeDeleted: boolean;
|
|
839
841
|
handlerId: number;
|
|
840
842
|
handlerName: string;
|
|
@@ -6431,7 +6433,7 @@ export const MoveCallHandlerConfig = {
|
|
|
6431
6433
|
};
|
|
6432
6434
|
|
|
6433
6435
|
function createBaseMoveResourceChangeConfig(): MoveResourceChangeConfig {
|
|
6434
|
-
return { type: "", includeDeleted: false, handlerId: 0, handlerName: "" };
|
|
6436
|
+
return { type: "", types: [], includeDeleted: false, handlerId: 0, handlerName: "" };
|
|
6435
6437
|
}
|
|
6436
6438
|
|
|
6437
6439
|
export const MoveResourceChangeConfig = {
|
|
@@ -6439,6 +6441,9 @@ export const MoveResourceChangeConfig = {
|
|
|
6439
6441
|
if (message.type !== "") {
|
|
6440
6442
|
writer.uint32(10).string(message.type);
|
|
6441
6443
|
}
|
|
6444
|
+
for (const v of message.types) {
|
|
6445
|
+
writer.uint32(42).string(v!);
|
|
6446
|
+
}
|
|
6442
6447
|
if (message.includeDeleted !== false) {
|
|
6443
6448
|
writer.uint32(32).bool(message.includeDeleted);
|
|
6444
6449
|
}
|
|
@@ -6465,6 +6470,13 @@ export const MoveResourceChangeConfig = {
|
|
|
6465
6470
|
|
|
6466
6471
|
message.type = reader.string();
|
|
6467
6472
|
continue;
|
|
6473
|
+
case 5:
|
|
6474
|
+
if (tag !== 42) {
|
|
6475
|
+
break;
|
|
6476
|
+
}
|
|
6477
|
+
|
|
6478
|
+
message.types.push(reader.string());
|
|
6479
|
+
continue;
|
|
6468
6480
|
case 4:
|
|
6469
6481
|
if (tag !== 32) {
|
|
6470
6482
|
break;
|
|
@@ -6498,6 +6510,7 @@ export const MoveResourceChangeConfig = {
|
|
|
6498
6510
|
fromJSON(object: any): MoveResourceChangeConfig {
|
|
6499
6511
|
return {
|
|
6500
6512
|
type: isSet(object.type) ? globalThis.String(object.type) : "",
|
|
6513
|
+
types: globalThis.Array.isArray(object?.types) ? object.types.map((e: any) => globalThis.String(e)) : [],
|
|
6501
6514
|
includeDeleted: isSet(object.includeDeleted) ? globalThis.Boolean(object.includeDeleted) : false,
|
|
6502
6515
|
handlerId: isSet(object.handlerId) ? globalThis.Number(object.handlerId) : 0,
|
|
6503
6516
|
handlerName: isSet(object.handlerName) ? globalThis.String(object.handlerName) : "",
|
|
@@ -6509,6 +6522,9 @@ export const MoveResourceChangeConfig = {
|
|
|
6509
6522
|
if (message.type !== "") {
|
|
6510
6523
|
obj.type = message.type;
|
|
6511
6524
|
}
|
|
6525
|
+
if (message.types?.length) {
|
|
6526
|
+
obj.types = message.types;
|
|
6527
|
+
}
|
|
6512
6528
|
if (message.includeDeleted !== false) {
|
|
6513
6529
|
obj.includeDeleted = message.includeDeleted;
|
|
6514
6530
|
}
|
|
@@ -6527,6 +6543,7 @@ export const MoveResourceChangeConfig = {
|
|
|
6527
6543
|
fromPartial(object: DeepPartial<MoveResourceChangeConfig>): MoveResourceChangeConfig {
|
|
6528
6544
|
const message = createBaseMoveResourceChangeConfig();
|
|
6529
6545
|
message.type = object.type ?? "";
|
|
6546
|
+
message.types = object.types?.map((e) => e) || [];
|
|
6530
6547
|
message.includeDeleted = object.includeDeleted ?? false;
|
|
6531
6548
|
message.handlerId = object.handlerId ?? 0;
|
|
6532
6549
|
message.handlerName = object.handlerName ?? "";
|
package/lib/chunk-AUPVVLD3.js
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import { createRequire as createRequireShim } from 'module'; const require = createRequireShim(import.meta.url);
|
|
2
|
-
var h=Object.create;var e=Object.defineProperty;var i=Object.getOwnPropertyDescriptor;var j=Object.getOwnPropertyNames;var k=Object.getPrototypeOf,l=Object.prototype.hasOwnProperty;var m=(a=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(a,{get:(b,c)=>(typeof require<"u"?require:b)[c]}):a)(function(a){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+a+'" is not supported')});var n=(a,b)=>()=>(a&&(b=a(a=0)),b);var o=(a,b)=>()=>(b||a((b={exports:{}}).exports,b),b.exports),p=(a,b)=>{for(var c in b)e(a,c,{get:b[c],enumerable:!0})},g=(a,b,c,f)=>{if(b&&typeof b=="object"||typeof b=="function")for(let d of j(b))!l.call(a,d)&&d!==c&&e(a,d,{get:()=>b[d],enumerable:!(f=i(b,d))||f.enumerable});return a};var q=(a,b,c)=>(c=a!=null?h(k(a)):{},g(b||!a||!a.__esModule?e(c,"default",{value:a,enumerable:!0}):c,a)),r=a=>g(e({},"__esModule",{value:!0}),a);export{m as a,n as b,o as c,p as d,q as e,r as f};
|
|
3
|
-
//# sourceMappingURL=chunk-AUPVVLD3.js.map
|