Can't access the app on the game infrastructure

Hi, I have installed new platform version 2.0. Now I am trying to connect to the sample app from the tutorial, but something seems to be unworkable. Here's what I did:

Create a "todolist" application:

play new todolist

play! 2.0, http://www.playframework.org

The new application will be created in / home / evermean / Code / playWorkspace / todolist

What is the application name?

> todolist

Which template do you want to use for this new application?

1 - Create a simple Scala application
2 - Create a simple Java application
3 - Create an empty project

> 2

OK, application todolist is created. Have fun!

Run play command:

$ cd todolist
$ play

Getting org.scala-tools.sbt sbt_2.9.1 0.11.2 ...
:: retrieving :: org.scala-tools.sbt # boot-app
confs: [default]
37 artifacts copied, 0 already retrieved (7324kB / 127ms) [info] Loading project definition from / home / evermean / Code / playWorkspace / todolist / project
[info] Set current project to todolist (in build file: / home / evermean / Code / playWorkspace / todolist /)

play! 2.0, http://www.playframework.org

> Type "help play" or "license" for more information. > Type "exit" or use Ctrl + D to leave this console.

Run the launch command:

[todolist] $ run

[info] Updating {file: / home / evermean / Code / playWorkspace / todolist /} todolist ... [info] Done updating.
--- (Running the application from SBT, auto-reloading is enabled) ---

[info] play - Listening for HTTP on port 9000 ...

(Server started, use Ctrl + D to stop and go back to the console ...)

Now I try to connect to the site http: // localhost: 9000

I get the following output:

[info] Compiling 4 Scala sources and 2 Java sources to /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/classes ...

[warn] Problem processing dependencies of source / home / evermean / Code / playWorkspace / todolist / app / controllers / Application.java: java.lang.UnsupportedClassVersionError: controllers / Application: Unsupported major.minor version 51.0

[warn] Error reading API from class file: java.lang.UnsupportedClassVersionError: controllers / Application: Unsupported major .minor version 51.0

[warn] Problem processing dependencies of source /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/src_managed/main/controllers/routes.java: java.lang.UnsupportedClassVersionError: controllers / routes : Unsupported major.minor version 51.0

[warn] Problem processing dependencies of source /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/src_managed/main/controllers/routes.java: java.lang.UnsupportedClassVersionError: controllers / routes $ ref: Unsupported major.minor version 51.0

[warn] Problem processing dependencies of source /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/src_managed/main/controllers/routes.java: java.lang.UnsupportedClassVersionError: controllers / routes $ javascript: Unsupported major.minor version 51.0

[warn] Problem processing dependencies of source /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/src_managed/main/controllers/routes.java: java.lang .UnsupportedClassVersionError: controllers / routes: Unsupported major.minor version 51.0

[warn] Problem processing dependencies of source /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/src_managed/main/controllers/routes.java: java.lang.UnsupportedClassVersionError: controllers / routes $ ref: Unsupported major.minor version 51.0

[warn] Problem processing dependencies of source /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/src_managed/main/controllers/routes.java: java.lang.UnsupportedClassVersionError: controllers / routes: Unsupported major.minor version 51.0

[warn] Problem processing dependencies of source /home/evermean/Code/playWorkspace/todolist/target/scala-2.9.1/src_managed/main/controllers/routes.java: java.lang.UnsupportedClassVersionError : controllers / routes $ javascript: Unsupported major.minor version 51.0

[warn] Error reading API from class file: java.lang.UnsupportedClassVersionError: controllers / routes: Unsupported major.minor version 51.0

[warn] Error reading API from class file: java.lang.UnsupportedClassVersionError: controllers / routes $ ref: Unsupported major .minor version 51.0 [warn] Error reading API from class file: java.lang.UnsupportedClassVersionError: controllers / routes $ javascript: Unsupported major.minor version 51.0

[info] play - Application started (Dev)

I really don't know what to do about it, maybe someone has an idea on this. I guess I'm doing something wrong, but I can't see where my mistake is. I hope some can help.

Thank...

+3


source to share


3 answers


It looks like the JDK you are using is too old. What version of Java are you using?



+4


source


A lot of the time java and javac have the same version, but the play framework / activator will use JAVA_HOME which may point to a different version than java and javac.So check everything is the same: echo $JAVA_HOME java -version javac -version



https://github.com/playframework/playframework/issues/2675

+2


source


I had the same problem. I didn't want to believe it was a bug in the JDK version with game 2.0. Thought about this for 10 minutes and realized that I didn't have scala installed. After installing scala, it got rid of these errors.

+1


source







All Articles