Cloud programming and help you choose a good structure

How can I write a cloud computing application? for example, an application that takes advantage of cloud deployments. Is it the same as application or vps / dedicated server? if not, what are the differences? are there any design changes? What procedures should I take if I need to transfer the application to the cloud?

I’m also going to implement the idea of ​​a web application that will require features such as security, performance, caching and, more importantly, for free. I compared some frameworks and found that django has the least RAM / CPU usage and works fine in prefork + threaded mode, but I also read that django-based sites stop responding with a huge load on connections. Other frameworks I've seen / know are Zend, CakePHP, Lithium / Cake3, CodeIgnitor, Symfony, Ruby on Rails ....

Therefore, I would leave this to your opinion, offer me a good free structure based on my needs.

Finally thanks for reading the essay;)

+4
source share
3 answers

I feel that a matrix moment is coming ... "What is the cloud? A cloud around us, a prison for your program ..." (what? C.Kh. said, bring your sense of humor ...)

Ok so serious, what is a cloud? It depends on the implementation, but the usual features include a scalable computing resource and a processor hour charge, storage area, etc. So yes, this is a bit like development on your VPS / regular server.

As I understand it, the Google App Engine allows you to consume as much as you want. Internal resource management is done by Google and billed to you, and you pay for what you use. I believe that even a free threshold.

Amazon EC2 provides an API that actually allows you to add instances of a virtual machine (someone corrects me if I am mistaken), having previously configured them, deploy another instance of your web application, talk between private IP ranges, if you want ( slicehost definitely allow this is). In this way, EC2 can allow you to act as a giant front-end load balancer, transferring work to a variety of virtual machines on the rear panel, or publishing it all publicly. I am not sure of the details because I did not create the system, but I understand how I understand it.

I have a feeling (but I know least about Azure) that on Azure, resource management is done automatically, for you, Microsoft, based on what your application uses.

So, in general, a cloud is two different things, depending on which cloud you choose. EC2 seems to provide an API for resource management, GAE and Azure are environments that grow and shrink in the background based on your usage.

Note. I know that there are certain limitations in GAE, especially with Java. In a minute I will edit in another thread, where someone made a wonderful comment on one of my posts with this effect.

To change , as promised, see this topic: Cloud agnostic architecture?

As for the choice of structure, it really doesn't matter as far as I know. If you are planning to deploy on one of these platforms, you can check the availability of the framework / language. I personally just started Django and love it, having learned python some time ago, so in my completely impartial opinion, use Django. Other developers will probably recommend other things based on their preferences. What do you know? What do you like best? What do you like most? I would go with that. I chose Django solely because I'm not such a big fan of PHP, I like Python, and I was comfortable with the framework when I initially played with it.

Change So how do you write cloud code? You design your software to fit one of these architectures. Again, look at the cloud agnostic thread for some really good discussion of the ways of this. For example, you can talk to some GAE services that are scalable. The fact that they are on GAE (example) does not really matter; you use the ideas of free communication. In fact, this is just a step further from the idea of ​​a web service.

In addition, another feature of the cloud that I forgot to mention is the idea of ​​providing a CDN for you - some cloud implementations can move your data around the world to make it more efficient for maintenance, or simply because where it is have got a seat. If this is a problem, do not use the cloud.

+3
source

I cannot answer your question - I have no experience in such projects, but I can tell you one thing: both CakePHP and CodeIgniter are for PHP4 - in other words: for really old technologies. And it seems that nothing will change in their case. Symfony (especially version 2.0, which is still in heavy beta) is worth considering, but, as I said at the very beginning, I cannot support this with my experience.

+2
source

To develop deployment applications for the cloud, the main thing to consider is recovery. If your server is completed, you may lose all your data. If you are deploying to Amazon, I would recommend putting all the data you need on an Elastic Block Storage (EBS) device. This will be data such as user-generated content / files, database files, and logs. I also use the 5-day rotation EBS snapshot to back up. However, I had a cloud server on AWS for over a year without any problems.

As for the frameworks, I give Grail a try that minute, and I really like it. Built to be syntactically similar to Rails, but runs on the JVM. This means that you can take full advantage of Java, such as threading, concurrency and all the great libraries to create your web application.

0
source

Source: https://habr.com/ru/post/1304662/


All Articles