问题
How can I make play framework 1.x
work with Java 8?
Play framework version 1.2.5.3
Java version "1.8.0"
Java(TM) SE Runtime Environment (build 1.8.0-b132)
Java HotSpot(TM) Server VM (build 25.0-b70, mixed mode)
I have an error:
play.exceptions.CompilationException: java.util.stream.Collectors cannot be resolved at play.classloading.ApplicationCompiler$2.acceptResult(ApplicationCompiler.java:246) at org.eclipse.jdt.internal.compiler.Compiler.handleInternalException(Compiler.java:676) at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:520) at play.classloading.ApplicationCompiler.compile(ApplicationCompiler.java:282) at play.classloading.ApplicationClasses$ApplicationClass.compile(ApplicationClasses.java:281) at play.classloading.ApplicationClassloader.detectChanges(ApplicationClassloader.java:324) at play.Play.detectChanges(Play.java:625) at play.Invoker$Invocation.init(Invoker.java:198) at Invocation.HTTP Request(Play!)
回答1:
There is a commit in the repository for java 8 support with play 1.3
https://github.com/playframework/play1/blob/master/framework/src/play/classloading/ApplicationCompiler.java
来源:https://stackoverflow.com/questions/22930366/play-framework-1-x-with-java-8