@secondlayer/subgraphs 4.0.4 → 4.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/index.js +3 -8
- package/dist/src/index.js.map +3 -3
- package/dist/src/runtime/block-processor.js +3 -8
- package/dist/src/runtime/block-processor.js.map +3 -3
- package/dist/src/runtime/catchup.js +3 -8
- package/dist/src/runtime/catchup.js.map +3 -3
- package/dist/src/runtime/processor.js +7 -15
- package/dist/src/runtime/processor.js.map +4 -4
- package/dist/src/runtime/reindex.js +3 -8
- package/dist/src/runtime/reindex.js.map +3 -3
- package/dist/src/runtime/reorg.js +3 -8
- package/dist/src/runtime/reorg.js.map +3 -3
- package/dist/src/runtime/replay.js +3 -8
- package/dist/src/runtime/replay.js.map +3 -3
- package/dist/src/service.js +7 -15
- package/dist/src/service.js.map +4 -4
- package/package.json +2 -2
|
@@ -1668,7 +1668,7 @@ import { sql as sql3 } from "kysely";
|
|
|
1668
1668
|
// src/runtime/block-source.ts
|
|
1669
1669
|
import { getSourceDb as getSourceDb2 } from "@secondlayer/shared/db";
|
|
1670
1670
|
import {
|
|
1671
|
-
|
|
1671
|
+
createInternalIndexHttpClient
|
|
1672
1672
|
} from "@secondlayer/shared/index-http";
|
|
1673
1673
|
import { logger as logger4 } from "@secondlayer/shared/logger";
|
|
1674
1674
|
|
|
@@ -2024,12 +2024,7 @@ class FallbackBlockSource {
|
|
|
2024
2024
|
}
|
|
2025
2025
|
var postgresBlockSource = new PostgresBlockSource;
|
|
2026
2026
|
function buildHttpClient() {
|
|
2027
|
-
|
|
2028
|
-
return new IndexHttpClient({
|
|
2029
|
-
indexBaseUrl: baseUrl,
|
|
2030
|
-
streamsBaseUrl: baseUrl,
|
|
2031
|
-
streamsApiKey: process.env.STREAMS_INTERNAL_API_KEY ?? "sk-sl_streams_decode_internal"
|
|
2032
|
-
});
|
|
2027
|
+
return createInternalIndexHttpClient();
|
|
2033
2028
|
}
|
|
2034
2029
|
function resolveBlockSource(subgraph) {
|
|
2035
2030
|
if (process.env.SUBGRAPH_SOURCE === "streams-index" && subgraph && isStreamsIndexEligible(subgraph)) {
|
|
@@ -3980,7 +3975,9 @@ import {
|
|
|
3980
3975
|
|
|
3981
3976
|
// src/runtime/streams-reorg-poll.ts
|
|
3982
3977
|
import { getErrorMessage as getErrorMessage5 } from "@secondlayer/shared";
|
|
3983
|
-
import {
|
|
3978
|
+
import {
|
|
3979
|
+
createInternalIndexHttpClient as createInternalIndexHttpClient2
|
|
3980
|
+
} from "@secondlayer/shared/index-http";
|
|
3984
3981
|
import { logger as logger12 } from "@secondlayer/shared/logger";
|
|
3985
3982
|
var POLL_MS = Number(process.env.SUBGRAPH_REORG_POLL_MS) || 15000;
|
|
3986
3983
|
var STARTUP_MARGIN_MS = 60 * 60 * 1000;
|
|
@@ -4005,12 +4002,7 @@ async function pollReorgsOnce(http2, cursor, onReorg, handled) {
|
|
|
4005
4002
|
return next_since ?? cursor;
|
|
4006
4003
|
}
|
|
4007
4004
|
function startStreamsReorgPoll(onReorg) {
|
|
4008
|
-
const
|
|
4009
|
-
const http2 = new IndexHttpClient2({
|
|
4010
|
-
indexBaseUrl: baseUrl,
|
|
4011
|
-
streamsBaseUrl: baseUrl,
|
|
4012
|
-
streamsApiKey: process.env.STREAMS_INTERNAL_API_KEY ?? "sk-sl_streams_decode_internal"
|
|
4013
|
-
});
|
|
4005
|
+
const http2 = createInternalIndexHttpClient2();
|
|
4014
4006
|
let since = new Date(Date.now() - STARTUP_MARGIN_MS).toISOString();
|
|
4015
4007
|
let running = true;
|
|
4016
4008
|
let timer;
|
|
@@ -4392,5 +4384,5 @@ export {
|
|
|
4392
4384
|
startSubgraphOperationRunner
|
|
4393
4385
|
};
|
|
4394
4386
|
|
|
4395
|
-
//# debugId=
|
|
4387
|
+
//# debugId=175795E59F84AF1D64756E2164756E21
|
|
4396
4388
|
//# sourceMappingURL=processor.js.map
|