I have an application which is developed using GWT 2.6 and Java 7. Now I am updating it to Java 8 with GWT 2.6.
- Is GWT 2.6 compatible with Java 8? Will it build/compile fine?
- Is GWT 2.7 compatible with Java 8? Any suggestion?
I have an application which is developed using GWT 2.6 and Java 7. Now I am updating it to Java 8 with GWT 2.6.
If you're only interested in using a JDK 8 to compile your application, without using Java 8 language constructs, then GWT 2.6 and 2.7 will work.
Java 8 as a source language won't be supported before GWT 2.8 though, as already pointed by others.
In 2.7, you can use the Java7 syntax on the client. You cannot use the Java8 syntax and runtime on the client.
On the server, you can use JDK8.
Java 8 support should come in GWT 2.8 according to this post: Java 8 support in GWT.
So, basically you cannot use Java 8 in GWT 2.6. As I understand there are some improvements in 2.7, but it is not enough. There is a way that by dividing the project you can achieve that you can use Java 8 on the server side and java 7 with GWT on UI.
Edit: you should take a look at this Java 8 support in GWT
It's seems to be GWT 2.8 and 3.0.
In the meantime, GWT 2.8 is due out within three months. Its main feature is support for Java 8, including lambdas.
According to Release Notes for 2.8.0
Highlights
- Java 8 syntax supported.
- JsInterop has graduated from experimental. See final JsInterop specification.
- GSS is no longer considered as experimental and old CssResource is now deprecated.
http://www.gwtproject.org/release-notes.html#Release_Notes_2_8_0_BETA1
Update: Stable version of 2.8.0 is released on Oct 20, 2016