Recently I was put into a position of a tech-lead on a very interesting project that I have been partially working for two years. This project carries a lot of legacy stuff with it even though we try to strip it down.
I am looking and researching a solution for my scenario:
- the website has lots of hard-coded IDs (even though they are extracted to one single place).
- it has bad database design that we can’t touch (because of custom CMS) and it prevents us from doing simple select statements that would get us the exact data that we need (that is why we have to hard-code IDs)
- it is using custom CMS that is maintained by different company
- because of hard-coded IDs (that often change) we have to do frequent releases (which raises a risk and brings extra cost for the customer).
The main concern that I have now is to prevent these releases because of hard-coded IDs.
The most sensible approach to this situation for now I came up with would be:
Move the IDs to new database and create a sensible structure there. Create basically a middle layer between the website and database. Create a new website for the new database for a client to manage. Which would essentially create another custom CMS which is again not ideal but better than frequent releases.
OR
Start using a commercial new CMS for IDs mentioned above and slowly migrate the whole website to a new proper CMS.
Have you ever experienced a project like this? What would be your best approach for this?
2
It’s been six months since I asked this question and the result is that we did kind of compromise between the custom CMS and our web application.
We introduced a few new fields in the CMS that would enable us to query the database in more reliable and flexible manner. After that we introduced a few new queries that help us getting the data dynamically. This seems to be as a good move as we got rid of all the hard-coded IDs and our code base shrinked as well so it’s much easier to maintain.