Jump to content

User:Nuqing/sandbox

From Wikipedia, the free encyclopedia

Blue Green Deployment

[edit]

Definition

[edit]

Blue-green deployment is a strategy that can be utilized by developers for deploying software in a production environment. Blue can be one particular production environment whereas green can define an identical production environment. Typing blue-green deployment in Google, autocomplete will return words such as pattern, aws, wiki, Wikipedia, database, IIS, Tomcat and cloud foundry.

According to the Pivotal Documentation v1.5.0.0, “Blue-green deployment is a release technique that reduces downtime and risk by running two identical production environments called Blue and Green.” [1]

Scope of Blue-Green Deployment

[edit]

(*I'm a little confused about what to write in this part)

Principle

[edit]

1. Two environments need to different but as identical as possible, so they are easily switchable. Therefore one of the environment can function as a backup when the other is live.

2. When green environment is where the new release if the software take place, fully test the green environment and make sure it work before switch from blue to green.


Benefit

[edit]

1. Minimizer downtime by simplifying the cut-over as a single act of switch the router;

2. Providing developers a fast way to rollback, because one of the environment always serve as the backup of the other

3. Allows developer to test disaster-recovery(*I don't understand what disaster-recovery means but basically developers can test as crazy as they want?) procedure on every release

Usage

[edit]

(*I'm thinking put Usage in here and put all the information about Aws, tomcat and iis etc here, but maybe change the section name 'usage' into another word like 'Implementation'?)

Aws: In a traditional environment, since two versions of the same software often run in the same server, the environment should always be prepared for switching from two version. Therefore developers should be extra cautious when they update their production environment as it may cause problem when reverting the server between two version.

[AWS] [Tomecat]

Challenge

[edit]

How to handle database in blue-green deployment is one of the biggest issues: Sometimes a new release of software involves changes in the schema of the database. Two separated databases, one serving as the other’s duplicate version can cause a lot of trouble in database migration. To implement blue-green deployment, those changes have to be done in a way that can keeps the database’s behavioral and informational semantics not only for the new but also the old version application. It is important that all the deployment and test process for the database refactory is done before deploying the new software, therefore to retain the consistency of database and also a backup for switching between blue and green environment.

  1. ^ "Pivotal Documentation v1.5.0.0" located at http://docs.pivotal.io/pivotalcf/devguide/deploy-apps/blue-green.html Retrieved Sept 5, 2015