0% found this document useful (0 votes)
20 views

Unit V Google App Engine

Uploaded by

spartansheik
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

Unit V Google App Engine

Uploaded by

spartansheik
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 20

UNIT V

Google App Engine


PaaS
• Cloud computing service which provides a
computing platform and a solution stack as a
service.
• Consumer creates the software using tools
and/or libraries from the provider.
• Provider provides the networks, servers, storage,
etc.
Why App Engine?
• Lower total cost of ownership
• Rich set of APIs
• Fully featured SDK for Local
development
• Ease of Deployment
Google App Engine
• Google App Engine (often referred to as GAE or simply App Engine) is a
platform as a service (PaaS) cloud computing platform for developing and
hosting web applications in Google-managed data centers.
• Applications are sandboxed and run across multiple servers.
• App Engine offers automatic scaling for web applications—as the
number of requests increases for an application, App Engine automatically
allocates more resources for the web application to handle the additional
demand.
• Google App Engine is free up to a certain level of consumed resources.
Fees are charged for additional storage, bandwidth, or instance hours
required by the application.
Google App Engine
• Application usage of Google resources and services is
metered by AppEngine, which bills users when their
applications finish their free quotas.
• Developers can develop applications in Java, Python,
and Go, a new programming language developed by
Google to simplify the development of Web
applications.
• It was first released as a preview version in April
2008, and came out of preview in September 2011.
Architecture and core concepts
• AppEngine is a platform for developing scalable
applications accessible through the Web.
• The platform is logically divided into four major
components:
• infrastructure,
• the run- time environment,
• the underlying storage,
• and the set of scalable services that can be used to
develop applications.
Infrastructure
• AppEngine hosts Web applications, and its primary function is
to serve users requests efficiently.
• To do so, AppEngine’s infrastructure takes advantage of many
servers available within Google datacenters.
• For each HTTP request, AppEngine locates the servers hosting
the application that processes the request, evaluates their
load, and, if necessary, allocates additional resources (i.e.,
servers) or redirects the request to an existing server.
• The infrastructure is also responsible for monitoring
application performance and collecting statistics on which the
billing is calculated.
Runtime environment
• The runtime environment represents the execution context of applications hosted on
AppEngine. With reference to the AppEngine infrastructure code
• Sandboxing : One of the major responsibilities of the runtime environment is to
provide the application environment with an isolated and protected context in which
it can execute without causing a threat to the server and without being influenced by
other applications.
• Currently, AppEngine supports applications that are developed only with managed or
interpreted languages, which by design require a runtime for translating their code
into executable instructions. Therefore, sandboxing is achieved by means of modified
runtimes for applications.
• Some of the operations that are not allowed in the sandbox include writing to the
server’s file system; accessing computer through network besides using Mail,
UrlFetch, and XMPP; executing code outside the scope of a request, a queued task,
and a cron job; and processing a request for more than 30 seconds.
• AppEngine currently supports Java 6, and developers can use
the common tools for Web appli- cation development in Java,
such as the Java Server Pages (JSP), and the applications
interact with the environment by using the Java Servlet
standard.
• Support for Python is provided by an optimized Python 2.5.2
interpreter. As with Java, the run- time environment supports
the Python standard library.
• The Go runtime environment allows applications developed
with the Go programming language to be hosted and executed
in AppEngine. Currently the release of Go that is supported by
AppEngine is r58.1. The SDK includes the compiler and the
standard libraries for developing appli- cations in Go and
interfacing it with AppEngine services.
Storage
• AppEngine provides various types of storage,
which operate differently depending on the
volatility of the data.
• There are three different levels of storage:
• in memory-cache,
• storage for semistructured data,
• and long-term storage for static data.
• Static file servers Static data often are mostly
constituted of the components that define the
graphical layout of the application (CSS files, plain
HTML files, JavaScript files, images, icons, and
sound files) or data files.
• DataStore is a service that allows developers to
store semistructured data. The service is designed
to scale and optimized to quickly access data.
Application services
• Application services made by runtime environment that simplify most of
the common operations that are performed in Web applications:
• access to data (MemCache AppEngine provides developers with access
to fast and reliable storage, which is DataStore),
• account management (Web applications often keep various data that
customize their interaction with users.),
• integration of external resources,
• messaging and communication (Email can also be used to trig- ger
activities in Web applications. ),
• image manipulation (Web applications render pages with graphics), and
• asynchronous computation.
Programming languages support
Java:
• App Engine runs JAVA apps on a JAVA 7 virtual machine
(currently
• supports JAVA 6 as well).
• Uses JAVA Servlet standard for web applications:
• WAR (Web Applications ARchive) directory structure.
• Servlet classes
• Java Server Pages (JSP)
• Static and data files
• Deployment descriptor (web.xml)
• Other configuration files
• Getting started :
– https://developers.google.com/appengine/docs/java/gettingstarte
Python:
• Uses WSGI (Web Server Gateway Interface)
standard.
• Python applications can be written using:
• Webapp2 framework
• Django framework
• Any python code that uses the CGI (Common Gateway
Interface) standard.
• Getting started :
– https://developers.google.com/appengine/docs/python
/gettingstartedpython27/
• PHP (Experimental support):
• Local development servers are available to
anyone for developing
• and testing local applications.
• Only whitelisted applications can be deployed on
Google App Engine.
• (https://gaeforphp.appspot.com/).
• Getting started:
https://developers.google.com/appengine/docs/p
hp/
Google’s Go:
• Go is an Google’s open source programming
environment.
• Tightly coupled with Google App Engine.
• Applications can be written using App Engine’s Go
SDK.
• Getting started:

https://developers.google.com/appengine/docs/go/ov
erview
Google cloud SQL:
• Provides a relational SQL database service.
• Similar to MySQL RDBMS.
• Google App Engine Hello World tutorials:

• JAVA:
– http://www.mkyong.com/google-app-engine/google-app-engine-hello-world-ex
ample-using-eclipse/

• Python:
– http://www.mkyong.com/google-app-engine/google-app-engine-python-hello-
world-example-using-eclipse/

• More information:
– https://developers.google.com/appengine/
GAE Application Environment
• Google App Engine makes it easy to build an application that runs reliably,
even under heavy load and with large amounts of data. App Engine includes
the following features:
• persistent storage with queries, sorting and transactions
• automatic scaling and load balancing
• APIs for authenticating users and sending email using Google Accounts
• task queues for performing work outside of the scope of a web request
• scheduled tasks for triggering events at specified times and regular intervals
• dynamic web serving, with full support for common web technologies

You might also like