Preface
I've been shopping around for cloud based hosting solutions, particularly MS Azure & Amazon's EC2. They, Microsoft and Amazon, have pricing tables which describe a "cost/hour"/"compute hour."
Question
When they say "cost/hour" or "compute hour," what's in an hour? Is it the amount of time an application pool, in the case of an ASP.NET app, is active? Or, the amount of time that your application is active? Or, is it related in some manner to the incoming requests per hour/minute?
Is there a possibility that if the app is not active (serving requests) it's not factored into the overall cost calculation, thus reducing the overall "compute time"?
The Azure Hour for Education is a Teams meeting that happens every Friday at 11am PST. Join in the conversation and let us know if there is anything that piques your interest or something you would like to learn more about.
Azure compute services are the hosting services responsible for hosting and running the application workloads. These include Azure Virtual Machines (VMs), Azure Container Service, Azure App Services, Azure Batch and Azure ServiceFabric.
Good answers by David and Mike. Let me add a bit: Rather than thinking in terms of apps, think about virtual machines. When that virtual machine is spun up (even in a stopped state, the virtual machine is allocated), you're being charged. You can easily start and stop apps within that virtual machine instance: Maybe it's a web application, background rendering process, whatever. Whether you're burning 0% CPU or 100% CPU, you're paying in clock-hours for that virtual machine.
Note that even with Cloud Services (web and worker roles), you're ultimately dealing with virtual machines. Each instance of a web role or worker role is its own Windows Server virtual machine.
Oh, and same goes for Web Sites reserved instances.
Regarding your question of switching an application off to save billable hours: If, say, you have a nightly process that runs for maybe an hour or two, then consider placing that process in its own Cloud Service (or Virtual Machine). When the time comes to run it, deploy it to its named slot (yourname.cloudapp.net), let it run until the task is done, then delete the deployment. Now the virtual machine instances hosting your process runs for 2 hours, not 24. What you can not do is reduce the count of a web or worker role to zero. So if you have, say, a web role with 2 instances and a worker role to do some nightly stuff, you cannot set the count to zero worker role instances upon completion of the task. That's why I suggested placing the nightly task in its own deployment.
EDIT Things have changed a bit since over the past few months. In particular, the following was announced in June 2013:
You can read ScottGu's blog post about the per-minute and stopped-VM updates here.
An hour counts as the time your app is deployed (running or not, being accessed or not). An hour is a 'wall clock' hour - meaning if you deploy at 10:45am and deleted at 11:05am, you are charged two hours (the 10 o'clock hour and the 11 o'clock hour).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With