Database Migration of Bro4u
Published Date :
Bro4u.com is an e-commerce platform that provides its clients with personalized home and professional services. Through its platform, Bro4u.com eliminates the difficulties in finding a relevant vendor for a service.
Bro4u.com was launched in 2015, the platform aims to extend its services to other cities across India.
In 2015, the year Bro4u was founded, a report from the Internet and Mobile Association of India (IAMAI) estimated that the number of Internet users was going to reach 402 million by December 2015. In February 2016 IAMAI likewise reported that the number of mobile Internet users in the country would increase by 55 percent to 371 million by June that year.
Bro4u is an online marketplace, founded in 2015. Based in the city of Bangalore, the capital of the Indian state Karnataka (frequently nicknamed the “Silicon Valley of India”), the startup company – which describes itself as a “ecommerce marketplace for services” – has plans to expand onwards to amongst additional places Hyderabad (capital city of Telangana) and Pune (second largest city in Maharashtra), according to The New Indian Express. The core idea of the company consists of providing for the exchange of both household and professional services, for example from tradespersons like plumbers, electricians and cleaners, amongst others.
Bro4u Online Service Pvt Ltd was running its infrastructure on traditional way. But sudden traffic of users per second and unpredictable spikes in traffic, it became difficult to run the infrastructure efficiently. To support reliability, increase agility and reduce management complexity, the company migrated its entire solution from a on prem to Amazon Web Services (AWS).
On prem solution was limited to usage & no scalability or availability. It had major downtime impact faced by the end customers due service unavailability at sometimes. So, to overcome this there was a need of a solution which would meet the business requirements as reliability, availability, security & most imp the cost, so here the Amazon RDS Aurora comes to rescue.
Database service used on AWS is Amazon Aurora RDS, which is highly available, fully managed RDS service offered by AWS.
Also, as RDS Aurora is MySQL & PostgreSQL compatible it was decided to shift to amazon aurora.
WHY AMAZON WEB SERVICES:
Bro4u chose Amazon Web Services due several services offered by AWS which are mentioned below. Also, reliability, availability, latency, security etc. were the factors included with these services.
- Networking – VPC, Security groups, NACL, Subnets etc.
- Databases such as DynamoDB managed service by aws
- Compute services – Amazon ec2
- For high availability – Autoscaling, latency, read-write node for RDS.
- DR – Multi AZ etc.
Aws turned to be a perfect solution to host the app & minimize the infrastructure cost. The support offered by AWS is admirable. The quick resolution helps to reach commitment easily and business grows.
AWS provide documents to help maintain the security at best level.
Amazon RDS is managed database services that provides six different DB engines. These are including Amazon Aurora, MySQL, MariaDB, Oracle, Microsoft SQL Server, and PostgreSQL. Current requirement was MySQL compatible DB so RDS Aurora is selected.
Amazon RDS performs the routine task such as patching, backup, failure detection, etc.
With RDS it easy to use replication to enhance availability and reliability for production workloads.
Some key features offered by Aurora MySQL are the following:
- High throughput with low latency
- Push-button compute scaling
- Storage autoscaling
- Custom database endpoints
- Parallel queries for faster analytics
Apart from this there are several benefits received in terms of customer trust, ability to withstand the customer needs, scalability, & cost efficiency resulting more customers more business.
The databases cost up to 600$ which is way more less than that the actual investment on prem, also the cost optimization strategies applied help the customer to reduce the billing from 2000$ to 700 $ for all RDS related activities. This can be seen as cost reduction & business benefits.
So now the developers, testers are able to focus on other important things rather than struggling with the limitations.
Strategies applied to Migrate Database
AWS Database Migration Service (AWS DMS) is a service that makes it easy to migrate RDS, NoSQL or other types of databases to AWS with minimum downtime.
Also, if you want to change database engines, you can use the AWS Schema Conversion Tool (AWS SCT) to translate your database schema to the new platform
Basically, migration of database is replication process where we specify the source and target and the data is moved between those.
The migration process:
The Migration process helps customer migrate thousands of applications on cloud. Here we needed the migration process for Databases. If you want to Migrate your databases to AWS with minimal downtime DMS is the option.
If we discuss the High-level view of AWS DMS following things
As shown in the diagram below the process of Migration is consist of following things.
- Replication process which is carried out by Replication instance.
- Needs the endpoints for source & destination Databases.
- And then we can create migration task to get the data moved from source to destination.
The migration task includes:
- Loading the existing Data
- Replicating the cache changes
- Ongoing replication
AWS DMS first create the schema to replicate the given data on to it. Also, there are two types in migration process i.e. Homogeneous or Heterogeneous migration.
In homogeneous migration the process above is done whereas in heterogeneous migration the SCT tool used to convert the complex schema on target DB.
The SCT (Schema Conversion Tool) is used the generate the schema on target Databases before the actual migration is processed.
Components of AWS DMS:
The basic components involved in DMS are as discussed below.
- Replication Instance:
At high level the replication instance is nothing but the Ec2 instance which carries responsibility of replication on cloud Target Database. Which is launched at time of deploying DMS.
The above diagram shows the overview of process.
This one instance can handle multiple replication tasks, you get to select the type of instance.
But also, along with that it is important to know the size of the replication instance to be considered as it decides the performance of replication process, so as the cost.
In this situation database was of huge size as compared to normal hence the required suggestion considered. And the downtime of a day or two was estimated. But as the DMS comes with some customizations it was easier to understand and follows the best practices. Security factors considered and access limitations decided
We selected the c4 type of instance to handle the load with good performance.
- Source & Destination endpoints:
Endpoints are used by DMS to connect the source and destination DBs. These endpoints can be source or target. While giving the endpoints information we specifed the following details.
- Types of engine i.e. MySQL, PostgreSQL etc.
- Types of endpoints
- Server name
- Credentials etc.
- Replication Task:
Replication task basically moves the datasets from source endpoints to the target endpoints.
While initiating the task we do following things.
- Specify the instance on which this task will run.
- Source endpoint
- Target endpoint
- & Migration type. Etc.
The full process is easier to understand, the data is collected from sources database & stored on to the target database.
Here the process of migration used is Homogeneous. Bro4 had the privet server hosting the database compatible with MySQL. Hence on AWS the obvious choice was to get the MySQL compatible Database i.e. Amazon Aurora.
Current database hosted for the Bro4u is RDS aurora which runs website & is highly available.
Benefits of AWS
- Migrated from on-prem to AWS in a few days with minimal downtime.
- Increased the number of users that could be served simultaneously & without any service delay.
- Provided greater visibility into service health and user experience with real-time feeds. Users were able to get the services they seek.
- Reduced time for users to get services slots availability on time.
- Improved data search performance by 30% on Amazon Aurora Database
Need help with your cloud?
"No worries! Our experts are here to help you. Just fill the form and we'll get back to you shortly!"