File tree Expand file tree Collapse file tree
internal-packages/run-engine/src/run-queue Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2133,8 +2133,10 @@ export class RunQueue {
21332133 const messageId = message . runId ;
21342134 const messageData = JSON . stringify ( message ) ;
21352135 const messageScore = String ( message . timestamp ) ;
2136- const currentTime = String ( Date . now ( ) ) ;
2137- const enableFastPathArg = enableFastPath ? "1" : "0" ;
2136+ const currentTimeMs = Date . now ( ) ;
2137+ const shouldEnableFastPath = enableFastPath && message . timestamp <= currentTimeMs ;
2138+ const currentTime = String ( currentTimeMs ) ;
2139+ const enableFastPathArg = shouldEnableFastPath ? "1" : "0" ;
21382140 const metricsGaugeArg = this . #queueMetricsGaugeArg( ) ;
21392141 const defaultEnvConcurrencyLimit = String ( this . options . defaultEnvConcurrency ) ;
21402142 const defaultEnvConcurrencyBurstFactor = String (
@@ -2155,6 +2157,7 @@ export class RunQueue {
21552157 messageScore,
21562158 masterQueueKey,
21572159 enableFastPath,
2160+ shouldEnableFastPath,
21582161 ttlInfo,
21592162 service : this . name ,
21602163 } ) ;
You can’t perform that action at this time.
0 commit comments