@secondlayer/shared 18.0.1 → 18.0.2
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/archive/range-digest.d.ts +8 -0
- package/dist/src/archive/semantic-digest-builder.d.ts +8 -0
- package/dist/src/coverage/index.d.ts +8 -0
- package/dist/src/db/index.d.ts +10 -1
- package/dist/src/db/index.js +2 -1
- package/dist/src/db/index.js.map +4 -4
- package/dist/src/db/queries/chain-reorgs.d.ts +8 -0
- package/dist/src/db/queries/chain-reorgs.js +2 -1
- package/dist/src/db/queries/chain-reorgs.js.map +4 -4
- package/dist/src/db/queries/contracts.d.ts +8 -0
- package/dist/src/db/queries/contracts.js.map +2 -2
- package/dist/src/db/queries/instance.d.ts +8 -0
- package/dist/src/db/queries/integrity.d.ts +8 -0
- package/dist/src/db/queries/subgraph-gaps.d.ts +8 -0
- package/dist/src/db/queries/subgraph-operations.d.ts +8 -0
- package/dist/src/db/queries/subgraphs.d.ts +8 -0
- package/dist/src/db/queries/sync-scope.d.ts +8 -0
- package/dist/src/db/queries/webhook-replays.d.ts +8 -0
- package/dist/src/db/queries/webhooks.d.ts +8 -0
- package/dist/src/db/schema.d.ts +9 -1
- package/dist/src/db/schema.js.map +2 -2
- package/dist/src/index.d.ts +10 -1
- package/dist/src/index.js +2 -1
- package/dist/src/index.js.map +4 -4
- package/dist/src/insights/index.d.ts +8 -0
- package/dist/src/leader.js +2 -1
- package/dist/src/leader.js.map +4 -4
- package/dist/src/node/local-client.d.ts +8 -0
- package/dist/src/queue/listener.js +2 -1
- package/dist/src/queue/listener.js.map +4 -4
- package/migrations/0216_events_total_baseline.ts +26 -0
- package/package.json +1 -1
|
@@ -715,6 +715,13 @@ interface BnsNamespacesTable {
|
|
|
715
715
|
* `index_block_hash` marks a caller-declared contract-constant value, cached
|
|
716
716
|
* once per contract+args instead of once per block.
|
|
717
717
|
*/
|
|
718
|
+
interface EventsTotalBaselineTable {
|
|
719
|
+
id: Generated<boolean>;
|
|
720
|
+
through: ColumnType<number | null, number | null | undefined, number | null>;
|
|
721
|
+
count: ColumnType<string | null, string | number | null | undefined, string | number | null>;
|
|
722
|
+
taken_at: Date | null;
|
|
723
|
+
claimed_at: Date | null;
|
|
724
|
+
}
|
|
718
725
|
interface ChainReadCacheTable {
|
|
719
726
|
id: Generated<number>;
|
|
720
727
|
contract_id: string;
|
|
@@ -858,6 +865,7 @@ interface Database {
|
|
|
858
865
|
bns_namespaces: BnsNamespacesTable;
|
|
859
866
|
service_heartbeats: ServiceHeartbeatsTable;
|
|
860
867
|
chain_read_cache: ChainReadCacheTable;
|
|
868
|
+
events_total_baseline: EventsTotalBaselineTable;
|
|
861
869
|
pending_fork_blocks: PendingForkBlocksTable;
|
|
862
870
|
observer_journal: ObserverJournalTable;
|
|
863
871
|
sync_scopes: SyncScopesTable;
|
|
@@ -715,6 +715,13 @@ interface BnsNamespacesTable {
|
|
|
715
715
|
* `index_block_hash` marks a caller-declared contract-constant value, cached
|
|
716
716
|
* once per contract+args instead of once per block.
|
|
717
717
|
*/
|
|
718
|
+
interface EventsTotalBaselineTable {
|
|
719
|
+
id: Generated<boolean>;
|
|
720
|
+
through: ColumnType<number | null, number | null | undefined, number | null>;
|
|
721
|
+
count: ColumnType<string | null, string | number | null | undefined, string | number | null>;
|
|
722
|
+
taken_at: Date | null;
|
|
723
|
+
claimed_at: Date | null;
|
|
724
|
+
}
|
|
718
725
|
interface ChainReadCacheTable {
|
|
719
726
|
id: Generated<number>;
|
|
720
727
|
contract_id: string;
|
|
@@ -858,6 +865,7 @@ interface Database {
|
|
|
858
865
|
bns_namespaces: BnsNamespacesTable;
|
|
859
866
|
service_heartbeats: ServiceHeartbeatsTable;
|
|
860
867
|
chain_read_cache: ChainReadCacheTable;
|
|
868
|
+
events_total_baseline: EventsTotalBaselineTable;
|
|
861
869
|
pending_fork_blocks: PendingForkBlocksTable;
|
|
862
870
|
observer_journal: ObserverJournalTable;
|
|
863
871
|
sync_scopes: SyncScopesTable;
|
|
@@ -1034,6 +1034,13 @@ interface BnsNamespacesTable {
|
|
|
1034
1034
|
* `index_block_hash` marks a caller-declared contract-constant value, cached
|
|
1035
1035
|
* once per contract+args instead of once per block.
|
|
1036
1036
|
*/
|
|
1037
|
+
interface EventsTotalBaselineTable {
|
|
1038
|
+
id: Generated<boolean>;
|
|
1039
|
+
through: ColumnType<number | null, number | null | undefined, number | null>;
|
|
1040
|
+
count: ColumnType<string | null, string | number | null | undefined, string | number | null>;
|
|
1041
|
+
taken_at: Date | null;
|
|
1042
|
+
claimed_at: Date | null;
|
|
1043
|
+
}
|
|
1037
1044
|
interface ChainReadCacheTable {
|
|
1038
1045
|
id: Generated<number>;
|
|
1039
1046
|
contract_id: string;
|
|
@@ -1177,6 +1184,7 @@ interface Database {
|
|
|
1177
1184
|
bns_namespaces: BnsNamespacesTable;
|
|
1178
1185
|
service_heartbeats: ServiceHeartbeatsTable;
|
|
1179
1186
|
chain_read_cache: ChainReadCacheTable;
|
|
1187
|
+
events_total_baseline: EventsTotalBaselineTable;
|
|
1180
1188
|
pending_fork_blocks: PendingForkBlocksTable;
|
|
1181
1189
|
observer_journal: ObserverJournalTable;
|
|
1182
1190
|
sync_scopes: SyncScopesTable;
|
package/dist/src/db/index.d.ts
CHANGED
|
@@ -718,6 +718,13 @@ interface BnsNamespacesTable {
|
|
|
718
718
|
* `index_block_hash` marks a caller-declared contract-constant value, cached
|
|
719
719
|
* once per contract+args instead of once per block.
|
|
720
720
|
*/
|
|
721
|
+
interface EventsTotalBaselineTable {
|
|
722
|
+
id: Generated<boolean>;
|
|
723
|
+
through: ColumnType<number | null, number | null | undefined, number | null>;
|
|
724
|
+
count: ColumnType<string | null, string | number | null | undefined, string | number | null>;
|
|
725
|
+
taken_at: Date | null;
|
|
726
|
+
claimed_at: Date | null;
|
|
727
|
+
}
|
|
721
728
|
interface ChainReadCacheTable {
|
|
722
729
|
id: Generated<number>;
|
|
723
730
|
contract_id: string;
|
|
@@ -861,6 +868,7 @@ interface Database {
|
|
|
861
868
|
bns_namespaces: BnsNamespacesTable;
|
|
862
869
|
service_heartbeats: ServiceHeartbeatsTable;
|
|
863
870
|
chain_read_cache: ChainReadCacheTable;
|
|
871
|
+
events_total_baseline: EventsTotalBaselineTable;
|
|
864
872
|
pending_fork_blocks: PendingForkBlocksTable;
|
|
865
873
|
observer_journal: ObserverJournalTable;
|
|
866
874
|
sync_scopes: SyncScopesTable;
|
|
@@ -2238,6 +2246,7 @@ declare const TABLE_TO_DB: {
|
|
|
2238
2246
|
contracts: string
|
|
2239
2247
|
chain_reorgs: string
|
|
2240
2248
|
chain_read_cache: string
|
|
2249
|
+
events_total_baseline: string
|
|
2241
2250
|
pending_fork_blocks: string
|
|
2242
2251
|
observer_journal: string
|
|
2243
2252
|
sync_scopes: string
|
|
@@ -2403,4 +2412,4 @@ declare function closeDb(): Promise<void>;
|
|
|
2403
2412
|
* actual work is done.
|
|
2404
2413
|
*/
|
|
2405
2414
|
declare function closeDbOrTimeout(timeoutMs?: number, closeFn?: () => Promise<void>): Promise<void>;
|
|
2406
|
-
export { ABI_STATUSES, AbiStatus, Account, AccountBalanceAlerts, AccountBalanceAlertsTable, AccountCredits, AccountCreditsTable, AccountSpendCap, AccountSpendCapsTable, AccountsTable, ApiFailedRequest, ApiFailedRequestsTable, ApiKey, ApiKeyStatus, ApiKeysTable, ApiRequestLogRow, ApiRequestLogTable, ArchiveFetch, ArchiveFetchesTable, Block, BlocksTable, BnsMarketplaceAction, BnsMarketplaceEventsTable, BnsNameEventTopic, BnsNameEventsTable, BnsNamesTable, BnsNamespaceEventStatus, BnsNamespaceEventsTable, BnsNamespacesTable, BurnBlockRewardSlotsTable, BurnBlockRewardsTable, ChainReadCacheTable, ChainReorgsTable, CliDeviceLogin, CliDeviceLoginStatus, CliDeviceLoginsTable, CliDeviceProduct, ContactRequest, ContactRequestsTable, Contract, ContractsTable, Database, DbPlane, DbReadRow, DbSplitStatus, DeadLetterEventsTable, DeadReason, DecodedEventsTable, DecoderCheckpointsTable, Event, EventsArchiveTable, EventsTable, FailureClass, FailureUnit, FeedbackTicket, FeedbackTicketsTable, GapReason, HostedStackStateTable, IndexColumn, IndexColumnType, IndexPrimaryKey, IndexProgress, IndexProgressTable, InsertAccount, InsertAccountBalanceAlerts, InsertAccountCredits, InsertAccountSpendCap, InsertApiFailedRequest, InsertApiKey, InsertApiRequestLogRow, InsertArchiveFetch, InsertBlock, InsertContactRequest, InsertContract, InsertEvent, InsertFeedbackTicket, InsertIndexProgress, InsertMagicLink, InsertMempoolTransaction, InsertSession, InsertStateWrite, InsertSubgraph, InsertSubgraphGap, InsertSubgraphHealthSnapshot, InsertSubgraphOperation, InsertTransaction, InsertUpdateSubscriber, InsertUsageLedgerRow, InsertVmEvent, InsertWaitlistSignup, InsertWebhook, InsertWebhookDelivery, InsertWebhookOutbox, InsightMutesTable, InsightsTable, InstancesTable, MagicLink, MagicLinksTable, MempoolTransaction, MempoolTransactionsTable, MigrationRole, NativeClock, NumericAsText, OBSERVER_JOURNAL_STATUSES, OauthClient, OauthClientsTable, OauthCodesTable, OauthGrant, OauthGrantsTable, OauthRefreshRetiredTable, OauthRequestStatus, OauthRequestsTable, OauthTokenKind, OauthTokensTable, ObserverJournalStatus, ObserverJournalTable, OutboxStatus, PendingForkBlocksTable, Pox5CycleSignersTable, Pox5CyclesTable, Pox5EventTopic, Pox5EventsTable, ProcessedStripeEventsTable, PushPrefs, PushPrefsTable, PushSentTable, PushSubscription, PushSubscriptionsTable, RepairMode, RetryState, RunStatus, SOURCE_READ_COLUMNS, SOURCE_READ_PKS, SOURCE_READ_TYPES, SbtcEventTopic, SbtcEventsTable, SbtcSettlementsTable, SentinelAccount, SentinelAccountsTable, ServiceHeartbeatsTable, Session, SessionsTable, StageFailuresTable, StageKind, StageRegistryTable, StateWrite, StateWritesArchiveTable, StateWritesTable, Subgraph, SubgraphErrorGroupsTable, SubgraphGap, SubgraphGapsTable, SubgraphHealthSnapshot, SubgraphHealthSnapshotsTable, SubgraphOperation, SubgraphOperationKind, SubgraphOperationStatus, SubgraphOperationsTable, SubgraphProcessingStatsTable, SubgraphViolationsTable, SubgraphsTable, SyncScopesTable, TABLE_TO_DB, Transaction, TransactionsArchiveTable, TransactionsTable, TriggerEvaluatorState, TriggerEvaluatorStateTable, UpdateAccountBalanceAlerts, UpdateAccountCredits, UpdateAccountSpendCap, UpdateApiKey, UpdateArchiveFetch, UpdateBlock, UpdateContract, UpdateEvent, UpdateIndexProgress, UpdateSendsTable, UpdateSubgraph, UpdateSubgraphOperation, UpdateSubscriber, UpdateSubscribersTable, UpdateTransaction, UpdateUsageLedgerRow, UpdateVmEvent, UpdateWebhook, UpdateWebhookOutbox, UsageLedgerRow, UsageLedgerTable, VmEvent, VmEventsArchiveTable, VmEventsTable, Waitlist, WaitlistSignup, WaitlistSignupsTable, WaitlistsTable, Webhook, WebhookDeliveriesTable, WebhookDelivery, WebhookDeliveryHoursTable, WebhookFormat, WebhookIncidentAlert, WebhookIncidentAlertsTable, WebhookKind, WebhookOutbox, WebhookOutboxTable, WebhookPauseReason, WebhookReplay, WebhookReplayStatus, WebhookReplaysTable, WebhookStatus, WebhooksTable, applicationDatabaseUrl, assertDbSplit, closeDb, closeDbOrTimeout, configuredSourceUrl, configuredTargetUrl, describeDbUrl, getDb, getDbSplitStatus, getMigrationRole, getRawClient, getSourceDb, getTargetDb, jsonb, onChainPlane, onControlPlane, parseJsonb, resolveSourceUrl, resolveTargetUrl, setMigrationRole, sql };
|
|
2415
|
+
export { ABI_STATUSES, AbiStatus, Account, AccountBalanceAlerts, AccountBalanceAlertsTable, AccountCredits, AccountCreditsTable, AccountSpendCap, AccountSpendCapsTable, AccountsTable, ApiFailedRequest, ApiFailedRequestsTable, ApiKey, ApiKeyStatus, ApiKeysTable, ApiRequestLogRow, ApiRequestLogTable, ArchiveFetch, ArchiveFetchesTable, Block, BlocksTable, BnsMarketplaceAction, BnsMarketplaceEventsTable, BnsNameEventTopic, BnsNameEventsTable, BnsNamesTable, BnsNamespaceEventStatus, BnsNamespaceEventsTable, BnsNamespacesTable, BurnBlockRewardSlotsTable, BurnBlockRewardsTable, ChainReadCacheTable, ChainReorgsTable, CliDeviceLogin, CliDeviceLoginStatus, CliDeviceLoginsTable, CliDeviceProduct, ContactRequest, ContactRequestsTable, Contract, ContractsTable, Database, DbPlane, DbReadRow, DbSplitStatus, DeadLetterEventsTable, DeadReason, DecodedEventsTable, DecoderCheckpointsTable, Event, EventsArchiveTable, EventsTable, EventsTotalBaselineTable, FailureClass, FailureUnit, FeedbackTicket, FeedbackTicketsTable, GapReason, HostedStackStateTable, IndexColumn, IndexColumnType, IndexPrimaryKey, IndexProgress, IndexProgressTable, InsertAccount, InsertAccountBalanceAlerts, InsertAccountCredits, InsertAccountSpendCap, InsertApiFailedRequest, InsertApiKey, InsertApiRequestLogRow, InsertArchiveFetch, InsertBlock, InsertContactRequest, InsertContract, InsertEvent, InsertFeedbackTicket, InsertIndexProgress, InsertMagicLink, InsertMempoolTransaction, InsertSession, InsertStateWrite, InsertSubgraph, InsertSubgraphGap, InsertSubgraphHealthSnapshot, InsertSubgraphOperation, InsertTransaction, InsertUpdateSubscriber, InsertUsageLedgerRow, InsertVmEvent, InsertWaitlistSignup, InsertWebhook, InsertWebhookDelivery, InsertWebhookOutbox, InsightMutesTable, InsightsTable, InstancesTable, MagicLink, MagicLinksTable, MempoolTransaction, MempoolTransactionsTable, MigrationRole, NativeClock, NumericAsText, OBSERVER_JOURNAL_STATUSES, OauthClient, OauthClientsTable, OauthCodesTable, OauthGrant, OauthGrantsTable, OauthRefreshRetiredTable, OauthRequestStatus, OauthRequestsTable, OauthTokenKind, OauthTokensTable, ObserverJournalStatus, ObserverJournalTable, OutboxStatus, PendingForkBlocksTable, Pox5CycleSignersTable, Pox5CyclesTable, Pox5EventTopic, Pox5EventsTable, ProcessedStripeEventsTable, PushPrefs, PushPrefsTable, PushSentTable, PushSubscription, PushSubscriptionsTable, RepairMode, RetryState, RunStatus, SOURCE_READ_COLUMNS, SOURCE_READ_PKS, SOURCE_READ_TYPES, SbtcEventTopic, SbtcEventsTable, SbtcSettlementsTable, SentinelAccount, SentinelAccountsTable, ServiceHeartbeatsTable, Session, SessionsTable, StageFailuresTable, StageKind, StageRegistryTable, StateWrite, StateWritesArchiveTable, StateWritesTable, Subgraph, SubgraphErrorGroupsTable, SubgraphGap, SubgraphGapsTable, SubgraphHealthSnapshot, SubgraphHealthSnapshotsTable, SubgraphOperation, SubgraphOperationKind, SubgraphOperationStatus, SubgraphOperationsTable, SubgraphProcessingStatsTable, SubgraphViolationsTable, SubgraphsTable, SyncScopesTable, TABLE_TO_DB, Transaction, TransactionsArchiveTable, TransactionsTable, TriggerEvaluatorState, TriggerEvaluatorStateTable, UpdateAccountBalanceAlerts, UpdateAccountCredits, UpdateAccountSpendCap, UpdateApiKey, UpdateArchiveFetch, UpdateBlock, UpdateContract, UpdateEvent, UpdateIndexProgress, UpdateSendsTable, UpdateSubgraph, UpdateSubgraphOperation, UpdateSubscriber, UpdateSubscribersTable, UpdateTransaction, UpdateUsageLedgerRow, UpdateVmEvent, UpdateWebhook, UpdateWebhookOutbox, UsageLedgerRow, UsageLedgerTable, VmEvent, VmEventsArchiveTable, VmEventsTable, Waitlist, WaitlistSignup, WaitlistSignupsTable, WaitlistsTable, Webhook, WebhookDeliveriesTable, WebhookDelivery, WebhookDeliveryHoursTable, WebhookFormat, WebhookIncidentAlert, WebhookIncidentAlertsTable, WebhookKind, WebhookOutbox, WebhookOutboxTable, WebhookPauseReason, WebhookReplay, WebhookReplayStatus, WebhookReplaysTable, WebhookStatus, WebhooksTable, applicationDatabaseUrl, assertDbSplit, closeDb, closeDbOrTimeout, configuredSourceUrl, configuredTargetUrl, describeDbUrl, getDb, getDbSplitStatus, getMigrationRole, getRawClient, getSourceDb, getTargetDb, jsonb, onChainPlane, onControlPlane, parseJsonb, resolveSourceUrl, resolveTargetUrl, setMigrationRole, sql };
|
package/dist/src/db/index.js
CHANGED
|
@@ -694,6 +694,7 @@ var TABLE_TO_DB = {
|
|
|
694
694
|
contracts: "source",
|
|
695
695
|
chain_reorgs: "source",
|
|
696
696
|
chain_read_cache: "source",
|
|
697
|
+
events_total_baseline: "source",
|
|
697
698
|
pending_fork_blocks: "source",
|
|
698
699
|
observer_journal: "source",
|
|
699
700
|
sync_scopes: "source",
|
|
@@ -969,5 +970,5 @@ export {
|
|
|
969
970
|
sql2 as sql
|
|
970
971
|
};
|
|
971
972
|
|
|
972
|
-
//# debugId=
|
|
973
|
+
//# debugId=376ED2B815C4DEF464756E2164756E21
|
|
973
974
|
//# sourceMappingURL=index.js.map
|