Logo

dev-resources.site

for different kinds of informations.

Common and Useful Deployment Patterns

Published at
5/29/2024
Categories
architecture
webdev
deploy
patterns
Author
zeedu_dev
Author
9 person written this
zeedu_dev
open
Common and Useful Deployment Patterns

What is a deployment pattern?

A deployment pattern (Not to be confused with a design pattern) is an automatic method of deploying new features of an application to your users. But it doesnโ€™t stop there, it is possible to get extra information from a deploy of an application, butโ€ฆ. but how?

Imagine you want to test a feature of your web application, but you are afraid that it will not be liked by your users, or you want to see if this new feature increases or decreases the conversion rate of your application, which is invaluable, especially in the early stages of iteration of an application.

What can you do in these cases? The best thing to do would be to test it on a representative sample of your audience and, depending on how it responds, discard it or roll it out to the rest of the users.

Common deployment patterns

There are a number of widely used deployment patterns:

  • Monolithic deployment
  • Microservices deployment
  • Containerization
  • Serverless Deployment
  • Continuous Integration (CI) / Continuous Deployment (CD)
  • Canary
  • Features toggles
  • Blue/Green
  • A/B Testing
  • Dark launches

For this post I am going to focus on the last patterns, since they are the ones I have read the least information about on the internet. Consider that deployment patterns can be combined with each other. For example, you can perform A/B tests on your monolithic application to find the best version. Having said that, I will explain the patterns.

Canary deployment

This pattern consists of showing new features to a small group of users. After analyzing and correcting the performance of the new features and, if appropriate, the deploy is extended to all users.

Canary deployment schema

Features toggles deployment

Instead of releasing all changes at the same time, this pattern hides new features behind a switch, which can be turned on or off without modifying the code. This allows changes to be released gradually or only to certain users, making it easy to test and manage. This method has the advantage that if a problem occurs, you can turn the switch off without the need to return the code to a previous state.

Features toggles deployment schema

Blue/Green deployment

In the blue/green deployment we have two similar environments simultaneously. These environments will be known as blue and green. At any time only one of the two environments will be active, while load balancing from one environment to the other. If we find any errors we simply adjust the load balancing to the opposite side.

Blue green deployment schema

A/B testing deployment

A/B testing is the classic A/B testing; a random set of our users will receive version A of the application, while the rest will receive version B. We will then use statistics, specifically the two-sample t-test, to determine which version (A or B) is more effective.

The distribution percentage does not necessarily have to be 50-50.

A/B testing deployment schema

Dark launches deployment

This type of deployment pattern is quite similar to the Canary deployment, however in this case users must be aware that they are receiving a test version and must be aware of the new functionality being tested. With this knowledge the users will be able to provide feedback on the new functionality.

Dark launches deployment schema

Consider that many projects do not reach the necessary size for a deploy pattern to be useful, and that if your application has few users it may even be counterproductive. However, if this is not the case, you can use one or several of them to extract valuable information for your application.

patterns Article's
30 articles in total
Favicon
Streamlining Data Flow in Angular: The Power of the Adapter Pattern ๐Ÿ”„
Favicon
CQRS โ€” Command Query Responsibility Segregation โ€” A Java, Spring, SpringBoot, and Axon Example
Favicon
Mastering the Container-Presenter Pattern in Angular: A Deep Dive
Favicon
Repository Design Pattern, Promoting Packages via ADS, and New Arabic Article โœจ
Favicon
Flexibilidad y Escalabilidad: Usando Strategy y Factory Patterns
Favicon
Understanding Domain Events in TypeScript: Making Events Work for You
Favicon
Padrรตes de Projeto em React [HOCs, Render Props, Hooks]
Favicon
Mobile Development Platforms and software architecture pattern in mobile development
Favicon
Finite-state machine example in JavaScript
Favicon
OOP Simplified: Quick Factory Methods with Encapsulation, Abstraction, and Polymorphism in TypeScript
Favicon
Finite-state machine example in JavaScript
Favicon
How to avoid N + 1 and keep your Ruby on Rails controller clean
Favicon
Types Of Software Architecture
Favicon
Testando das trincheiras: Usando um "clock" fixo
Favicon
ยฟPOR QUร‰ no estรกs usando estos providers de Angular?
Favicon
Common and Useful Deployment Patterns
Favicon
Reusing state management: HOC vs Hook
Favicon
Understanding JavaScript Creational Patterns for Object Creation
Favicon
Understanding Design First: Principles, Patterns, and Best Practices Explained
Favicon
The Architecture Might Not Be the Problem
Favicon
Padrรฃo JumpTable com Javascript
Favicon
Explorando os Fundamentos dos Padrรตes de Projeto: Conceitos Bรกsicos
Favicon
Six Factors That Raise The Risk Of Bugs In A Codebase
Favicon
Microservices: Avoiding the Pitfalls, Embracing the Potential - A Guide to Anti-Patterns
Favicon
Android Presentation Patterns: MVI
Favicon
Entendendo o Pub/Sub com Javascript
Favicon
The Consumer Conundrum: Navigating Change in Microservices Without Gridlock
Favicon
๐—ช๐—ต๐—ฎ๐˜ ๐—ฎ๐—ฟ๐—ฒ ๐˜๐—ต๐—ฒ ๐—ฅ๐—ฒ๐—ด๐—˜๐˜… ๐—ฃ๐—ฎ๐˜๐˜๐—ฒ๐—ฟ๐—ป๐˜€?
Favicon
Using a Trait in Builder CLIs
Favicon
CLI Contexts

Featured ones: