cds-snc / cds-snc/platform-forms-client
More specific logging to differentiate failures on the "submit" action
- Dominant language
- TypeScript
- Stars
- 46
- Forks
- 16
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 85
Description
## Context
From [#incident-2025-08-13-users-blocked-from-submitting](https://docs.google.com/document/d/1VnhPebwNRzQ4j5OaZfzgOqDT51G5QMUY5jZ4mtWulHY/edit?tab=t.0#heading=h.gjdgxs)
## Description
Upon incident investigation, we saw that the logged error try-catch wraps a lot of code, including:
- Prisma database call (to retrieve template)
- Redis call (to retrieve hCaptcha feature flag)
- hCaptcha API call
- Invoking the Submission Lambda
- Sending notifications
- Extended outages
We might want to refactor the submit function and improving the granularity of logging and messages for submit to help diagnose problems, that are all wrapped in same try…catch and provide more specific and narrow logging messages for each of these.
Contributor guide
Assessment
This issue has not been assessed yet.