504 Gateway timeout error #10033
Unanswered
aakash-findingpi
asked this question in
Question
Replies: 1 comment
-
@aakash-findingpi is this on Hasura Cloud? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi community,
From past 2 weeks i am getting 504 issue when my API call reaches 20s limit.
Expressjs API -
exports.createTask = async (variables: any, req: any, res: any, next: any) => {
try {
const result: any = await createTaskPaperlite(variables, req, res, next);
console.log("createTaskPaperlite", result);
if (result?.status === 200) {
buildTaskResponse(
res,
result.status,
result?.data?.insert_company_task_one
);
}
} catch (error) {
console.log("ccccccccc", error);
next({
errorStack: error,
requestName:
exceptionDesc.taskExceptionDescription.TASK_CREATE_REQUEST_NAME,
unknownErrorDescription:
exceptionDesc.taskExceptionDescription.CREATE_UNKNOWN_ERROR_DESCRIPTION,
});
}
};
const createTaskPaperlite = async (
variables: any,
req: any,
res: any,
next: any
) => {
return new Promise(async (resolve) => {
const taskNoResult: any = await generateTaskNo(variables, next);
variables.task_no = taskNoResult.task_no; // update new task no in task payload
});
};
Mutation => mutation UpdateTaskCounter($id: uuid!, $task_counter: Int!) {
update_company_agency_services_by_pk(pk_columns: {id: $id}, _set: {task_counter: $task_counter}) {
task_counter
id
}
} ------------- This mutation is taking more than 10s
mutation AddTask($task_name: String!, $assigned_to: uuid!, $service_id: uuid!, $red_date: date!, $yellow_date: date!, $start_date: date, $due_date: date, $priority: String!, $status: String, $description: String, $poc_id: uuid!, $client_id: uuid!, $task_no: String!, $parent_task_id: uuid, $attachments: jsonb, $notify_to: jsonb, $visibility: jsonb, $createdby_hierarchy: jsonb, $reporter_to: uuid, $reviewer_to: uuid, $group_id: uuid, $group_tag: String, $sub_group_id: uuid) {
insert_company_task_one(object: {name: $task_name, assigned_to: $assigned_to, service_id: $service_id, red_date: $red_date, priority: $priority, start_date: $start_date, status: $status, yellow_date: $yellow_date, due_date: $due_date, description: $description, poc: $poc_id, client_id: $client_id, parent_task_id: $parent_task_id, task_no: $task_no, attachments: $attachments, notify_to: $notify_to, visibility: $visibility, createdby_hierarchy: $createdby_hierarchy, reporter_to: $reporter_to, reviewer_to: $reviewer_to, group_id: $group_id, group_tag: $group_tag, sub_group_id: $sub_group_id}) {
id
assigned_employee {
user_id
user {
full_name
profile_image
}
}
client {
full_name
}
client_firm_service {
service_name
agency_service {
service_name
}
}
document_checklists {
document_attachments
id
is_checked
is_mandatory
name
task_id
}
activity_checklists {
id
is_checked
name
task_id
}
created_by
org_id
task_no
group_tag
name
status
reviewer_to
}
} ------------------------- This is taking 10s or more.
Due to below queries the timeout issue occurs.
Please help me out.
Thankyou in Advance
Beta Was this translation helpful? Give feedback.
All reactions