Web Application

A Look at the Uber Microservices Architecture

author

Sayone technologiesAugust 16, 20217 min read

article img

Generative AI Revolution: Unlocking Opportunities for Modern Companies

Table of Contents

Generating table of contents...

Microservices architecture systems are much discussed in today’s times. Many large enterprises in the world have seen enormous success after the adoption of microservices. These organizations meet their scaling and agility goals easily by adopting microservices.

While the main premise of this article will be the discussion of the Uber microservices architecture, we will also discuss the key concepts that govern the microservices architecture and the pros and cons of this software system framework.

Definition of Microservices Architecture

Definition of microservices architecture
Microservices is a software architecture system that consists of small independent services, each of which performs a business function. Each of the independent business services is built on a technology stack that is most suited to the function.

Download Ebook for FREE "How to choose the best microservices vendor and trim the cost"

In a monolithic software architecture system, a large piece of cohesive code carries out all the functions. The code is tightly coupled together and is difficult to untangle. Though a monolith carries out a number of functions, adding new code or modifying existing code can be a burden. With more upgrades, the coding becomes more complicated till it becomes impossible at one stage. 

Microservices Architecture-Key Concepts

Microservices architecture-Key concepts
Before designing a microservices system, it is vital to have a clear understanding of the scope of the services and the functionalities of the application at hand.

Main Design Guidelines for Microservices

  • First, the domains should be separated and each business function should be clearly understood.
  • Each of the microservices that you plan to have should have only a single functionality.
  • The entire application should be designed in a manner so that it is possible to deploy each service independently.
  • Inter-services communication should take place via a stateless server.
  • Each service can be factored down into smaller services, each one with its own microservices.

What does it take to seal the many vulnerable points in the microservices architecture?

Read our blog, "Microservices Architecture Security Best Practices and Patterns" 

Microservices Architecture

The components of the microservices architecture can be briefly described as follows:

Clients: The architecture has different types of clients with different management functions, such as build, search, and configure, among others.

Identity Providers: They authenticate client requests and pass them to the internal services via an API gateway.

API Gateway: This is the entry point for clients to send requests to specific microservices. The advantages of doing this include the ability to update services without letting the clients know, the ability of the services to use message protocols that are not web-friendly, and making use of the ability of the gateways to provide cross-cutting functions such as load balancing and providing security.

Download and read our ebook "Porting from Monoliths to Microservices – Is the shift worth it?"

Messaging Formats: The API gateway uses both synchronous (REST and HTTP) and asynchronous (AMQP, STOMP, MQTT) message formats to communicate.

Databases: Each of the microservices has its own database to capture the data and implement the business function. The databases of a microservice are updated via their service API only.

Static Content: Once the microservices communication is over within the services themselves, the static content is then delivered to cloud-based storage. This is delivered to clients via CDN systems. 

Management: The management component balances the services on nodes and identifies failures.

Service Discovery: This acts as a guide to the microservices to ascertain the communication route between the services. Basically, it maintains a list of the services that have nodes located on them.

Microservices Architecture – Pros and Cons

Microservices Architecture – Pros and Cons
Pros:

  • Microservices allow the freedom to use different technologies for different services.
  • Software release cycles are shortened.
  • The microservices architecture system ensures the security of every service.
  • Each of the services can be individually deployed.
  • Each of the microservices accomplishes a single business function.

Cons:

  • There are more troubleshooting challenges that can occur.
  • Configuration and related operations take more time.
  • Maintaining transaction safety is a challenge.
  • It is difficult to track data across different service boundaries.
  • It is also difficult to move code across the different services.
  • Remote calls can cause increased delays.

How Does Microservice Architecture Work?

Microservice architecture is an architectural style in which an application is composed of multiple services. Each service is autonomous and communicates with other services through a well-defined interface. Services are built around business capabilities, and they are independently deployable, scalable, and maintainable. Each service can be written in different programming languages and can use different data storage technologies. Microservice architecture makes it easier to maintain and extend applications because services are modular and can be replaced or modified independently. This also makes it easier to scale applications up or down, as individual services can be scaled independently.

Uber’s Transition into Microservices

Just as many other start-ups do, Uber first started off with a monolithic software architecture framework in place. However, this system was initially manageable as it took care of the cab hailing operations inside a single city.

Are you looking to outsource microservices development? Call us today!

However, Uber soon started expanding their operations worldwide and the problems started. The scalability and continuous integration aspects were soon affected.

Uber’s Previous Software System Architecture Worked in this Manner:

  • The passenger and driver are connected via a REST API.
  • Three adapters with an API within them performed the billing, sending messages, and payment actions.
  • All the data was stored using a MySQL database.

All the different functions, such as passenger/trip/driver management, billing and payments, notifications, etc., were all composed within one framework.

Challenges Faced by UBER

These were the main problems faced by the monolithic software framework that UBER worked with.

  • To update even a single feature, every feature had to be built again, deployed and tested many times.
  • Fixing bugs became a very difficult job as there was only a single codebase, and developers had to change the code in this repository again and again.
  • Scaling any feature together with the introduction of new features over many countries is getting to be very tough.

Solution

UBER decided to follow in the footsteps of other big giants like Amazon and Netflix and transition into microservices architecture. This meant multiple codebases from a single one and each of the microservices constructed to manage a single business function.

Read our blog "How to find the best microservices development company"

The introduction of the API gateway connected passengers and drivers. Similarly, from the gateway, other internal points, such as passenger/driver/trip management, and other internal points are connected.

All the units are designed to perform their functions independently.

Every feature could be scaled independently of the other. As an example, the number of people searching for taxis is greater than the number of people that actually book the cab services and make the payments. This also means that the number of processes that handle passenger management is greater than the number that manages the payment processes.

UBER broke down its monolith into cloud-based microservices for each of the functionalities and connected these via an API gateway.

UBER Microservices Architecture – Benefits

  • Individual development teams were assigned ownership of specific services which helped to boost the quality, speed, and manageability of new module development.
  • Teams were allowed to focus only on the services that needed scaling, and this helped to scale at high speed.
  • Individual services could be updated without disrupting any other services.
  • Fault tolerance has become more reliable.

Conclusion

The UBER microservices architecture shift paid off well for the company. The company then went on to develop and implement global standards that have been of great help to organizations that followed in their footsteps.

Are you looking for top-rated microservices development for your organization? We, at SayOne Technologies, can help you!

blog-contents

Subscribe to our Blog

We're committed to your privacy. SayOne uses the information you provide to us to contact you about our relevant content, products, and services. check out our privacy policy.

Sayone technologies's profile picture

Sayone technologies

About Author

Fuelling Happiness.

Robot
Ring

Get in touch

We collaborate with visionary leaders on projects that focus on quality and require the expertise of a highly-skilled and experienced team.

Detecting your location for country code...
Phone