Monday, February 4, 2019

Web App Deployment in Azure



Azure App Service Web Apps (or just Web Apps) is a service for hosting web applications, REST APIs, and mobile back ends.

Web Apps has,
You can also take advantage of its DevOps capabilities, such as continuous deployment from Azure DevOps, GitHub, Docker Hub, and other sources, package management, staging environments, custom domain, and SSL certificates.

You can scale up or out manually or automatically. App services are ISO, SOC and PCI compliant.

In Azure apps runs in an App Service plan. It defines set of compute resources for a web app to run. These resources are much analogues to a server farm.

Pricing tiers (Hosting plans in depth)

Shared compute (Free and Shared): Runs on same Azure VM as other App service apps. These resources cannot scale out- Intended only for development and testing

Dedicated compute (Basic, Standard, Premium and Premium V2) runs on dedicated Azure VMs. Only apps in same App Service plan share the same compute resources. Higher the tier, the more VM instances are available to you for scale-out

Isolated : Runs on dedicated Azure VMs on dedicated Azure Virtual Networks, provides network isolation on top of compute isolation to your apps. Provides maximum scale-out capabilities.

Consumption: Only available for function apps. Scales the functions dynamically depending on the workload.

Except Free and Shared tiers (which cannot scale out), if multiple apps are in same App Service plan, they all share same VM instances.

Azure - Comparison of Web hosting options

Azure offers several ways to host web sites: Azure App Service, Virtual Machines, Service Fabric, and Cloud Services. Azure even supports Azure dedicated hosts where you can configure to use a single physical machine for all your applications and servers in Azure.
https://docs.microsoft.com/en-us/azure/app-service/choose-web-site-cloud-service-vm

Deploying Web Apps from Visual Studio

You can directly publish to Azure Web App from Visual Studio using publish tool. When you give azure subscription details and web app you want to publish to, Visual Studio will directly publish the files to the web app. Kudu is the engine behind git deployments in Azure.

If you had hosted a web app with a previous version, when upgrading you'll run into Cannot find compilation library issue which can be solved by clearing wwwroot folder

Azure Web Apps carries capability to scale up (More CPU, memory disk space) as well as Scale out (Increase number of VM instances).

Monitoring Web Apps in Azure

There are few tools Azure provides to monitor web apps in Azure. You can define rules which gets triggered based on a condition such as spikes in request count, CPU usage etc.


You can also monitor Metrics in Azure. It gives real-time overview of how the application behaves in different metrics.



Logs are important in any web application to see what kind of errors, warnings applications gives when running. App service logs and Log stream helps you seeing these. You can configure these in App service logs to view in Azure itself via. Log stream or upload it to storage of file system.


Process explorer is not frequently used feature which enables us to see currently running processes.

Running Performance Tests in Azure Web Apps

Azure Web Apps allows you to run performance tests.


But theses performance tests are now deprecated. There are few reasons why cloud based load testing is reaching end of life due to how practical and pragmatic load testing are. Therefore performance tests in Azure is reaching end of life.

Deciding correct Azure compute service



Web Apps in AWS - EC2

AWS carries option of Amazon EC2 for app deloyment. You can deploy ASP.NET Core 2.0 apps in AWS

Powered by Blogger.


Software Architect at Surge Global/ Certified Scrum Master

Experienced in Product Design, Software Engineering, Team management and Practicing Agile methodologies.

Search This Blog

Facebook