GAE Vs. EC2

Hey,

I don't know which cloud service to use.

I have 2 needs:
1. serving static files with DB (regular web server scenario), Django
2. execute specific utility I wrote, for some requests, in Python

currently the web server and the utility are running on the same machine,
and for some requests I'm running the utility locally.

If I'll use the GAE as a platform for my web server, I won't be able to run my utility locally,
I'll probably need to create another web server on EC2 just for it.

And for my question -
Does it make sense to have GAE for serving the static files and handling the DB,
and EC2 for running the utility, and make the GAE server send requests to the EC2 server?

Thanks!
omer dAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

btanExec ConsultantCommented:
GAE is more of platform for apps so I do see as web/app tier while the DB tier is typically segregated as backend. Some go for 3 tier instead of the mentioned 2 tier. Appscale (open source for GAE) can run in EC2.
> The web tier also most of the time act like a proxy cache, Appscale can spawn off instance as autoscale is supported. Also Appscale support Python too
> Appscale apps comes with its native DB (Cassandra as default) and if you need to connect to a remote database, you need to white list the client python library and then connect it directly to that database that you have already stood up and configured.

As per their FAQ, this is direct access to the database, not using the App Engine Datastore API. For a Python app, you can use MySQLdb - see a sample guestbook app (https://github.com/AppScale/sample-apps/tree/guestbook-mysql/python2.7/guestbook-mysql)

If you are seeking for recommended setup here is one with configuration example. But really depends on your use case and timeline to support this on short or long term.
What is a recommended production deployment?
...Here we placed an "appengine" node and "database" node on their own machines, while zookeeper is sitting on the head node. If you want additional fault tolerance, you can add more database nodes, zookeeper nodes, and appengine nodes.....In this deployment we have 2 database nodes, with replication set to 2. Cassandra is set to be strongly consistent, so both replicas should always be identical. We have two "appengine" nodes, therefore there are a total of 16 application servers hosting your application. If you were to deploy more applications, they too will have another 16 application servers (be careful with memory hungry applications). We have 3 "zookeeper" nodes so that we can achieve a quorum between them. We still have a single point of failure at the master node, but all other services have redundancies.
"https://github.com/AppScale/appscale/wiki/FAQs#what-is-a-recommended-production-deployment

For simplistic use case, AppServers already can save, retrieve, and query data via the Datastore API. They support AppServers written in the Python and ease the talking to any database supported within AppScale within each of the AppServers. https://github.com/AppScale/appscale/wiki/DatastoreServer

For distributed setup considerations - Some databases (Cassandra) run in a peer-to-peer fashion, so all database nodes are considered equal. But others employ some type of master-slave relationship - how then do we specify which node is the database master and which are the database slaves? That's simple - the first database node specified is always the database master.

FAQ Appscale - https://github.com/AppScale/appscale/wiki/FAQs

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
omer dAuthor Commented:
thanks for the detailed answer!
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Cloud Computing

From novice to tech pro — start learning today.