Scale out my application in cloud, how i can do that?
i have a medium SaaS project an开发者_StackOverflow中文版d need scale out, where i can find materials to get started my cloud project?
ps: i dont want work with a PaaS, like App engine or Azure...i will use IaaS like ec2 or rackspace
I don't know from experience, but surely the service provider you're working with has some decent material to assist you? Also, I imagine the Amazon offering (and those of a similar ilk) will have good active user communities.
If you prefer to work with Iaas, Amazon EC2 offers a basic auto-scaling function that allows you to scale your server capacity according to conditions you define. Other cloud management solutions such as Scalr or RightScale provide more advanced features. These are not Paas per se, but rather services that help you manage your infrastructure on Amazon, Rackspace and other providers. Depending on what you are looking for, EC2 auto-scaling may or may not fulfill your requirements.
Here is an example to understand how things work differently between EC2 and Scalr auto-scaling (I do work at Scalr):
Let's say you have three web servers, and each one should handle 1000 concurrent users at least, otherwise they should be terminated. At 4am, your traffic is slowing down, and you only have 2100 simultaneous users, so 700 per server. This is below your threshold, so a downscaling event is triggered.
With EC2 auto-scaling, one of the three servers will be terminated. This means that the 500 users that were on the server will have their connections closed, and be logged out (if you use file-based sessions, very common with PHP and other languages).
Scalr handles downscaling differently. Before terminating a server, the OnBeforeHostTerminate event is triggered: it allows you to perform maintenance actions to prepare the server for being terminated. Furthermore, Scalr uses the web server's safe shutdown method, so no new connections are made. It waits until all the connections are closed to terminate the server. Another difference, unlike EC2 auto-scaling, Scalr allows you to scale based on CPU, RAM, Disk, Network, users...
As for Rackspace, I do not think that they have an auto-scaling feature. However, if you would like to build your infrastructure on Rackspace rather than Amazon, you can still use Scalr to manage your servers and scale your capacity automatically.
As I said earlier, it depends on your requirements.
Not sure what you mean by "scale out", but maybe you mean automatic scaling, load balancing or something like that?
Amazon have services that you can add to your EC2 account to do that (Auto Scaling, Amazon CloudWatch and Elastic Load Balancing), or you could use third party tools such as Scalr to manage it all for you. We are evaluating Scalr for our needs at my day job but I have no experience of it just yet.
精彩评论