Reputation: 324
How do I deploy multiple Java services to the same GCP project?
There are a few mentions in the documentation of specifying the project ID in the appengine-web.xml[1];
The
<application>
element contains the application's project ID. This is the project ID you register when you create your project in the Google Cloud Platform Console.
but it is ignored by gcloud
and mvn
[1] [2] (Emphasis mine):
gcloud and gcloud tooling (Intellij, Gradle, and the new maven plug-ins) ignore this element
Note that while every appengine-web.xml file must contain the
<application>
tag, the name you supply there is ignored. The name of the application is taken from the<application>
tag in the appengine-application.xml file.
The last quote seems to apply to Java 8 / Jetty 9 runtimes.
The java-gae-quickstart project does not have an appengine-application.xml file.
[1] - appengine-web.xml Reference
[2] - Organizing xml Configuration Files
Upvotes: 2
Views: 1670
Reputation: 5526
Here's a sample project for using modules: https://github.com/GoogleCloudPlatform/appengine-modules-sample-java
Notes:
mvn appengine:update
Upvotes: 3