Skip to content

Commit

Permalink
Remove reporting from /health/info (#521)
Browse files Browse the repository at this point in the history
https://eaflood.atlassian.net/browse/WATER-4169

Three charging forecast reports were built by the previous dev team. They are accessed from a link on the manage page in the internal UI. They have never been used because they were identified as returning incorrect values and have never been fixed for 'reasons'. They will never be fixed because all reporting work is being handled by our partnership with RDP and RSP.

This means [water-abstraction-reporting](https://github.com/DEFRA/water-abstraction-reporting) is a defunct app we can remove from the service. One of the first steps to allow this to happen is for the `/health/info` page which we use to check the health of the service to stop pinging reporting.

This change removes that check plus any associated config which was needed to support it.
  • Loading branch information
Cruikshanks authored Nov 14, 2023
1 parent 58fb4d4 commit d40480d
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 18 deletions.
1 change: 0 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ EA_ADDRESS_FACADE_URL=http://localhost:8009
CHARGING_MODULE_URL=http://localhost:8020
SERVICE_FOREGROUND_URL=http://localhost:8001
SERVICE_BACKGROUND_URL=http://localhost:8012
REPORTING_URL=http://localhost:8011
IMPORT_URL=http://localhost:8007
TACTICAL_CRM_URL=http://localhost:8002
EXTERNAL_UI_URL=http://localhost:8000
Expand Down
5 changes: 0 additions & 5 deletions app/lib/legacy-request.lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,6 @@ const services = {
base: servicesConfig.permitRepository.url,
api: 'API/1.0/'
},
// water-abstraction-reporting - reporting
reporting: {
base: servicesConfig.reporting.url,
api: 'reporting/1.0'
},
// water-abstraction-returns - returns
returns: {
base: servicesConfig.returns.url,
Expand Down
1 change: 0 additions & 1 deletion app/services/health/info.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ async function _getLegacyAppData () {
{ name: 'Returns', serviceName: 'returns' },
{ name: 'Tactical CRM', serviceName: 'crm' },
{ name: 'Tactical IDM', serviceName: 'idm' },
{ name: 'Reporting', serviceName: 'reporting' },
{ name: 'Permit repository', serviceName: 'permits' }
]

Expand Down
3 changes: 0 additions & 3 deletions config/services.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ const config = {
serviceBackground: {
url: process.env.SERVICE_BACKGROUND_URL
},
reporting: {
url: process.env.REPORTING_URL
},
import: {
url: process.env.IMPORT_URL
},
Expand Down
16 changes: 8 additions & 8 deletions test/services/health/info.service.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ describe('Info service', () => {
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])

expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].name).to.equal('Import')
expect(result.appData[0].serviceName).to.equal('import')
expect(result.appData[0].version).to.equal('9.0.99')
Expand Down Expand Up @@ -189,7 +189,7 @@ describe('Info service', () => {
expect(result).to.include([
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])
expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].version).to.equal('9.0.99')
expect(result.appData[0].jobs).to.have.length(2)

Expand Down Expand Up @@ -232,7 +232,7 @@ describe('Info service', () => {
expect(result).to.include([
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])
expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].version).to.equal('9.0.99')
expect(result.appData[0].jobs).to.have.length(2)

Expand All @@ -259,7 +259,7 @@ describe('Info service', () => {
expect(result).to.include([
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])
expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].version).to.equal('9.0.99')
expect(result.appData[0].jobs).to.have.length(2)

Expand Down Expand Up @@ -301,7 +301,7 @@ describe('Info service', () => {
expect(result).to.include([
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])
expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].version).to.equal('9.0.99')
expect(result.appData[0].jobs).to.have.length(0)

Expand All @@ -321,7 +321,7 @@ describe('Info service', () => {
expect(result).to.include([
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])
expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].version).to.equal('9.0.99')
expect(result.appData[0].jobs).to.have.length(0)

Expand Down Expand Up @@ -365,7 +365,7 @@ describe('Info service', () => {
expect(result).to.include([
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])
expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].version).to.equal('9.0.99')
expect(result.appData[0].jobs).to.have.length(2)

Expand All @@ -392,7 +392,7 @@ describe('Info service', () => {
expect(result).to.include([
'virusScannerData', 'redisConnectivityData', 'addressFacadeData', 'chargingModuleData', 'appData'
])
expect(result.appData).to.have.length(11)
expect(result.appData).to.have.length(10)
expect(result.appData[0].version).to.equal('9.0.99')
expect(result.appData[0].jobs).to.have.length(2)

Expand Down

0 comments on commit d40480d

Please sign in to comment.