Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove the replacement legacy import code (#1585)
https://eaflood.atlassian.net/browse/WATER-4535 By this time last year (December 2023), we completed a workshop with our ReSP colleagues and began working toward a vision that would conclude with NALD being replaced by ReSP. A key part of this vision would be a complete change in how we import our licence abstraction (ABS) data. The legacy process that examines _all_ licences, processing each one to determine whether it is new or changed, would be replaced by single licence 'events'. ReSP would provide an event bus to which our service would subscribe. As MVP (because details were scant), we would treat any event as a trigger to process a licence and determine whether it is new or changed. To be as ready as possible, we saw an opportunity to replace the existing legacy import and create the basis for that MVP. We would rebuild what the legacy import does but refactor the process to be licence-specific. For example, the legacy import has a CRM step for all licences, an abstraction step for all, and a returns step for all. We'd refactor that to do the CRM step, the abstraction step, and the returns step for a single licence. This work was done under [ReSP Import abstraction data prep—water.licence](https://eaflood.atlassian.net/browse/WATER-4535). Once we figured out how to verify that it was importing things correctly, we could test the contacts and abstraction steps. We'd then need to tackle returns information. Piggybacking on this work was the need to change two parts: tariff billing and return version management. These two features needed to know when a licence 'end dates' were changed to flag it for billing correctly and in case return logs were required to be reissued. This was no small job, and it got as far as it did thanks to the perseverance of @jonathangoulding . Unfortunately, events overtook this work and a new change in direction has been agreed. Now, WRLS itself will replace NALD. This means licences will be created and directly managed within the service. There will be no need for an import process _at all_. If it had changed direction once, there was always the chance it would change back! So, we decided to leave the work done within the app. If nothing else, it's a handy resource for figuring out what the legacy import is doing. However, management of the two-part tariff billing and return version still needs to know if a licence's end dates have changed. So, we've added a new job (see [WATER-4728 New 'import' job to trigger return log and supplementary flag checks](https://eaflood.atlassian.net/browse/WATER-4728)) at `/jobs/import-licences` specifically designed to trigger these two processes. The problem is that folks sometimes do it in this new job when it comes to managing two-part tariffs and returns. Other times, they update and amend the legacy licence import replacement we built. There is a concern that something will be missed or done incorrectly because the team is confused between the two. So, leaning into the knowledge that source control means deleted code is never truly lost, this change aims to remove the confusion by deleting the replacement legacy import functionality we added.
- Loading branch information