MCPcopy Index your code
hub / github.com/simstudioai/sim / enqueue

Function enqueue

apps/sim/app/api/table/[tableId]/events/stream/route.ts:59–66  ·  view source on GitHub ↗
(text: string)

Source from the content-addressed store, hash-verified

57 let nextHeartbeatAt = Date.now() + HEARTBEAT_INTERVAL_MS
58
59 const enqueue = (text: string) => {
60 if (closed) return
61 try {
62 controller.enqueue(encoder.encode(text))
63 } catch {
64 closed = true
65 }
66 }
67
68 const sendEvents = (events: TableEventEntry[]) => {
69 for (const entry of events) {

Callers 4

sendEventsFunction · 0.70
sendPrunedAndCloseFunction · 0.70
sendHeartbeatFunction · 0.70
startFunction · 0.70

Calls 1

enqueueMethod · 0.65

Tested by

no test coverage detected