This repository was archived by the owner on Mar 14, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Expand file tree Collapse file tree 2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -57,6 +57,11 @@ const schema = Type.Object({
57
57
) ,
58
58
/** If the API should automatically shut down when Ordhook ingestion mode is `replay` */
59
59
ORDHOOK_REPLAY_INGESTION_MODE_AUTO_SHUTDOWN : Type . Boolean ( { default : true } ) ,
60
+ /**
61
+ * If the API should check that streamed blocks received from Ordhook are contiguous (without
62
+ * inscription number gaps).
63
+ */
64
+ ORDHOOK_STREAMED_BLOCK_CONTINUITY_CHECK : Type . Boolean ( { default : true } ) ,
60
65
61
66
PGHOST : Type . String ( ) ,
62
67
PGPORT : Type . Number ( { default : 5432 , minimum : 0 , maximum : 65535 } ) ,
Original file line number Diff line number Diff line change @@ -149,7 +149,8 @@ export class PgStore extends BasePgStore {
149
149
}
150
150
switch ( direction ) {
151
151
case 'apply' :
152
- if ( streamed ) await this . assertNextBlockIsContiguous ( sql , event , cache ) ;
152
+ if ( streamed && ENV . ORDHOOK_STREAMED_BLOCK_CONTINUITY_CHECK )
153
+ await this . assertNextBlockIsContiguous ( sql , event , cache ) ;
153
154
await this . applyInscriptions ( sql , cache , streamed ) ;
154
155
break ;
155
156
case 'rollback' :
You can’t perform that action at this time.
0 commit comments