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

Function updateJobProgress

apps/sim/lib/table/jobs/service.ts:181–192  ·  view source on GitHub ↗
(
  tableId: string,
  rowsProcessed: number,
  jobId: string
)

Source from the content-addressed store, hash-verified

179 * in-flight job.
180 */
181export async function updateJobProgress(
182 tableId: string,
183 rowsProcessed: number,
184 jobId: string
185): Promise<boolean> {
186 const updated = await db
187 .update(tableJobs)
188 .set({ rowsProcessed, updatedAt: new Date() })
189 .where(ownsActiveJob(tableId, jobId))
190 .returning({ id: tableJobs.id })
191 return updated.length > 0
192}
193
194/**
195 * Reads the persisted progress of an in-flight job this worker still owns (`null` when the job

Callers 6

flushFunction · 0.90
runTableImportFunction · 0.90
runTableUpdateFunction · 0.90
runTableExportFunction · 0.90
runTableBackfillFunction · 0.90
runTableDeleteFunction · 0.90

Calls 2

ownsActiveJobFunction · 0.85
setMethod · 0.65

Tested by

no test coverage detected