MCPcopy
hub / github.com/Effect-TS/effect / interrupt

Function interrupt

packages/sql/src/SqlPersistedQueue.ts:241–257  ·  view source on GitHub ↗
(ids: Array<number>)

Source from the content-addressed store, hash-verified

239 )
240 }
241 const interrupt = (ids: Array<number>) => {
242 for (const id of ids) {
243 elementIds.delete(id)
244 }
245 return sql`
246 UPDATE ${tableNameSql}
247 SET acquired_at = NULL, acquired_by = NULL
248 WHERE sequence IN (${sql.literal(ids.join(","))})
249 AND acquired_by = ${workerIdSql}
250 `.pipe(
251 Effect.retry({
252 times: 5,
253 schedule: Schedule.exponential(100, 1.5)
254 }),
255 Effect.orDie
256 )
257 }
258
259 yield* refreshLocks.pipe(
260 Effect.tapErrorCause(Effect.logWarning),

Callers 1

Calls 2

pipeMethod · 0.65
joinMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…