Your project must contain, at a minimum, the following files:
File and Location | Description |
---|---|
/src/main/java/<packagepath>/<your_api_class>.java |
The class file (or files, if you implement your API across multiple classes) containing your backend API. |
/src/main/webapp/WEB-INF/appengine-web.xml |
The web app deployment descriptor required for App Engine configuration. |
/src/main/webapp/WEB-INF/web.xml |
The standard Java web app deployment descriptor mapping URLs to servlets and other information. |
The contents of each of these required files is documented in the following sections.
The API class file
The required and optional contents of the class file (or files, if you use a multi-class API) are fully described in the topic Endpoint Annotations.
appengine-web.xml
The appengine-web.xml
file is used to define the App Engine standard
environment configuration when the API is deployed.
See appengine-web.xml Reference
for more information.
The bare minimum contents required for this file are as follows:
web.xml
You use the web.xml
file to configure the Endpoints servlet, which handles
incoming requests and forwards them to the backend service running on
App Engine. The Endpoints servlet is required for your API to be
managed by Cloud Endpoints.
The bare minimum contents required for this file are as follows:
For more information about web.xml
, see
The Deployment Descriptor: web.xml.