Skip to content

Commit e086ef9

Browse files
committed
Added more logging to Finalizing
1 parent bcafd44 commit e086ef9

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

apps/webapp/app/v3/services/finalizeTaskRun.server.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import { type Prisma, type TaskRun, type TaskRunStatus } from "@trigger.dev/data
22
import { type PrismaClientOrTransaction } from "~/db.server";
33
import { marqs } from "~/v3/marqs/index.server";
44
import { BaseService } from "./baseService.server";
5+
import { logger } from "~/services/logger.server";
56

67
type BaseInput = {
78
tx: PrismaClientOrTransaction;
@@ -34,8 +35,21 @@ export class FinalizeTaskRunService extends BaseService {
3435
}: T extends Prisma.TaskRunInclude ? InputWithInclude<T> : InputWithoutInclude): Promise<
3536
Output<T>
3637
> {
38+
logger.debug("Finalizing run marqs ack", {
39+
id,
40+
status,
41+
expiredAt,
42+
completedAt,
43+
});
3744
await marqs?.acknowledgeMessage(id);
3845

46+
logger.debug("Finalizing run updating run status", {
47+
id,
48+
status,
49+
expiredAt,
50+
completedAt,
51+
});
52+
3953
const run = await tx.taskRun.update({
4054
where: { id },
4155
data: { status, expiredAt, completedAt },

0 commit comments

Comments
 (0)