DEFRA / water-abstraction-team

Guides, info and issue management for the Water Abstraction Team
Other
1 stars 0 forks source link

Remove blipp from water-abstraction-system #111

Closed Cruikshanks closed 5 months ago

Cruikshanks commented 10 months ago

Blipp is a Hapi plugin to

[..] display the routes table to console at startup.

We and it seems most other Defra services add this as standard to projects. There is nothing like seeing this appear in the early days of getting a project going!

http://e527582369f6:8013
method  path                                                 auth     scope                    description
------  ---------------------------------------------------  -------  -----------------------  ------------------------------------------------------------------------------------------------------------------------------------------------
GET     /                                                    none     none                     Returns the same response as /status
GET     /assets/{path*}                                      none     none
GET     /assets/all.js                                       none     none
GET     /bill-licences/{id}                                  session  billing                  Used to view a bill licence and it's transactions
POST    /bill-runs                                           session  billing                  Used to create a bill run
GET     /bill-runs/{id}                                      session  billing                  View a bill run
GET     /bill-runs/{id}/review                               session  billing                  Review two-part tariff match and allocation results
POST    /billing-accounts/{billingAccountId}/change-address  session  manage_billing_accounts  Used updating a billing account with a new address
GET     /bills/{id}                                          session  billing                  Used to view a bill
GET     /check/two-part-licence/{licenceId}                  none     none                     Used by the delivery team to check the SROC 2PT billing logic for a single licence
GET     /check/two-part/{naldRegionId}                       none     none                     Used by the delivery team to check the SROC 2PT billing logic for all licences in a region
POST    /data/seed                                           none     none                     Used to seed test data in the database
POST    /data/tear-down                                      none     none                     Used to remove the acceptance test data from the database
GET     /health/airbrake                                     none     none                     Used by the delivery team to confirm error logging is working correctly in an environment. NOTE. We expect this endpoint to return a 500
GET     /health/database                                     none     none                     Used by the delivery team to confirm we can connect to the database. It also returns us some useful stats about each table.
GET     /health/info                                         session  none                     Used by the delivery team to confirm we can connect to our other apps and services. It also returns us the version and commit hash for each one.
GET     /jobs/export                                         none     none                     Used to export the database and upload the file to our AWS S3 bucket
POST    /jobs/time-limited                                   none     none                     Puts a licence into workflow when a charge element has a `timeLimitedEndDate` which is < 50 days away
GET     /licences/{id}/add-a-note                            session  billing                  Returns add a note page
GET     /licences/{id}/no-return-check-your-answers          session  billing                  No return check your answers page
GET     /licences/{id}/no-returns-required                   session  billing                  Review two-part tariff match and allocation results
GET     /licences/{id}/requirements-approved                 session  billing                  Returns requirements approved
GET     /licences/{id}/returns-check-your-answers            session  billing                  Returns check your answers page
GET     /licences/{id}/select-return-start-date              session  billing                  Select the start date of the return
GET     /robots.txt                                          none     none                     Needed to support requests proxied from the legacy UI through to this app
GET     /status                                              none     none                     Used by the AWS load balancers to confirm the service is running

Look! My app is working.

But we've been (rightly) challenged on what value this adds. As the project progresses the number of routes is going to expand so that routing table is going to get very noisy. It's an extra dependency and we even have untested logic in server.js to only add the plugin when in non-prod environments.

Keeping to our ethos of minimal and simple, why do we have this dependency?!

Having discussed it no one could make a case for keeping it. So, we think it is time to say goodbye to Blipp 😢👋

Jozzey commented 5 months ago