Igor Kromin |   Consultant. Coder. Blogger. Tinkerer. Gamer.

Google has deprecated the Java7 runtime in favour of Java8 as of the 13th of December 2017 and it's advisable to migrate your apps to the new runtime. The apps do not need to be migrated immediately since the Java7 runtime will be available until January 16 2019, so you have some time still.

I decided to migrate Guru JSON-RPS Tester and Extrudifier now to avoid any issues in the future. The process was very simple, however if your app is using some of the incompatible features of the Java7 runtime you may need to put in a bit more work. All of the incompatibilities are described on the Migrating from Java 7 to Java 8 Runtime page in Google's documentation.

This was the email I received from Google informing me of the changes...

I decided to head on over to the AppEngine Console to check that I was in fact on the Java7 runtime...I was.

So to move my app over to the Java8 runtime I had to update the WEB-INF/appengine-web.xml file and add this line to it - <runtime>java8</runtime>. I also updated my app's version at the same time just in case I had some incompatibility to iron out (I didn't want the current users of my app to have any down time).

That was almost too easy! I tried to redeploy and got a NullPointerException! Boo. It wasn't exactly clear why this exception was being thrown during deployment but I had a hunch...I was still using the Java7 JRE on my project's build path.

I've changed that to the Java8 JRE (via the Edit button)...


Now deploying the app was successful! I guess it's obvious that this should have been changed, but it wasn't in Google's documentation. My app now had a new version on the Java8 runtime. I was able to test it on its version-dot endpoint and after making sure it was running without issues I migrated all the traffic to the new version.

After the traffic was migrated, I deleted the Java7 version of my app.


Skip down to comments...
Hope you found this post useful...

...so please read on! I love writing articles that provide beneficial information, tips and examples to my readers. All information on my blog is provided free of charge and I encourage you to share it as you wish. There is a small favour I ask in return however - engage in comments below, provide feedback, and if you see mistakes let me know.

If you want to show additional support and help me pay for web hosting and domain name registration, donations, no matter how small, are always welcome!

Use of any information contained in this blog post/article is subject to this disclaimer.
comments powered by Disqus
Other posts you may like...