I’ve blogged about my attempts to understand the cost structure of serving (publicly over HTTP) large amounts of small files from Azure Blob Storage (or CDN for that matter). Ad exchange network for Windows Phone 7 helping developers promote their apps for free by helping each other.
The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway. CloudWatch is an AWS component for monitoring resources and services running on AWS, setting alarms based on a wide range of metrics, and viewing statistics on the performance of your resources. Receiving an unpleasant surprise in the form of a large bill at the end of the month is disappointing and stressful.
For example, it is easy to misconfigure a Lambda function and inadvertently allocate 1.5GB of RAM to it. In the main AWS console, click your name (or the name of the IAM user that's representing you) and then click Billing & Cost Management. Click Preferences in the navigation panel and then enable the checkbox next to Receive Billing Alerts.
Figure 1: The preferences page allows you to manage how invoices and billing reports are received. Click the Create Alarm button in the lower right-hand corner to open the Create Alarm dialog.
Figure 2: It's good practice to create multiple billing alarms to keep you informed of ongoing costs. Services such as CloudCheckr can help to track costs, send alerts, and even suggest savings by analyzing services and resources in use. Figure 3: CloudCheckr is useful for identifying improvements to your system but the good features are not free. AWS also has a service called Trusted Advisor that suggests improvements to performance, fault tolerance, security, and cost optimization. Cost Explorer (figure 4) is a useful, albeit high-level, reporting and analytics tool built in to AWS. Figure 4: The Cost Explorer tool allows you to review historical costs and estimate what future costs may be. The Simple Monthly Calculator is a web application developed by Amazon to help model costs for many of its services.
You can click common customer samples on the right side of the console or enter your own values to see estimates. Figure 5: The Simple Monthly Calculator is a great tool to work out the estimated costs in advance. The cost of running serverless architecture often can be a lot less than running traditional infrastructure. Amazon's pricing for Lambda is based on the amount of requests, duration of execution, and the amount of memory allocated to the function. Amazon provides a perpetual free tier with 1 million free requests and 400,000 GB-seconds of compute time per month.


As an example, consider a scenario where you have to run a 256MB function five million times a month. The total billable amount of GB-seconds for the month is 2,100,000 (2,500,000 GB-seconds - 400,000 free tier GB-seconds = 2,100,000). It was more complicated than it had to be and I’m still not sure I understand the reasoning behind it, but at least the answer was clear – you pay for both bandwidth and transactions if you serve files publicly from Azure Blob Storage. When you begin to build your serverless system, you are likely to use logging more than any other feature of CloudWatch. CloudWatch can create billing alarms that send notifications if total charges for the month exceed a predefined threshold. The function might not do anything useful except wait for 15 seconds to receive a response from a database. Unfortunately, the free version of Trusted Advisor is limited, so if you want to explore all of the features and recommendations it has to offer, you must upgrade to a paid monthly plan or access it through an AWS enterprise account. You must activate it first by clicking your name (or the IAM user name) in the top right-hand corner of the AWS console, selecting Cost Explorer for the navigation pane, and then enabling it. This tool allows you to select a service on the left side of the console and then enter information related to the consumption of that particular resource to get an indicative cost.
Naturally, the cost of each service you might use will be different, but we can have a look at what it takes to run a serverless system with Lambda and the API Gateway.
Note that Amazon prices may differ depending on the region and that they are subject to change at any time. This means that a user can perform a million requests and spend an equivalent of 400,000 seconds running a function created with 1GB of memory before they have to pay. The API Gateway pricing is based on the number of API calls received and the amount of data transferred out of AWS. It will help to track and debug issues in Lambda functions, and it's likely that you will rely it on for some time. This is useful, not only to avoid unexpectedly large bills, but also to catch potential misconfigurations of your system. In a very heavy-duty environment, the system might perform 2 million invocations of the function a month costing a little over $743.00. Figure 5 shows a snippet of the Simple Monthly Calculator with an estimated monthly cost of $650.00. The edge location traffic distribution is 30% for US and Europe, 15% for Japan, and 25% for Hong Kong, Philippines, South Korea, Singapore, and Taiwan. Duration is based on how long the function takes to execute, rounded up to the nearest 100ms. It's worthwhile to attempt to model how many requests and operations you may have to handle on an ongoing basis.
Its other features, however, will become important as your system matures and goes to production. Amazon charges in 100ms increments while also taking into account the amount of memory reserved for the function.


If you expect 2M invocations of a Lambda function that only uses 128MB of memory and runs for a second, you will pay approximately $0.20 month. If you perform cost calculations up front and have a sensible billing alarm, you will quickly realize that something is going on when billing alerts begin to come through. Initially, you may not see any information, because it takes 24 hours for AWS to process data for the current month. It is a complex tool and it's not without usability issues, but it can help with estimates. If you expect 2M invocations of a function with 512MB of RAM that runs for five seconds, you will pay a little more than $75.00. With Lambda, you have an opportunity to assess costs, plan ahead, and pay for only what you actually use. Finally, don't forget to factor in other services such as S3 or SNS, no matter how insignificant their cost may seem to be. This could be design elements of your site, your CSS or JavaScript files or small banner ads (in my case).
CDN would probably be a more appropriate solution for these scenarios, but the pricing structure and costs (more on this later) are identical so it doesn’t matter in this context. I understand that storage space costs something, I understand that bandwidth costs something, but I don’t understand where is the cost of “transaction”. It looks just like a HTTP request to me and for some odd reason I don’t get billed for HTTP requests to my web roles, huh? Does it cost Microsoft twice as much to serve 700gb in 7kb files than 700gb in 700kb files? I was pretty sure that we’ve researched that option and there was a transaction cost too, but who am I to argue with 2 Azure MVPs ;) Back home I’ve checked that I was right and that there is a very good reason why they thought otherwise. When you hover the “?” you start getting some hints: And only when you click the “Learn more” link it becomes crystal clear: So, WTF do you want, Alan!?
I don’t care how big margins on the bandwidth prices are as long as the end price is competitive. Why are public HTTP requests to the Blob storage billed and HTTP requests to the Web Role are not?
I know it looks like a rant, but I just want to make the product better and provide feedback from the average customer’s point of view. This cost structure makes Azure and Amazon CDN (and storage) services unattractive to projects serving large quantities of small files and I’m just not sure that there’s a good reason for Microsoft and Amazon to shut these customers out.



Most secure cloud storage device
Free internal storage kindle fire modelos


Comments

  1. 16.02.2014 at 14:23:14


    Store it to the camera roll on your device, which available, but not all storage simply short video.

    Author: sindy_25
  2. 16.02.2014 at 23:58:57


    Today, dependence on services from a cloud service provider can bring new.

    Author: 45345
  3. 16.02.2014 at 12:28:53


    You can then select the appropriate.

    Author: Pantera
  4. 16.02.2014 at 12:53:27


    Teamplace because the photos of his.

    Author: AVTOSHKA
  5. 16.02.2014 at 12:50:46


    High-speed network connections around the globe that's only true for mobile photo backup.

    Author: PLAY_BOY