creating a hello app using google app engine. what are google apps? apps is an abbreviation for...

37
Creating a Hello App Using Google App Engine

Upload: elisabeth-flowers

Post on 20-Jan-2016

222 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Creating a Hello App Using Google App Engine

Page 2: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

What are Google apps?

• Apps is an abbreviation for application. An app is a piece of software. It can run on the Internet, on your computer, or on your phone or other electronic device.• Google refers to their online services as apps, but

they also sell a specific suite of services known as Google Apps and have an application hosting service called Google Appengine.

Page 3: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

What is google appengine?

•Google App Engine is a way to write your own Web applications and have them hosted on Google servers.

•Google Apps can be found on the Web at www.google.com/a

•And Google App Engine can be found on the Web at code.google.com/appengine.

Page 4: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Cont…

•You can serve your app using a free name on the appspot.com domain. You can share your application with the world, or limit access to members of your organization.

Page 5: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Registering the Application

1. App Engine Administration Console, at the following URL:

https://appengine.google.com/2. Sign in to App Engine using your Google account3. To create a new application:

a) Click the "Create an Application" buttonb) Follow the instructions to register an application ID,

a name unique to this applicationc)If you select to use the free appspot.com domain name,

the full URL for the application will be http://application-id.appspot.com/

Page 6: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Sign in to gmail account:

Page 7: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run
Page 8: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

How to make Google app?

•To make google app we need following 1. eclipse 2. google plugin for eclipse

Page 9: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Eclipse

• Eclipse is a multi-language software development environment comprising an integrated development environment (IDE) and an extensible plugin system. It is written mostly in java and can be used to develop applications in Java and, by means of various plug-ins, other programming language including C, C++ etc.

Page 10: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

How to download eclipse?

•Eclipse is an open source software .• Its different versions are easily available on internet .•http://www.eclipse.org/downloads/•To download eclipse first you have to install java run

time environment.

Page 11: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Installing eclipse:

•Go to the site:•http://www.poweredbypulse.com/

eclipse_packages_win.php•Select the eclipse version 3.6

Page 12: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Installing eclipse classic:

Page 13: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Step1:Check Google plugin for eclipse

Page 14: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Step2:click on install button

Page 15: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Installation started:

Page 16: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Plugin installed:

Page 17: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Creating web application project

Page 18: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Creating new web application project:

Page 19: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Project created:

Page 20: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

The Project Directory • A single directory named

Project_Name/ for all project files.

• Subdirectory named src/ contains the Java source code

• Subdirectory named war/ contains the complete application arranged in the WAR format.

• Build process compiles the Java source files and puts the compiled classes in the appropriate location in war/

Page 21: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

The servlet class:•App Engine Java applications use the Java Servlet

API to interact with the web server.• An HTTPservlet is an application class that can

process and respond to web requests.•Servlet class extends either the

javax.servlet.GenericServlet class or the javax.servlet.http.HttpServlet class.

Page 22: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Servlet class:

Page 23: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

The web.xml File:

•When the web server receives a request, web.xml file is used to determines which servlet class to call

•web.xml resides in the war/WEB-INF/ directory •web.xml file declares a servlet named Yusra, and

maps it to the URL path /yusra•whenever the user fetches a URL path that is not

already mapped to a servlet, the server should check for a file named index.html in that directory and serve it if found.

Page 24: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Xml file:

Page 25: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

The appengine-web.xml File

•This file is named appengine-web.xml, and resides in WEB-INF/ alongside web.xml

• It includes:▫The registered ID of your application (Eclipse creates

this with an empty ID for you to fill in later), ▫The version number of your application, ▫Lists of files:

Static files (such as images and CSS) and resource files (such as JSPs and other application data)

Page 26: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

appengine-web.xml file:

Page 27: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Running the project:• The App Engine SDK includes a web server

application you can use to test your application • Steps:

▫ Make sure the project (“Yusra") is selected, ▫ Right click and select Run As menu▫ Select Web Application

• This should start Jetty on http://localhost:8888/

Page 28: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run
Page 29: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Testing the Application:

Page 30: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Deploying Application:

• Now deploy your application to the Google cloud• You must have a google mail account• Give application ID to you application– Application ID will be stored in file (“appengine-

web.xml”• First you will have to register application on google

cloud–Using the same application ID

• Then perform deploying operation

Page 31: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Uploading From Eclipse• To upload your application from Eclipse, click the

App Engine deploy button on the toolbar

• Click the Deploy button

• Enter your Google account username (your email address) and password when prompted

• Eclipse gets the application ID and version information from the appengine-web.xml file, and uploads the contents of the war/ directory.

Page 32: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Deploying project:

Page 33: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Click on deploy button:

Page 34: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Deployment started:

Page 35: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Accessing Your Application

•You can now see your application running on App Engine

• If you set up a free appspot.com domain name, the URL for your website begins with your application ID:

http://application-id.appspot.com/• In our example it will be http://hiyzfriends.appspot.com/yusra

Page 36: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run

Uploaded successfully:

Page 37: Creating a Hello App Using Google App Engine. What are Google apps? Apps is an abbreviation for application. An app is a piece of software. It can run