pulibrary / lib_jobs

Enterprise Services batch processing tasks. Rails 7 Ruby 3.1.0
4 stars 0 forks source link

Add a health.json endpoint that determines this application is ready to serve live users #814

Closed maxkadel closed 3 days ago

maxkadel commented 3 months ago

What maintenance needs to be done?

We want the load balancer to never serve sites that are broken. That can happen automatically if every application has a health.json endpoint that the load balancer can check.

Level of urgency

Why is this maintenance needed?

Right now it's easy to deploy to one of x servers, have that deploy fail, and thus have the site go down, unless we do a laborious load balancer dance.

Acceptance criteria

Implementation notes, if any

An example implementation: https://github.com/pulibrary/lae-blacklight/pull/380/files

First Step

Install the health-monitor-rails gem to the gem file, as per the above PR.

Health monitor rails gem: https://github.com/lbeder/health-monitor-rails