
Not every library from the App Engine SDK is available in the Cloud SDK, and some of the libraries behave differently. Then change your code to use the packages and classes in this library. You’re using the App Engine Maven plugin if you have this in your pom.xml file:

The App Engine Maven plugin had been used to deploy servers both locally and to Google Cloud, and it was the first feature to be deprecated. The end result is a codebase that uses the new Cloud SDK-based Maven plugin, the new Cloud SDK-based libraries, and the Java 11 runtime. The rest of this guide outlines upgrading each of these three pieces. You can’t do this unless you also migrate any App Engine libraries you’re using. But if you want to use any features implemented in Java 9, 10, or 11, or if you want to stay more up-to-date, then you’d want to do this migration. If you’re happy with Java 8, you don’t need to do this. The Java runtime, from Java 8 to Java 11.You can do this without upgrading to Java 11. The App Engine-specific APIs still work for now, but they’re no longer recommended by Google. The Cloud libraries, from the App Engine-specific APIs to the Google Cloud SDK-based libraries.This is the only step you need to do for your code to keep working. The Maven plugin that runs the code, from the standalone App Engine Maven plugin to the Cloud SDK-based Maven plugin.One thing that makes this migration confusing is that it’s actually migrating three different things: Instead of complaining about why that is, I’m going to collect the steps I followed to upgrade my own Google Cloud code from Java 8 to Java 11. The challenge is that code that used to work with Java 8 will no longer work in Java 11, and the migration path is not very obvious. Then in June 2019, Google Cloud announced support for Java 11. This guide outlines a process you can follow to migrate your Google Cloud server code from Java 8 and the standalone App Engine SDK to Java 11 and the Cloud SDK.įor years, Java 8 was the standard Java runtime supported by Google Cloud.

Setup Migrating to Java 11 tutorial java google cloud
