Our client is a fast-growing 24/7 Self-Storage service across the Middle East, specifically UAE and Kuwait.
The application was running in a deprecated Node 12 environment. If the environment is not upgraded immediately, the application would become unavailable to the users causing disruption to the business.
Customer experience:The system lacked a development/staging environment, and the updates were being manually deployed to the live environment causing errors which in turn was impacting the customers and resulting in customer dissatisfaction.
Employee satisfaction:The lack of testing and staging environment was affecting the business operations and the staff was really frustrated due to the daily occurrence of errors.
Slow rollout of features:Due to the lack of proper environments and deprecated software versions, the rollout of new features was delayed. This in turn impacted customer satisfaction.
Old Architecture
Solutions
As a start, we conducted the following analysis.
Analyzed the AWS infrastructure.
Analyzed the application code.
Analyzed the RDS Instances and configurations.
Analyzed the elastic beanstalk service configurations.
Analyzed elastic beanstalk deployment scripts
Analyzed the GitHub repository
Our findings were:
The existing deployment of the code was manually driven, and the developers had to connect to a remote machine via TeamViewer. This remote machine acts as an intermediary between the developer environment and production. The code has to be copied to the remote machine and then compiled to deploy the application to AWS using beanstalk scripts. The remote machine won’t be available most of the time because the team viewer loses connectivity.
The client lacked a staging server and it made the developer’s life difficult. There was no room for testing, the testing had to be done after the client’s office hours but still, it was risky since there would be customers accessing the system.
Deployment was difficult for the developers without disturbing the live environment.
Applications were configured with git-submodules and using multiple repositories. GitHub, AWS-code commit, and NPM repositories.
For managing codes, multiple SCM tools were used, and found no proper branching strategies.
The client had no technical documentation for the AWS infrastructure and for the application stack.
There were no UAT environments configured.
New Architecture
Implementation Challenges
The upgrade from Nodev12 to Node 16 was really challenging due to dependency issues that popped up after the upgrade.
Identified dependencies:We identified all dependencies related to Node 16 migration. Around 55 individual dependencies were found to be upgraded.
Evaluate dependencies:Once the dependencies are identified, we evaluated if an upgrade will work with the existing code and other connected libraries. Also, the security vulnerabilities were also analyzed.
Package/library upgrades:After the evaluation phase was over we started with installing the main libraries/packages that are connected with API calls and database models. The application was evaluated for bugs after these primary libraries were installed. The remaining packages were individually checked and installed for compatible Node 16 versions and the application was thoroughly tested.
Upgrading the server without impacting the existing production server and minimizing downtime.
New environment:Created a new AWS Beanstalk setup, and implemented a fully functional automated, and operational Gitflow. The staging environment in Node 16 environment with CI/CD pipeline. The entire application components were separately tested for functionality and deployment automation.
After the testing is completed, the production environment was spun off with high-availability auto-scaling.
Results