Questions tagged [azure-web-roles]

A Microsoft Azure Web Role is a Windows Server Compatible Virtual Machine (VM) with IIS enabled, along with scaffolding code that provides a launch point for your own code to run within the VM.

Web Roles and Worker Roles form the basis of the Azure Cloud Services PaaS offering, removing the need for developers to manage the platform on which their applications will run.

The primary difference between a Web Role and Worker Role is the enabling of IIS. Both Web Roles and Worker Roles may run the same code, though it's often useful to split code between different roles for scaling purposes.

Within Visual Studio, you'll also see a slightly different role template, but the 4 primary events/overrides are available in both:

  • OnStart()
  • Run()
  • Stopping()
  • OnStop()

Further: If apps need to be installed (or registry changes are needed), and those tasks need elevated privileges, there's the ability to run startup tasks, which execute prior to OnStart().

In either roles you can choose the type of operating system running by modifying the service configuration file (.cscfg). Possible options are:

  • osFamily 1: equivalent of Windows Server 2008 SP2 x64
  • osFamily 2: equivalent of Windows Server 2008 R2
  • osFamily 3: equivalent of Windows Server 2012
  • osFamily 4: equivalent of Windows Server 2012 R2

You can read more about service configuration schema here.

1139 questions
5
votes
1 answer

Ignore Endpoints from Azure Application Insights

I have enabled Traffic Manager and the Monitoring Settings on my web role, now my Application Insights usage is completely unusable (11K impressions in a 24 hour period from Internet Explorer or Windows NT) and marks it as "real user traffic"? Smh.…
5
votes
0 answers

Error 500.19 when debugging Azure web role on IIS Express

I have a MVC 3.0 web application running on an Azure cloud service as a web role. When debugging the application under Visual Studio 2013, if I delay too long between breakpoints, the web role shuts down and IIS Express 8.0 responses an error…
5
votes
1 answer

Does running multiple Azure Cloud Service (Web Role) instances need a Load Balancer?

If a web application is deployed as an Azure Cloud Service (Web Role) with multiple instances, should I still put a load balancer in front of its endpoints (HTTP and HTTPS)? On Azure's product page it says load-balancing it taken care by Azure…
Jim
  • 1,695
  • 2
  • 23
  • 42
5
votes
3 answers

Error 109 WAT080 : Failed to locate the Windows Azure SDK 2.1 on Visual Studio 2013

I have Visual Studio 2013 with update 3 installed. On the first time i opened my project, it prompted me to download and install Azure SDK 2.2 and so i did. When i tried to build, it fails and gives me this error message: Error 109 WAT080 : Failed…
CodeLinguist
  • 173
  • 1
  • 7
5
votes
1 answer

Could not load file or assembly 'msshrtmi' - when publishing Windows Azure Websites

I'm having an issue as below: Could not load file or assembly 'msshrtmi, Version=2.3.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. Description: An unhandled exception…
Karl Cassar
  • 6,043
  • 10
  • 47
  • 84
5
votes
2 answers

Ninject dependency for Ninject.Web.WebApi.OwinHost v3.2.x

I'm attempting to ninject ApiControllers in an Azure worker role. I've previously accomplished ninjection with the same controllers in an asp.net mvc 5 / web api 2 project in the same solution. Another non ninjected test controller in this…
Jeff Albrecht
  • 3,723
  • 1
  • 17
  • 22
5
votes
1 answer

azure table : Duplicate partition key results in (409) conflict

I am trying to insert multiple rows into the Azure table service. As far as this article goes, I have understood the partition key to be able to store duplicates. However, while following this article, when I try to insert a duplicate partition key…
user20358
  • 14,182
  • 36
  • 114
  • 186
5
votes
1 answer

Setting Up And Using Web Deploy with Azure WebRole in Visual Studio (One-Click partial update)

I am using Windows Azure, and find it a lot difficult and useless make a new "Package" each time you make a small change, and want to test it on the Cloud. I heard about the opportunity to update the web roles without re-deploy the whole instance…
5
votes
2 answers

Azure MVC Web Role does not use CSS when run under development fabric

When I run either application itself or Azure deployment from Web, my pages are rendered using CSS, but when running the Web role under local fabric, I get plain "no-CSS" style pages. I have two questions: Anybody knows why does it happen? What is…
Sergey Aldoukhov
  • 22,316
  • 18
  • 72
  • 99
5
votes
1 answer

Web API on Azure errors until App Pool is Recycled

I have a web role that hosts 4 MVC 4 sites. One of the sites (let's call it the API site from now on) uses both MVC and Web API. When I upgrade the web role, the Web API controllers from the API Site returns a 500 Internal Server Error to all…
knightpfhor
  • 9,299
  • 3
  • 29
  • 42
5
votes
2 answers

Azure Cloud Service deployment without changing existing configuration

Is it possible to deploy a Cloud Service without changing existing configuration? What i want to do is to deploy a Cloud Service package to the Dev Cloud Service and then take the same package and upload it to the Production Cloud Service. Any…
Uri Abramson
  • 6,005
  • 6
  • 40
  • 62
5
votes
1 answer

Which version of Azure SDK is used on the Azure Platform?

Hi I'm really new on Azure. I've VS 2012 and Azure SDK 2.1, when I run my web application with the emulator all work fine. But when I deploy on azure I have the error message : Could not load file or assembly …
DadyFuji
  • 243
  • 1
  • 12
5
votes
1 answer

he type initializer for 'Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment' threw an exception

After moving my Azure web app to SDK 2.1 I have started getting the type initializer for 'Microsoft.WindowsAzure.ServiceRuntime.RoleEnvironment' threw an exception. error message. The same is working fine in the local environment but gives above…
iomca4u
  • 235
  • 4
  • 15
5
votes
1 answer

FluentSecurity makes Azure WebRole to fail

I have a ASP.NET MVC website using FluentSecurity. As a Azure Website it works just fine. I need to make it a WebRole. I added a WebRole project but the WebRole fails at startup with a generic "The page cannot be displayed because an internal server…
Igor Kulman
  • 16,211
  • 10
  • 57
  • 118
5
votes
3 answers

How to obtain an SSL certificate for Azure Cloud Service

I have an azure cloud service (WebRole) and I want to purchase an SSL certificate. What is the technical requirements to purchase this certificate? An SSL provider like godaddy offers 256-bit encryption certificate but Azure documentation said that…
Mahmoud Samy
  • 2,822
  • 7
  • 34
  • 78