This page describes the demo. You can find the recordings of the demo on the following page. It can be useful to download the demo video and save it locally in case the internet doesn't allow you to connect to Azure reliably, etc.
Important: Make sure to run the preparation steps first.
In this demo we will show two functionalities of the deployment slots:
- Publishing a new version of a web application without risks and without downtime
- Trying new features with A/B testing
-
Show the App service in the Azure portal.
-
In the
Overview
tab, click on the website's URL. -
Show a bit of the website's functionality
- Navigate to a category.
- Click on an item's details.
- (If needed) log into the Shopping cart.
- Click on Add to Cart.
- Navigate to the Shopping cart.
-
Go back to the Azure portal.
-
Click on
Deployment slots
. -
Explain what slots are, underline that 100% of the traffic goes to Production at the moment.
-
Go back to the website and show that there are some typos in the navigation menu.
-
Go back to the Deployment slots and explain that the typos have been fixed and deployed to the
Staging
slot. We will see later how the deployment is setup. -
Click on Swap and make sure to swap the
Production
slot and theStaging
slot.
Swapping the slots takes a couple of minutes, which we will use to show a few details about how to create slots and deploy code to them.
-
Switch to another instance of the Azure Portal, to avoid interfering with the swap that is currently taking place.
-
Open the App Service again in the portal.
-
Click on
Deployment slots
. -
Click on
Add Slot
and explain the process to create a new slot.- Explain that slots run in the same process, which minimizes the differences between them, and makes sure that we have very similar environments to test into.
- Explain that the settings can be different between slots and show how to clone them.
- Close the drawer without saving.
-
Click on the
Staging
deployment slot. -
Show the
Configuration
, illustrating that every slot can have different settings. -
Click on
Deployment Center
. -
Show that this deployment comes from a branch named
Typos
, and explain that there are different ways to deploy to a slot, either with CI/CD or directly from Visual Studio, etc. -
Go back to the previous window where the swap was taking place. Show that it is completed now.
-
Go back to the website, and refresh the page. Show that the typos are fixed now.
-
Log into the shopping cart and then navigate to it. This should start throwing a lot of errors, because this slot's connection string to the CosmosDB database has been mangled during the preparation.
-
Click on the Back button to stop the errors and wait for them to disappear. Then log off the shopping cart.
-
Go back to the
Deployment slots
, and click on theSwap
button again. Explain that getting back to the version with the typos but where the shopping cart was working is as simple as a click on theSwap
button, and the previous version can be set again in just a couple of minutes. This is a peace of mind when deploying a new version.
Show that the error could have been caught, because it is visible that the settings changed between the
Production
and theStaging
versions.
- In the
Deployment slots
menu, click on theAbTest
slot.
If you cannot click on the deployment slot name as a link, it's probably because you are within a slot in the portal. To go back to the production slot's portal, you can use the navigation crumbs on top of the page.
-
In the
AbTest
slot, click onDeployment Center
. -
Show that the branch used here is called
AbColor
.
Explain that this is a branch where we are developing a new feature. In this case we modified the main color to be red. We now want to randomly test this new feature to gather feedback from our users.
-
Go back to the Production slot and in the
Deployment slots
page, show the Traffic again. At the moment 100% of the traffic goes to theProduction
slot. -
Change the Traffic so that 50% of it goes to the
AbTest
slot. then click onSave
. -
Go back to the website and refresh the page. Normally it should be still the old blue version becauase we're still running in the same session.
-
Open another web browser. Make sure that it is a different browser, for example Edge Dev, Edge Beta or Chrome.
-
Navigate to the same URL. If we're lucky, it should be red. If it doesn't, try with yet another browser.
Alternatively, you can also use the short link you created earlier, targeting the Tailwind Traders website. Then, ask your audience to load this short link on their smartphone. If they see the red color, they should raise their hand. Approximately 50% of the audience should have their hand raised.
Once you are done with the demos, you can clean up the resources to save money on resources.