envio 3.0.0-alpha-main-clickhouse-sink → 3.0.0-alpha.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/bin.js +5 -3
- package/evm.schema.json +23 -6
- package/fuel.schema.json +17 -5
- package/index.d.ts +0 -27
- package/index.js +9 -6
- package/package.json +11 -7
- package/rescript.json +4 -3
- package/src/{Address.res.js → Address.res.mjs} +7 -6
- package/src/{Batch.res.js → Batch.res.mjs} +19 -18
- package/src/{ChainMap.res.js → ChainMap.res.mjs} +20 -19
- package/src/{Config.res.js → Config.res.mjs} +11 -10
- package/src/Envio.gen.ts +2 -15
- package/src/Envio.res +0 -36
- package/src/{Envio.res.js → Envio.res.mjs} +5 -16
- package/src/{ErrorHandling.res.js → ErrorHandling.res.mjs} +10 -9
- package/src/EventRegister.res +7 -0
- package/src/{EventRegister.res.js → EventRegister.res.mjs} +29 -18
- package/src/EventRegister.resi +1 -0
- package/src/{EventUtils.res.js → EventUtils.res.mjs} +10 -9
- package/src/{EvmTypes.res.js → EvmTypes.res.mjs} +5 -4
- package/src/{FetchState.res.js → FetchState.res.mjs} +44 -43
- package/src/{Hasura.res.js → Hasura.res.mjs} +25 -24
- package/src/{InMemoryStore.res.js → InMemoryStore.res.mjs} +19 -18
- package/src/{InMemoryTable.res.js → InMemoryTable.res.mjs} +21 -20
- package/src/Internal.gen.ts +1 -3
- package/src/Internal.res +9 -2
- package/src/{Internal.res.js → Internal.res.mjs} +21 -11
- package/src/{LazyLoader.res.js → LazyLoader.res.mjs} +14 -13
- package/src/{LoadManager.res.js → LoadManager.res.mjs} +11 -10
- package/src/{LogSelection.res.js → LogSelection.res.mjs} +14 -13
- package/src/{Logging.res.js → Logging.res.mjs} +37 -36
- package/src/{Persistence.res.js → Persistence.res.mjs} +22 -21
- package/src/{PgStorage.res.js → PgStorage.res.mjs} +58 -57
- package/src/Platform.res +4 -5
- package/src/{Platform.res.js → Platform.res.mjs} +10 -10
- package/src/{Prometheus.res.js → Prometheus.res.mjs} +66 -65
- package/src/{ReorgDetection.res.js → ReorgDetection.res.mjs} +12 -11
- package/src/{SafeCheckpointTracking.res.js → SafeCheckpointTracking.res.mjs} +6 -5
- package/src/{Sink.res.js → Sink.res.mjs} +6 -5
- package/src/{TableIndices.res.js → TableIndices.res.mjs} +8 -7
- package/src/{Throttler.res.js → Throttler.res.mjs} +7 -6
- package/src/{Time.res.js → Time.res.mjs} +8 -7
- package/src/{TopicFilter.res.js → TopicFilter.res.mjs} +18 -17
- package/src/Utils.res +40 -0
- package/src/{Utils.res.js → Utils.res.mjs} +68 -34
- package/src/bindings/BigDecimal.gen.ts +2 -2
- package/src/bindings/BigDecimal.res +5 -5
- package/src/bindings/BigDecimal.res.d.mts +5 -0
- package/src/bindings/{BigDecimal.res.js → BigDecimal.res.mjs} +10 -9
- package/src/bindings/BigInt.gen.ts +2 -2
- package/src/bindings/BigInt.res.d.mts +5 -0
- package/src/bindings/{BigInt.res.js → BigInt.res.mjs} +25 -24
- package/src/bindings/ClickHouse.res +2 -2
- package/src/bindings/{ClickHouse.res.js → ClickHouse.res.mjs} +22 -21
- package/src/bindings/Ethers.gen.ts +2 -2
- package/src/bindings/Ethers.res.d.mts +5 -0
- package/src/bindings/{Ethers.res.js → Ethers.res.mjs} +18 -17
- package/src/bindings/{Hrtime.res.js → Hrtime.res.mjs} +13 -12
- package/src/bindings/{Lodash.res.js → Lodash.res.mjs} +4 -3
- package/src/bindings/NodeJs.res +13 -1
- package/src/bindings/NodeJs.res.mjs +48 -0
- package/src/bindings/Pino.res +6 -6
- package/src/bindings/{Pino.res.js → Pino.res.mjs} +16 -15
- package/src/bindings/Postgres.res +2 -2
- package/src/bindings/{Postgres.res.js → Postgres.res.mjs} +4 -3
- package/src/bindings/{PromClient.res.js → PromClient.res.mjs} +6 -5
- package/src/bindings/{Promise.res.js → Promise.res.mjs} +6 -5
- package/src/bindings/{SDSL.res.js → SDSL.res.mjs} +3 -2
- package/src/bindings/{Viem.res.js → Viem.res.mjs} +9 -8
- package/src/bindings/vendored-lodash-fns.js +3 -35
- package/src/db/{EntityHistory.res.js → EntityHistory.res.mjs} +21 -20
- package/src/db/InternalTable.gen.ts +2 -2
- package/src/db/InternalTable.res +0 -2
- package/src/db/{InternalTable.res.js → InternalTable.res.mjs} +19 -19
- package/src/db/{Schema.res.js → Schema.res.mjs} +10 -9
- package/src/db/{Table.res.js → Table.res.mjs} +34 -33
- package/src/sources/{EventRouter.res.js → EventRouter.res.mjs} +17 -16
- package/src/sources/{Fuel.res.js → Fuel.res.mjs} +6 -5
- package/src/sources/{HyperFuel.res.js → HyperFuel.res.mjs} +14 -13
- package/src/sources/{HyperFuelClient.res.js → HyperFuelClient.res.mjs} +7 -6
- package/src/sources/{HyperFuelSource.res.js → HyperFuelSource.res.mjs} +28 -27
- package/src/sources/{HyperSync.res.js → HyperSync.res.mjs} +21 -20
- package/src/sources/HyperSyncClient.gen.ts +1 -1
- package/src/sources/HyperSyncClient.res +78 -20
- package/src/sources/{HyperSyncClient.res.js → HyperSyncClient.res.mjs} +32 -15
- package/src/sources/{HyperSyncJsonApi.res.js → HyperSyncJsonApi.res.mjs} +10 -9
- package/src/sources/HyperSyncSource.res +77 -9
- package/src/sources/{HyperSyncSource.res.js → HyperSyncSource.res.mjs} +99 -38
- package/src/sources/{Rpc.res.js → Rpc.res.mjs} +16 -15
- package/src/sources/{RpcSource.res.js → RpcSource.res.mjs} +40 -39
- package/src/sources/Source.res +1 -1
- package/src/sources/{Source.res.js → Source.res.mjs} +4 -3
- package/src/sources/SourceManager.res +12 -1
- package/src/sources/{SourceManager.res.js → SourceManager.res.mjs} +32 -21
- package/src/sources/vendored-fuel-abi-coder.js +94 -149
- package/src/vendored/{Rest.res.js → Rest.res.mjs} +12 -11
- package/src/bindings/NodeJs.res.js +0 -35
- /package/src/{Change.res.js → Change.res.mjs} +0 -0
- /package/src/{Indexer.res.js → Indexer.res.mjs} +0 -0
- /package/src/bindings/{Express.res.js → Express.res.mjs} +0 -0
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
3
|
+
import * as Utils from "./Utils.res.mjs";
|
|
4
|
+
import * as Js_exn from "rescript/lib/es6/js_exn.js";
|
|
5
|
+
import * as Logging from "./Logging.res.mjs";
|
|
6
|
+
import * as Belt_Array from "rescript/lib/es6/belt_Array.js";
|
|
7
|
+
import * as Prometheus from "./Prometheus.res.mjs";
|
|
8
|
+
import * as EntityHistory from "./db/EntityHistory.res.mjs";
|
|
9
|
+
import * as ErrorHandling from "./ErrorHandling.res.mjs";
|
|
10
|
+
import * as InMemoryStore from "./InMemoryStore.res.mjs";
|
|
11
|
+
import * as InMemoryTable from "./InMemoryTable.res.mjs";
|
|
12
|
+
import * as InternalTable from "./db/InternalTable.res.mjs";
|
|
13
|
+
import * as Caml_exceptions from "rescript/lib/es6/caml_exceptions.js";
|
|
14
|
+
import * as S$RescriptSchema from "rescript-schema/src/S.res.mjs";
|
|
15
|
+
import * as Caml_js_exceptions from "rescript/lib/es6/caml_js_exceptions.js";
|
|
17
16
|
|
|
18
17
|
var StorageError = /* @__PURE__ */Caml_exceptions.create("Persistence.StorageError");
|
|
19
18
|
|
|
@@ -202,11 +201,13 @@ async function prepareRollbackDiff(persistence, rollbackTargetCheckpointId, roll
|
|
|
202
201
|
};
|
|
203
202
|
}
|
|
204
203
|
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
204
|
+
export {
|
|
205
|
+
StorageError ,
|
|
206
|
+
make ,
|
|
207
|
+
init ,
|
|
208
|
+
getInitializedStorageOrThrow ,
|
|
209
|
+
getInitializedState ,
|
|
210
|
+
writeBatch ,
|
|
211
|
+
prepareRollbackDiff ,
|
|
212
|
+
}
|
|
212
213
|
/* Utils Not a pure module */
|
|
@@ -1,29 +1,28 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
3
|
+
import * as Fs from "fs";
|
|
4
|
+
import * as Path from "path";
|
|
5
|
+
import * as $$Array from "rescript/lib/es6/array.js";
|
|
6
|
+
import * as Table from "./db/Table.res.mjs";
|
|
7
|
+
import * as Utils from "./Utils.res.mjs";
|
|
8
|
+
import * as Config from "./Config.res.mjs";
|
|
9
|
+
import * as Hrtime from "./bindings/Hrtime.res.mjs";
|
|
10
|
+
import * as Js_exn from "rescript/lib/es6/js_exn.js";
|
|
11
|
+
import * as Schema from "./db/Schema.res.mjs";
|
|
12
|
+
import * as Js_dict from "rescript/lib/es6/js_dict.js";
|
|
13
|
+
import * as Logging from "./Logging.res.mjs";
|
|
14
|
+
import * as $$Promise from "./bindings/Promise.res.mjs";
|
|
15
|
+
import * as Internal from "./Internal.res.mjs";
|
|
16
|
+
import * as Belt_Array from "rescript/lib/es6/belt_Array.js";
|
|
17
|
+
import * as Prometheus from "./Prometheus.res.mjs";
|
|
18
|
+
import * as Caml_option from "rescript/lib/es6/caml_option.js";
|
|
19
|
+
import * as Persistence from "./Persistence.res.mjs";
|
|
20
|
+
import * as EntityHistory from "./db/EntityHistory.res.mjs";
|
|
21
|
+
import * as InternalTable from "./db/InternalTable.res.mjs";
|
|
22
|
+
import * as Child_process from "child_process";
|
|
23
|
+
import * as Caml_exceptions from "rescript/lib/es6/caml_exceptions.js";
|
|
24
|
+
import * as S$RescriptSchema from "rescript-schema/src/S.res.mjs";
|
|
25
|
+
import * as Caml_js_exceptions from "rescript/lib/es6/caml_js_exceptions.js";
|
|
27
26
|
|
|
28
27
|
var getCacheRowCountFnName = "get_cache_row_count";
|
|
29
28
|
|
|
@@ -1074,37 +1073,39 @@ function make(sql, pgHost, pgSchema, pgPort, pgUser, pgDatabase, pgPassword, isH
|
|
|
1074
1073
|
|
|
1075
1074
|
var maxItemsPerQuery = 500;
|
|
1076
1075
|
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1076
|
+
export {
|
|
1077
|
+
getCacheRowCountFnName ,
|
|
1078
|
+
makeCreateIndexQuery ,
|
|
1079
|
+
makeCreateTableIndicesQuery ,
|
|
1080
|
+
makeCreateTableQuery ,
|
|
1081
|
+
getEntityHistory ,
|
|
1082
|
+
makeInitializeTransaction ,
|
|
1083
|
+
makeLoadByIdQuery ,
|
|
1084
|
+
makeLoadByFieldQuery ,
|
|
1085
|
+
makeLoadByIdsQuery ,
|
|
1086
|
+
makeDeleteByIdQuery ,
|
|
1087
|
+
makeDeleteByIdsQuery ,
|
|
1088
|
+
makeLoadAllQuery ,
|
|
1089
|
+
makeInsertUnnestSetQuery ,
|
|
1090
|
+
makeInsertValuesSetQuery ,
|
|
1091
|
+
maxItemsPerQuery ,
|
|
1092
|
+
makeTableBatchSetQuery ,
|
|
1093
|
+
chunkArray ,
|
|
1094
|
+
removeInvalidUtf8InPlace ,
|
|
1095
|
+
pgErrorMessageSchema ,
|
|
1096
|
+
PgEncodingError ,
|
|
1097
|
+
setQueryCache ,
|
|
1098
|
+
setOrThrow ,
|
|
1099
|
+
makeSchemaTableNamesQuery ,
|
|
1100
|
+
cacheTablePrefixLength ,
|
|
1101
|
+
makeSchemaCacheTableInfoQuery ,
|
|
1102
|
+
getConnectedPsqlExec ,
|
|
1103
|
+
deleteByIdsOrThrow ,
|
|
1104
|
+
makeInsertDeleteUpdatesQuery ,
|
|
1105
|
+
executeSet ,
|
|
1106
|
+
writeBatch ,
|
|
1107
|
+
makeGetRollbackRestoredEntitiesQuery ,
|
|
1108
|
+
makeGetRollbackRemovedIdsQuery ,
|
|
1109
|
+
make ,
|
|
1110
|
+
}
|
|
1110
1111
|
/* pgErrorMessageSchema Not a pure module */
|
package/src/Platform.res
CHANGED
|
@@ -17,7 +17,7 @@ module Evm = {
|
|
|
17
17
|
@get external getNumber: Internal.eventBlock => int = "number"
|
|
18
18
|
@get external getTimestamp: Internal.eventBlock => int = "timestamp"
|
|
19
19
|
@get external getId: Internal.eventBlock => string = "hash"
|
|
20
|
-
|
|
20
|
+
|
|
21
21
|
let cleanUpRawEventFieldsInPlace: Js.Json.t => unit = %raw(`fields => {
|
|
22
22
|
delete fields.hash
|
|
23
23
|
delete fields.number
|
|
@@ -82,7 +82,7 @@ let evm: t = {
|
|
|
82
82
|
"chainId",
|
|
83
83
|
"maxFeePerBlobGas",
|
|
84
84
|
"blobVersionedHashes",
|
|
85
|
-
"
|
|
85
|
+
"type",
|
|
86
86
|
"l1Fee",
|
|
87
87
|
"l1GasPrice",
|
|
88
88
|
"l1GasUsed",
|
|
@@ -104,7 +104,7 @@ module Fuel = {
|
|
|
104
104
|
@get external getNumber: Internal.eventBlock => int = "height"
|
|
105
105
|
@get external getTimestamp: Internal.eventBlock => int = "time"
|
|
106
106
|
@get external getId: Internal.eventBlock => string = "id"
|
|
107
|
-
|
|
107
|
+
|
|
108
108
|
let cleanUpRawEventFieldsInPlace: Js.Json.t => unit = %raw(`fields => {
|
|
109
109
|
delete fields.id
|
|
110
110
|
delete fields.height
|
|
@@ -133,9 +133,8 @@ let fromName = (name: name): t => {
|
|
|
133
133
|
}
|
|
134
134
|
|
|
135
135
|
// Create a block event object for block handlers based on platform
|
|
136
|
-
let makeBlockEvent = (~blockNumber: int,
|
|
136
|
+
let makeBlockEvent = (~blockNumber: int, platform: t): Internal.blockEvent => {
|
|
137
137
|
let blockEvent = Js.Dict.empty()
|
|
138
|
-
blockEvent->Js.Dict.set("chainId", chainId->Utils.magic)
|
|
139
138
|
blockEvent->Js.Dict.set(platform.blockNumberName, blockNumber->Utils.magic)
|
|
140
139
|
blockEvent->Utils.magic
|
|
141
140
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
3
|
|
|
5
4
|
var cleanUpRawEventFieldsInPlace = (fields => {
|
|
@@ -68,7 +67,7 @@ var evm_transactionFields = [
|
|
|
68
67
|
"chainId",
|
|
69
68
|
"maxFeePerBlobGas",
|
|
70
69
|
"blobVersionedHashes",
|
|
71
|
-
"
|
|
70
|
+
"type",
|
|
72
71
|
"l1Fee",
|
|
73
72
|
"l1GasPrice",
|
|
74
73
|
"l1GasUsed",
|
|
@@ -154,17 +153,18 @@ function fromName(name) {
|
|
|
154
153
|
}
|
|
155
154
|
}
|
|
156
155
|
|
|
157
|
-
function makeBlockEvent(blockNumber,
|
|
156
|
+
function makeBlockEvent(blockNumber, platform) {
|
|
158
157
|
var blockEvent = {};
|
|
159
|
-
blockEvent["chainId"] = chainId;
|
|
160
158
|
blockEvent[platform.blockNumberName] = blockNumber;
|
|
161
159
|
return blockEvent;
|
|
162
160
|
}
|
|
163
161
|
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
162
|
+
export {
|
|
163
|
+
Evm ,
|
|
164
|
+
evm ,
|
|
165
|
+
Fuel ,
|
|
166
|
+
fuel ,
|
|
167
|
+
fromName ,
|
|
168
|
+
makeBlockEvent ,
|
|
169
|
+
}
|
|
170
170
|
/* No side effect */
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
3
|
+
import * as Utils from "./Utils.res.mjs";
|
|
4
|
+
import * as Hrtime from "./bindings/Hrtime.res.mjs";
|
|
5
|
+
import * as Js_exn from "rescript/lib/es6/js_exn.js";
|
|
6
|
+
import * as Belt_Array from "rescript/lib/es6/belt_Array.js";
|
|
7
|
+
import * as Belt_Result from "rescript/lib/es6/belt_Result.js";
|
|
8
|
+
import * as PromClient from "prom-client";
|
|
9
|
+
import * as S$RescriptSchema from "rescript-schema/src/S.res.mjs";
|
|
11
10
|
|
|
12
11
|
var loadEntitiesDurationCounter = new PromClient.Counter({
|
|
13
12
|
name: "load_entities_processing_time_spent",
|
|
@@ -848,61 +847,63 @@ var SinkWrite = {
|
|
|
848
847
|
increment: increment$7
|
|
849
848
|
};
|
|
850
849
|
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
850
|
+
export {
|
|
851
|
+
loadEntitiesDurationCounter ,
|
|
852
|
+
eventRouterDurationCounter ,
|
|
853
|
+
executeBatchDurationCounter ,
|
|
854
|
+
storageWriteTimeCounter ,
|
|
855
|
+
storageWriteCounter ,
|
|
856
|
+
allChainsSyncedToHead ,
|
|
857
|
+
sourceChainHeight ,
|
|
858
|
+
Labels ,
|
|
859
|
+
metricNames ,
|
|
860
|
+
MakeSafePromMetric ,
|
|
861
|
+
SafeCounter ,
|
|
862
|
+
SafeGauge ,
|
|
863
|
+
makeSafeHistogramOrThrow ,
|
|
864
|
+
BenchmarkSummaryData ,
|
|
865
|
+
incrementLoadEntityDurationCounter ,
|
|
866
|
+
incrementEventRouterDurationCounter ,
|
|
867
|
+
incrementExecuteBatchDurationCounter ,
|
|
868
|
+
incrementStorageWriteTimeCounter ,
|
|
869
|
+
incrementStorageWriteCounter ,
|
|
870
|
+
setSourceChainHeight ,
|
|
871
|
+
setAllChainsSyncedToHead ,
|
|
872
|
+
BenchmarkCounters ,
|
|
873
|
+
chainIdLabelsSchema ,
|
|
874
|
+
Info ,
|
|
875
|
+
IndexingAddresses ,
|
|
876
|
+
IndexingMaxConcurrency ,
|
|
877
|
+
IndexingConcurrency ,
|
|
878
|
+
IndexingPartitions ,
|
|
879
|
+
IndexingIdleTime ,
|
|
880
|
+
IndexingSourceWaitingTime ,
|
|
881
|
+
IndexingQueryTime ,
|
|
882
|
+
IndexingBufferSize ,
|
|
883
|
+
IndexingTargetBufferSize ,
|
|
884
|
+
IndexingBufferBlockNumber ,
|
|
885
|
+
IndexingEndBlock ,
|
|
886
|
+
sourceLabelsSchema ,
|
|
887
|
+
SourceHeight ,
|
|
888
|
+
SourceGetHeightDuration ,
|
|
889
|
+
ReorgCount ,
|
|
890
|
+
ReorgDetectionBlockNumber ,
|
|
891
|
+
ReorgThreshold ,
|
|
892
|
+
RollbackEnabled ,
|
|
893
|
+
RollbackSuccess ,
|
|
894
|
+
RollbackHistoryPrune ,
|
|
895
|
+
RollbackTargetBlockNumber ,
|
|
896
|
+
ProcessingMaxBatchSize ,
|
|
897
|
+
ProgressBlockNumber ,
|
|
898
|
+
ProgressEventsCount ,
|
|
899
|
+
ProgressBatchCount ,
|
|
900
|
+
ProgressLatency ,
|
|
901
|
+
effectLabelsSchema ,
|
|
902
|
+
EffectCalls ,
|
|
903
|
+
EffectCacheCount ,
|
|
904
|
+
EffectCacheInvalidationsCount ,
|
|
905
|
+
EffectQueueCount ,
|
|
906
|
+
StorageLoad ,
|
|
907
|
+
SinkWrite ,
|
|
908
|
+
}
|
|
908
909
|
/* loadEntitiesDurationCounter Not a pure module */
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
import * as Belt_Array from "rescript/lib/es6/belt_Array.js";
|
|
4
|
+
import * as Belt_Option from "rescript/lib/es6/belt_Option.js";
|
|
6
5
|
|
|
7
6
|
function reorgDetectedToLogParams(reorgDetected, shouldRollbackOnReorg) {
|
|
8
7
|
var scannedBlock = reorgDetected.scannedBlock;
|
|
@@ -185,12 +184,14 @@ function getHashByBlockNumber(reorgDetection, blockNumber) {
|
|
|
185
184
|
}
|
|
186
185
|
}
|
|
187
186
|
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
187
|
+
export {
|
|
188
|
+
reorgDetectedToLogParams ,
|
|
189
|
+
make ,
|
|
190
|
+
getDataByBlockNumberCopyInThreshold ,
|
|
191
|
+
registerReorgGuard ,
|
|
192
|
+
getLatestValidScannedBlock ,
|
|
193
|
+
rollbackToValidBlockNumber ,
|
|
194
|
+
getThresholdBlockNumbersBelowBlock ,
|
|
195
|
+
getHashByBlockNumber ,
|
|
196
|
+
}
|
|
196
197
|
/* No side effect */
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
3
|
|
|
5
4
|
function make(maxReorgDepth, shouldRollbackOnReorg, chainReorgCheckpoints) {
|
|
@@ -92,8 +91,10 @@ function rollback(safeCheckpointTracking, targetBlockNumber) {
|
|
|
92
91
|
};
|
|
93
92
|
}
|
|
94
93
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
94
|
+
export {
|
|
95
|
+
make ,
|
|
96
|
+
getSafeCheckpointId ,
|
|
97
|
+
updateOnNewBatch ,
|
|
98
|
+
rollback ,
|
|
99
|
+
}
|
|
99
100
|
/* No side effect */
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import * as Belt_Array from "rescript/lib/es6/belt_Array.js";
|
|
4
|
+
import * as ClickHouse from "./bindings/ClickHouse.res.mjs";
|
|
5
|
+
import * as Client from "@clickhouse/client";
|
|
7
6
|
|
|
8
7
|
function makeClickHouse(host, database, username, password) {
|
|
9
8
|
var client = Client.createClient({
|
|
@@ -32,5 +31,7 @@ function makeClickHouse(host, database, username, password) {
|
|
|
32
31
|
};
|
|
33
32
|
}
|
|
34
33
|
|
|
35
|
-
|
|
34
|
+
export {
|
|
35
|
+
makeClickHouse ,
|
|
36
|
+
}
|
|
36
37
|
/* ClickHouse Not a pure module */
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
import * as Caml_obj from "rescript/lib/es6/caml_obj.js";
|
|
4
|
+
import * as Belt_Array from "rescript/lib/es6/belt_Array.js";
|
|
6
5
|
|
|
7
6
|
function toString(tNonOptional) {
|
|
8
7
|
if (Array.isArray(tNonOptional)) {
|
|
@@ -136,8 +135,10 @@ var Index = {
|
|
|
136
135
|
evaluate: evaluate$1
|
|
137
136
|
};
|
|
138
137
|
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
138
|
+
export {
|
|
139
|
+
FieldValue ,
|
|
140
|
+
Operator ,
|
|
141
|
+
SingleIndex ,
|
|
142
|
+
Index ,
|
|
143
|
+
}
|
|
143
144
|
/* No side effect */
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import * as Pino from "./bindings/Pino.res.mjs";
|
|
4
|
+
import * as Utils from "./Utils.res.mjs";
|
|
5
|
+
import * as Caml_js_exceptions from "rescript/lib/es6/caml_js_exceptions.js";
|
|
7
6
|
|
|
8
7
|
function make(intervalMillis, logger) {
|
|
9
8
|
return {
|
|
@@ -56,6 +55,8 @@ function schedule(throttler, fn) {
|
|
|
56
55
|
startInternal(throttler);
|
|
57
56
|
}
|
|
58
57
|
|
|
59
|
-
|
|
60
|
-
|
|
58
|
+
export {
|
|
59
|
+
make ,
|
|
60
|
+
schedule ,
|
|
61
|
+
}
|
|
61
62
|
/* Pino Not a pure module */
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
3
|
+
import * as Utils from "./Utils.res.mjs";
|
|
4
|
+
import * as Logging from "./Logging.res.mjs";
|
|
5
|
+
import * as ErrorHandling from "./ErrorHandling.res.mjs";
|
|
6
|
+
import * as Caml_js_exceptions from "rescript/lib/es6/caml_js_exceptions.js";
|
|
8
7
|
|
|
9
8
|
function resolvePromiseAfterDelay(delayMilliseconds) {
|
|
10
9
|
return Utils.delay(delayMilliseconds);
|
|
@@ -35,6 +34,8 @@ async function retryAsyncWithExponentialBackOff(backOffMillisOpt, multiplicative
|
|
|
35
34
|
}
|
|
36
35
|
}
|
|
37
36
|
|
|
38
|
-
|
|
39
|
-
|
|
37
|
+
export {
|
|
38
|
+
resolvePromiseAfterDelay ,
|
|
39
|
+
retryAsyncWithExponentialBackOff ,
|
|
40
|
+
}
|
|
40
41
|
/* Utils Not a pure module */
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
// Generated by ReScript, PLEASE EDIT WITH CARE
|
|
2
|
-
'use strict';
|
|
3
2
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import * as Viem from "viem";
|
|
4
|
+
import * as $$BigInt from "./bindings/BigInt.res.mjs";
|
|
5
|
+
import * as Caml_option from "rescript/lib/es6/caml_option.js";
|
|
7
6
|
|
|
8
7
|
function toTwosComplement(num, bytesLen) {
|
|
9
8
|
var maxValue = $$BigInt.Bitwise.shift_left(1n, BigInt((bytesLen << 3)));
|
|
@@ -70,17 +69,19 @@ function fromBool(b) {
|
|
|
70
69
|
});
|
|
71
70
|
}
|
|
72
71
|
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
72
|
+
export {
|
|
73
|
+
toTwosComplement ,
|
|
74
|
+
fromSignedBigInt ,
|
|
75
|
+
keccak256 ,
|
|
76
|
+
bytesToHex ,
|
|
77
|
+
concat ,
|
|
78
|
+
castToHexUnsafe ,
|
|
79
|
+
fromBigInt ,
|
|
80
|
+
fromDynamicString ,
|
|
81
|
+
fromString ,
|
|
82
|
+
fromAddress ,
|
|
83
|
+
fromDynamicBytes ,
|
|
84
|
+
fromBytes ,
|
|
85
|
+
fromBool ,
|
|
86
|
+
}
|
|
86
87
|
/* viem Not a pure module */
|