How to upgrade website incrementally
Technology is changing rapidly. But businesses have been running their activities for decades. Tools or Languages that have a thriving future are obsolete in a few years. To keep up to date, they need to upgrade their Software. Sometimes, Incremental upgrades are necessary. But upgrading a running Website can be a daunting task. Here are a few tips to help you get started.
Feasibility study
You have to decide whether it is economically viable to have an incremental replacement or whether a whole website replacement will be more suitable. List of all the challenges you might encounter during the transformation and plan them accordingly.
Requirement
You must have a clear requirement even If you are instructed to convert the old system. Find out the architectural design, project planning, and other docs the current web app has.
It helps you to understand the functionality. In addition to that, Contact with old team members to know more about it. Very precise knowledge about the functionality and codebase of the current website is mandatory.
Planning
Plan Driven Development instead of Agile development.
A perfect plan is crucial for the successful completion of transformation.
Each member of the team must know details about the system that is going to be transformed. For that, several workshops can be organized to educate team members about the codebase and functionality of the old system as well as coding standards, architectural design and best practices of the new system.
Create individual tasks based on each endpoint and group tasks by component or module and Write down possible side effects, e.g. Event handling, Mail, Notification, and linked services.
Each task should have a priority and serial number so that development happens based on the initial plan.
Data Model
It’s highly recommended to have only one database in both old and new systems.
Sometimes, you might choose two different databases than one.
Change on one database must be implemented on another ASAP for data consistency.
If the old database consists of one-way encrypted data, then you can do the following.
1. Implement the same algorithm on the new system so that encrypted data can be utilised
2. Ask the user to input encrypted data again.
Routing & Integration
It is the most crucial part of the entire process. Let’s say you have a few routes (URLs) ready in a new application and want to serve it from the new one. Visitors should be redirected to the new application when they try to access those URLs in the old system.
It is important to carefully plan and execute the process of redirecting users from the old website to the new website. There are a few different ways to handle redirects, including using the server (such as Apache or Nginx), redirecting from the application root, or using a controller method or file.
For example, when a user visits www.example.com/privacy-policy on the old website, they should be redirected to www.example.com/new/privacy-policy or www.new.example.com/privacy-policy on the new website until the full transition is complete. It is important to minimise changes to the URL structure to minimise confusion for the user.
One way to do this is to create a list of old and new URLs, and use this list to check the current URL and redirect as needed.
It may also be helpful to include a warning on the website about the transition to let users know about any changes to the URL or subdomain.
UX & UI
To ensure a good user experience, it is important for the UI and UX of the new application to be consistent. This means that the user should feel like they are browsing the same Website. It may be advisable to wait until the full transition is completed before making any updates to the UI to avoid confusing the user.
Communication
Communication is a vital part . Anything that happens on one website must be notified to the others so that others can do something if required.
We can do that using Message Queues like RabbitMQ, AMQP and so on.
Authentication
Two websites are completely different so their authentication systems might be different.
So when we logged in a user on an old website, We should send a Message via Queue about the login info and tokens to the new website. So that new website can save it and once a user is redirected to the new website with that authentication token, New website recognises that user and marks them as a logged in user.