Skip to content

Commit

Permalink
ES-1393 Fix /readyz returning 503 if readinessProbes not defined in o…
Browse files Browse the repository at this point in the history
…ptions
  • Loading branch information
sethidden committed Dec 16, 2024
1 parent f9fab52 commit 67ba895
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
7 changes: 7 additions & 0 deletions .changeset/curly-gifts-hang.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"@vue-storefront/middleware": patch
---

- **[FIXED]** Fix /readyz returning 503 if readinessProbes not passed in middleware.config.ts

Before this fix, sending a GET request would return { "status": "error" } and a HTTP 503 status. This happened only when `readinessProbes` wasn't added to middleware options (the default behavior)
2 changes: 1 addition & 1 deletion packages/middleware/src/terminus.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export const createReadyzHandler =
};

export const createTerminusOptions = (
readinessChecks: ReadinessProbe[]
readinessChecks: ReadinessProbe[] = []
): TerminusOptions => {
return {
useExit0: true,
Expand Down

0 comments on commit 67ba895

Please sign in to comment.