Skip to content

Commit

Permalink
updated migration guide
Browse files Browse the repository at this point in the history
  • Loading branch information
kirankumar-grootan committed Jul 16, 2024
1 parent f4f5bb0 commit 81fa78f
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions docs/whats_new.md
Original file line number Diff line number Diff line change
Expand Up @@ -475,11 +475,10 @@ app.Use(static.New("", static.Config{

### Healthcheck

#### Before Update

Previously, the Healthcheck middleware was configured with a combined setup for liveliness and readiness probes:

```go
//before
app.Use(healthcheck.New(healthcheck.Config{
LivenessProbe: func(c *fiber.Ctx) bool {
return true
Expand All @@ -492,11 +491,11 @@ app.Use(healthcheck.New(healthcheck.Config{
}))
```

#### After Update

With the new version, each health check endpoint is configured separately, allowing for more flexibility:

```go
// after

// Default liveness endpoint configuration
app.Get(healthcheck.DefaultLivenessEndpoint, healthcheck.NewHealthChecker(healthcheck.Config{
Probe: func(c *fiber.Ctx) bool {
Expand Down

0 comments on commit 81fa78f

Please sign in to comment.