Play 2.3.0-RC1 released!

3,897 views
Skip to first unread message

James Roper

unread,
May 8, 2014, 1:11:25 AM5/8/14
to play-framework

The Play team is pleased to announce the first release candidate for Play 2.3.0. This release candidate is a feature complete version of Play 2.3.0, but it may have bugs in it. If it has any serious bugs then we’ll put out another release candidate with fixes. Otherwise this release will become Play 2.3.0.


We encourage the Play community to download this release candidate and test it out. See further down this email for instructions.


What’s new in Play 2.3


  1. Introducing the activator command. You can use activator exactly like you would use play, but Activator brings new features too. (More about the Activator change.)

  2. Better tooling for static assets. Play now uses sbt-web which gives faster asset processing, more features, and better extensibility.

  3. Support for Java 8 (and continued support for Java 6 and 7).

  4. Better Java performance. Simple Java controllers give 40–90% better throughput. (Thanks to YourKit for sponsoring licenses.)

  5. Support for Scala 2.11 (and continued support for Scala 2.10).

  6. Anorm enhancements: SQL string interpolation, multi-value parameters, new types, and more.

  7. Web Services enhancements: separate client, SSL configuration, and more.

  8. Play templates have become Twirl templates: separate project, new sbt plugin, still excellent integration with Play

  9. Actors for WebSockets

  10. Custom SSLEngine for HTTPS

  11. Asset performance: faster serving, better caching.

  12. One Result to rule them all: all the result types which were deprecated in 2.2 are now gone and only Result remains.

  13. Lots of bug fixes. :)


For details see the Play 2.3 Highlights and the Play 2.3 Migration Guide.


Testing out Play 2.3


You can help out by testing this release candidate. Discuss issues on the mailing list—use a subject starting with [2.3.0-RC1]—or report bugs on Github.


Using Play 2.3 in a new project


We will use Activator to create a new project from a Play 2.3 template.


Command line instructions


  1. Download the Activator minimal distribution (1MB).

  2. Run activator new.

  3. Enter one of the following template names:

  4. Enter a name for your new project.

  5. Change to the the project directory.

  6. Type activator to reach the console. [Known issue: You may not see any activity for several minutes while new dependencies are being downloaded.]

  7. Use the compile, run, test, etc commands to build and run the project.


Activator UI instructions


Most Activator templates include a tutorial that can be viewed from within the Activator UI. The play-2.3-highlights template has a tutorial that showcases the new features of Play 2.3.


  1. Download the Activator minimal distribution (1MB)

  2. Run activator new.

  3. Enter one of the following template names:

  4. Enter a name for your new project.

  5. Change to the the project directory.

  6. Type activator ui to view the project in a the Activator UI [Known issue: You may not see any activity for several minutes while new dependencies are being downloaded.]

  7. Follow the tutorial on the right of the screen or use the buttons on the left to interact with the project.


Using Play 2.3 in an existing project


See the Play 2.3 Migration Guide for complete instructions on changing your existing project to use Play 2.3.


Known Issues


  1. If there are a large number of assets to be processed by sbt-coffeescript, sbt-less or sbt-jshint then a timeout can occur during asset compilation when using the default JavaScript engine (Trireme). If this occurs then “set JsEngineKeys.parallelism := 1” or use Node instead of Trireme (export SBT_OPTS="$SBT_OPTS -Dsbt.jse.engineType=Node").


Thanks

Play Team


--
James Roper
Software Engineer

virtualeyes

unread,
May 8, 2014, 3:15:40 AM5/8/14
to play-fr...@googlegroups.com
This release looks awesome ;-)

> Support for Scala 2.11

and that is indeed welcome, can now start testing against 2.11

Thanks!

Marius Soutier

unread,
May 8, 2014, 3:31:25 AM5/8/14
to play-fr...@googlegroups.com
14. Akka 2.3.2 :)

--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to play-framewor...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

heapifyman

unread,
May 8, 2014, 5:01:40 AM5/8/14
to play-fr...@googlegroups.com

Am Donnerstag, 8. Mai 2014 07:11:25 UTC+2 schrieb James Roper:

Command line instructions


  1. Download the Activator minimal distribution (1MB).

  2. Run activator new.

  3. Enter one of the following template names:

  4. Enter a name for your new project.

  5. Change to the the project directory.

  6. Type activator to reach the console. [Known issue: You may not see any activity for several minutes while new dependencies are being downloaded.]

  7. Use the compile, run, test, etc commands to build and run the project.


 Following above instructions for play-java-preview I get the following exception on "run" 

[play-java-8-prev] $ run

--- (Running the application from SBT, auto-reloading is enabled) ---

[info] play - Listening for HTTP on /0:0:0:0:0:0:0:0:9000

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

[trace] Stack trace suppressed: run last *:coffeescript for the full output.
[trace] Stack trace suppressed: run last *:less for the full output.
[trace] Stack trace suppressed: run last *:jshint for the full output.
[error] (*:coffeescript::jstaskShellSource) Could not create directory C:\Users\......\play-java-8-prev\project\target\coffeescript\file:\C:\Users\......\.ivy2\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-coffeescript\jars\sbt-coffeescript-1.0.0-RC1.jar!
[error] (*:less::jstaskShellSource) Could not create directory C:\Users\......\play-java-8-prev\project\target\less\file:\C:\Users\......\.ivy2\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-less\jars\sbt-less-1.0.0-RC1.jar!
[error] (*:jshint::jstaskShellSource) Could not create directory C:\Users\......\play-java-8-prev\project\target\jshint\file:\C:\Users\......\.ivy2\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-jshint\jars\sbt-jshint-1.0.0-RC1.jar!
[error] application -

! @6i6ci26pl - Internal server error, for (GET) [/] ->

play.PlayExceptions$UnexpectedException: Unexpected exception[RuntimeException: Could not create directory C:\Users\......\play-java-8-prev\project\target\coffeescript\file:\C:\Users\......\.ivy2\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-coffeescript\jars\sbt-coffeescript-1.0.0-RC1.jar!]
        at play.PlayReloader$$anon$1$$anonfun$play$PlayReloader$$anon$$taskFailureHandler$1.apply(PlayReloader.scala:295) ~[na:na]
        at play.PlayReloader$$anon$1$$anonfun$play$PlayReloader$$anon$$taskFailureHandler$1.apply(PlayReloader.scala:287) ~[na:na]
        at scala.Option.map(Option.scala:145) ~[scala-library-2.11.0.jar:na]
        at play.PlayReloader$$anon$1.play$PlayReloader$$anon$$taskFailureHandler(PlayReloader.scala:287) ~[na:na]
        at play.PlayReloader$$anon$1$$anonfun$reload$2.apply(PlayReloader.scala:320) ~[na:na]
Caused by: java.lang.RuntimeException: Could not create directory C:\Users\......\play-java-8-prev\project\target\coffeescript\file:\C:\Users\......\.ivy2\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-coffeescript\jars\sbt-coffeescript-1.0.0-RC1.jar!
        at scala.sys.package$.error(package.scala:27) ~[scala-library-2.11.0.jar:na]
        at sbt.IO$.createDirectory(IO.scala:155) ~[na:na]
        at sbt.OpenFile$class.open(Using.scala:45) ~[na:na]
        at sbt.Using$$anon$2.open(Using.scala:70) ~[na:na]
        at sbt.Using$$anon$2.open(Using.scala:70) ~[na:na]
[warn] play - No application found at invoker init


Phil Wills

unread,
May 8, 2014, 7:22:59 AM5/8/14
to play-fr...@googlegroups.com
One thing missing from the migration guide is that you need to add

import com.typesafe.sbt.web._

if you have a .scala, rather than .sbt based build.  I'd do a PR to add this, but I'm not sure where would be a sensible place to add it.

Phil

neverminder

unread,
May 8, 2014, 10:35:11 AM5/8/14
to play-fr...@googlegroups.com
Can someone confirm what's the status of play-slick module, as it was supposed to be integrated into Play 2.3, but I understand that's no longer the case? I'm trying to upgrade one of my projects to Play 2.3 / Scala 2.11 / Slick 2.1, but absence of Scala 2.11 compatible play-slick module is a total showstopper.

Christopher Hunt

unread,
May 8, 2014, 6:47:00 PM5/8/14
to play-fr...@googlegroups.com
Hi Phil,

There is no migration here as such - the sbt-web settings weren't available before...

The migration guide does provide an indication of how an auto-plugin's settings should be imported:

  import play.Play.autoImport._
  import PlayKeys._

Perhaps it would be useful to add a line beyond that highlighting:

  import com.typesafe.sbt.web.SbtWeb.autoImport._
  import WebKeys._

The autoImport member is what you want though because it is used to control the scope of a wildcard import; you don't want everything of that package.

Feel free to raise a PR - thanks!

Kind regards,
Christopher

Christopher Hunt

unread,
May 8, 2014, 6:58:12 PM5/8/14
to play-fr...@googlegroups.com
Thanks for reporting this issue. I've now collected the issue here: https://github.com/playframework/playframework/issues/2803

Christopher Hunt

unread,
May 8, 2014, 7:05:11 PM5/8/14
to play-fr...@googlegroups.com
We subsequently decided that it was best for play-slick to reside outside of core Play. The rationale here is that play-slick should have its own release cycle and not be bound to the slower cycle of core Play. We've taken this approach with a number of functionalities including the whole of sbt-web and twirl (templates). I'd say that anorm will be spun off for the same reason.

Apologies for not having been clearer in our communications here.

Happy also to accept PRs for play-slick!

alex s

unread,
May 8, 2014, 8:46:01 PM5/8/14
to play-fr...@googlegroups.com

I'm having trouble with "run" command on FreeBSD.

https://gist.github.com/anonymous/1aa680f2a68cf2f67b8c

While it's true that Play doesn't support FreeBSD: 1) it's was working before 2.3 (before 21195c9181, I suppose); 2) this behavior kind of undermines the idea of having fallback code for jnotify.

Christopher Hunt

unread,
May 8, 2014, 8:53:32 PM5/8/14
to play-fr...@googlegroups.com
Unfortunately this looks to be a constraint of JNotify itself. Are you certain that it was working for 2.2? Perhaps our version refresh for 2.3 pulled in a later version that decided not to support FreeBSD?

--
You received this message because you are subscribed to a topic in the Google Groups "play-framework" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/play-framework/OJBAdiWMc_A/unsubscribe.
To unsubscribe from this group and all its topics, send an email to play-framewor...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


-- 
Christopher Hunt
Senior Engineer
Typesafe – Build Reactive Apps on the JVM!

Twitter: @huntchr

alex s

unread,
May 8, 2014, 9:07:38 PM5/8/14
to play-fr...@googlegroups.com


пятница, 9 мая 2014 г., 4:53:32 UTC+4 пользователь Christopher Hunt написал:
Unfortunately this looks to be a constraint of JNotify itself. Are you certain that it was working for 2.2? Perhaps our version refresh for 2.3 pulled in a later version that decided not to support FreeBSD?

https://github.com/playframework/playframework/pull/2147

FreeBSD was never supported by jnotify. Play just skips the fallback code.

alex s

unread,
May 8, 2014, 9:17:56 PM5/8/14
to play-fr...@googlegroups.com


пятница, 9 мая 2014 г., 5:07:38 UTC+4 пользователь alex s написал:

Play just skips the fallback code.

I mean the jnotify fallback code in PlayReloader.scala to be more precise / less cryptic.

Christopher Hunt

unread,
May 8, 2014, 10:07:31 PM5/8/14
to play-fr...@googlegroups.com
Perhaps raise this as an issue. Thanks.

--
You received this message because you are subscribed to a topic in the Google Groups "play-framework" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/play-framework/OJBAdiWMc_A/unsubscribe.
To unsubscribe from this group and all its topics, send an email to play-framewor...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Christian Kaps

unread,
May 9, 2014, 2:17:28 AM5/9/14
to play-fr...@googlegroups.com
Hi,

I thought the new validation API would also be integrated into Play 2.3. but there is no notice about it.

Regards,
Christian


Am Donnerstag, 8. Mai 2014 07:11:25 UTC+2 schrieb James Roper:

Sebas

unread,
May 9, 2014, 11:37:35 AM5/9/14
to play-fr...@googlegroups.com
Looks like a great release, can't wait for the final release, but something is still broken in the classloader.

public static Result index()  {
  
    ScriptEngineManager factory = new ScriptEngineManager();
    ScriptEngine engine = factory.getEngineByName("JavaScript");   
  
    return ok(views.html.main.render(engine==null ? "null":"not null" ));
}

engine should not be null (java 7 does not give null, java 8 does).

Sebas

Phil Wills

unread,
May 9, 2014, 4:44:25 PM5/9/14
to play-fr...@googlegroups.com
Hi Christopher,

Perhaps I'm misunderstanding, but my understanding was that if you were previously using Play for Coffeescript and LESS compilation, you'd now need to include SbtWeb. Hence my presumption that you need additional imports, since you need at least one to be able to enable SbtWeb.

Will try and do the PR.

Phil

Christopher Hunt

unread,
May 9, 2014, 6:00:32 PM5/9/14
to play-fr...@googlegroups.com
Hi Phil

Sorry for confusing you. We talk about sbt-web in a general sense and then the specific plugins. sbt-web, sbt-jse, sbt-coffeescript, sbt-less - they're all plugins that warrant their own imports.

Kind regards
Christopher
--

James Roper

unread,
May 10, 2014, 4:03:42 AM5/10/14
to play-framework
That sounds more like a regression in Java 8, not a problem in Play. 

Anyway, script engine manager needs to be told which classloader to use, and you're not doing that - in order for Play's dev mode to work, it requires a very complex and dynamic classloading environment, so if you're using code that messes with classloaders like script manager engine, you need to understand what you're doing, you can't just expect it all to magically work.  Try:

new ScriptEngineManager(null);

By passing it null, you're telling it to use the system classloader, which is presumably where you want to get the "JavaScript" script manager from.

Sebas

--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to play-framewor...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.

Julien Richard-Foy

unread,
May 10, 2014, 2:43:39 PM5/10/14
to play-fr...@googlegroups.com
The documentation does not mention anymore that the require.js
cilent-side runtime is provided by Play as a
`public/javascripts/require.js` resource.
However, I see that it is still present in the Play .jar. Do you want
to keep providing it? In such case you should mention it in the
documentation. Maybe it should be shipped with the sbt-rjs plugin
instead.

Christopher Hunt

unread,
May 10, 2014, 6:05:10 PM5/10/14
to play-fr...@googlegroups.com
We don't want to continue providing it. WebJars should be used (we should also support Bower at some point).

We haven't totally eliminated the old way yet and so it is just a hangover.

Kind regards
Christopher
> You received this message because you are subscribed to a topic in the Google Groups "play-framework" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/topic/play-framework/OJBAdiWMc_A/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to play-framewor...@googlegroups.com.

Sebas

unread,
May 10, 2014, 8:07:07 PM5/10/14
to play-fr...@googlegroups.com
Hi James,

Yeah, I already found out that null works, and I know why. But you are correct, I dont know enough about the finer internal workings of play so my first guess obviously was that play changed something internally for java 8. Lets hope it is a Java 8 problem then and that it eventually gets fixed :)

Thanks for your reply.

Sebas

Julien Richard-Foy

unread,
May 10, 2014, 8:30:56 PM5/10/14
to play-fr...@googlegroups.com
> We don't want to continue providing it. WebJars should be used (we should also support Bower at some point).

Ok. But we can also use npm, no? BTW, is it really worth to maintain
WebJars support if we can use the npm module registry, which is more
complete and up to date? Maybe it would save some effort to focus on
one way to handle JavaScript dependencies?

Christopher Hunt

unread,
May 10, 2014, 8:44:39 PM5/10/14
to play-fr...@googlegroups.com
Npm is generally for server side assets whole Bower has a client side focus. Browserify perhaps changes that. WebJars bring their own advantages including the support of existing IT infrastructure. It makes sense for us to support them all and be unopinionated.

Aurélien

unread,
May 11, 2014, 6:09:58 AM5/11/14
to play-fr...@googlegroups.com
Hi,

It seems there is a problem with sbt-less (maybe on windows only), whenever I add
addSbtPlugin("com.typesafe.sbt" % "sbt-less" % "1.0.0-RC1")
in my plugins.sbt file and I run the application, I get :
[trace] Stack trace suppressed: run last *:less for the full output.
[error] (*:less::jstaskShellSource) Could not create directory D:\myproject\project\target\less\file:\D:\dev\ivy\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-less\jars\sbt-less-1.0.0-RC1.jar!
[error] application -

! @6i78m39d1 - Internal server error, for (GET) [/] ->

play
.PlayExceptions$UnexpectedException: Unexpected exception[RuntimeException:
Could not create directory D:\myproject\project\target\less\file:\D:\dev\ivy\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-less\jars\sbt-less-1.0.0-RC1.jar!]

        at play
.PlayReloader$$anon$1$$anonfun$play$PlayReloader$$anon$$taskFailureHandler$1.apply(PlayReloader.scala:295) ~[na:na]
        at play
.PlayReloader$$anon$1$$anonfun$play$PlayReloader$$anon$$taskFailureHandler$1.apply(PlayReloader.scala:287) ~[na:na]

        at scala
.Option.map(Option.scala:145) ~[scala-library.jar:na]

        at play
.PlayReloader$$anon$1.play$PlayReloader$$anon$$taskFailureHandler(PlayReloader.scala:287) ~[na:na]
        at play
.PlayReloader$$anon$1$$anonfun$reload$2.apply(PlayReloader.scala:320) ~[na:na]
Caused by: java.lang.RuntimeException: Could not create directory D:\myproject\project\target\less\file:\D:\dev\ivy\cache\scala_2.10\sbt_0.13\com.typesafe.sbt\sbt-less\jars\sbt-less-1.0.0-RC1.jar!
        at scala
.sys.package$.error(package.scala:27) ~[scala-library.jar:na]

        at sbt
.IO$.createDirectory(IO.scala:155) ~[na:na]
        at sbt
.OpenFile$class.open(Using.scala:45) ~[na:na]
        at sbt
.Using$$anon$2.open(Using.scala:70) ~[na:na]
        at sbt
.Using$$anon$2.open(Using.scala:70) ~[na:na]
[warn] play - No application found at invoker init

When sbt-less is off and only sbt-web is running, I can launch and use my application (without its css :).

Cheers,
Aurélien

Christopher Hunt

unread,
May 11, 2014, 6:39:39 AM5/11/14
to play-fr...@googlegroups.com
There is an issue for this on github. 


Thanks.

Aurélien

unread,
May 11, 2014, 6:49:00 AM5/11/14
to play-fr...@googlegroups.com
Thank you Christopher for your quick answer !

Aurélien

Kevin Bowling

unread,
May 12, 2014, 12:48:53 AM5/12/14
to play-fr...@googlegroups.com

This affects me as well.

Regards,
Kevin

The information in this message may be confidential.  It is intended solely for
the addressee(s).  If you are not the intended recipient, any disclosure,
copying or distribution of the message, or any action or omission taken by you
in reliance on it, is prohibited and may be unlawful.  Please immediately
contact the sender if you have received this message in error.

virtualeyes

unread,
May 12, 2014, 7:14:31 AM5/12/14
to play-fr...@googlegroups.com
JNotify issues with not just FreeBSD, Fedora bails on ctrl-d out of ~run (starting run is fine but exiting fails)

net
.contentobjects.jnotify.linux.JNotifyException_linux: Error removing watch 118
    at net
.contentobjects.jnotify.linux.JNotify_linux.removeWatch(Unknown Source)
    at net
.contentobjects.jnotify.linux.JNotifyAdapterLinux.unwatch(Unknown Source)
    at net
.contentobjects.jnotify.linux.JNotifyAdapterLinux.removeWatch(Unknown Source)
    at net
.contentobjects.jnotify.JNotify.removeWatch(Unknown Source)
    at sun
.reflect.GeneratedMethodAccessor16.invoke(Unknown Source)
    at sun
.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java
.lang.reflect.Method.invoke(Method.java:601)
    at play
.PlayReloader$$anon$1$$anon$6.removeWatch(PlayReloader.scala:95)

Andrew Gaydenko

unread,
May 12, 2014, 9:52:47 AM5/12/14
to play-fr...@googlegroups.com
On Monday, May 12, 2014 3:14:31 PM UTC+4, virtualeyes wrote:
JNotify issues with not just FreeBSD, Fedora bails on ctrl-d out of ~run (starting run is fine but exiting fails)

I guess it takes place under any Linux as far as under Arch Linux I have the issue also during last months.

virtualeyes

unread,
May 12, 2014, 10:06:07 AM5/12/14
to play-fr...@googlegroups.com
You mentioned another thread where Play devs talked about the JNotify issue, where is it?

Would be nice to follow the status.

Andrew Gaydenko

unread,
May 12, 2014, 11:23:31 AM5/12/14
to play-fr...@googlegroups.com


On Monday, May 12, 2014 6:06:07 PM UTC+4, virtualeyes wrote:
You mentioned another thread where Play devs talked about the JNotify issue, where is it?

Would be nice to follow the status.

Sorry, I don't remember where I have met it. Probably, I have just saw the issue subject:
https://github.com/playframework/playframework/issues/2620

virtualeyes

unread,
May 12, 2014, 12:42:08 PM5/12/14
to play-fr...@googlegroups.com
Thanks, just chimed in on the issue, hopefully a workaround of some sort available.

alex s

unread,
May 12, 2014, 2:13:43 PM5/12/14
to play-fr...@googlegroups.com


понедельник, 12 мая 2014 г., 15:14:31 UTC+4 пользователь virtualeyes написал:
JNotify issues with not just FreeBSD, Fedora bails on ctrl-d out of ~run (starting run is fine but exiting fails)

No, it's not the same issue.

virtualeyes

unread,
May 12, 2014, 3:36:18 PM5/12/14
to play-fr...@googlegroups.com
Issues is plural, meaning that JNotify in general has issues, not just the one affecting you (obviously worse because you can't even run play).

alex s

unread,
May 12, 2014, 4:31:07 PM5/12/14
to play-fr...@googlegroups.com


понедельник, 12 мая 2014 г., 23:36:18 UTC+4 пользователь virtualeyes написал:
Issues is plural, meaning that JNotify in general has issues, not just the one affecting you (obviously worse because you can't even run play).

Except mine is not a jnotify (or freebsd) issue :p I've referred to offending commit before, but let me try that again:

commit 21195c918122dac10cbadd90944f13186a204dca
+++ b/framework/src/sbt-plugin/src/main/scala/PlayReloader.scala
@@ -100,7 +101,7 @@


         
} catch {
-          case e: Throwable => {
+          case NonFatal(e) => {


               
"""|


Rich Dougherty

unread,
May 12, 2014, 8:01:57 PM5/12/14
to play-fr...@googlegroups.com
Hi Alex

Would you mind explaining what you'd like to happen here instead? Going from Throwable to NonFatal is usually a good idea, but are you saying that this chance introduced a bug? Or do you mean that there needs to be some different handling code in the catch body?

Cheers
Rich

--
Rich Dougherty - @richdougherty
Typesafe - Reactive apps on the JVM

alex s

unread,
May 12, 2014, 9:13:47 PM5/12/14
to play-fr...@googlegroups.com


On Tuesday, May 13, 2014 4:01:57 AM UTC+4, Rich Dougherty wrote:
> Would you mind explaining what you'd like to happen here instead? Going from Throwable to NonFatal is usually a good idea, but are you saying that this chance introduced a bug?

If you read carefully last 5 messages in https://groups.google.com/forum/#!msg/play-framework/4vII9sQc6kk/Swr2rOaYaRQJ , it seems, that block of code was introduced to handle UnsatisfiedLinkError which is subclass of LinkageError, i.e. doesn't match NonFatal(e).

The FreeBSD case (https://gist.github.com/anonymous/1aa680f2a68cf2f67b8c) should be handled too.

Rich Dougherty

unread,
May 12, 2014, 10:24:17 PM5/12/14
to play-fr...@googlegroups.com
On Fri, May 9, 2014 at 2:35 AM, neverminder <daro...@gmail.com> wrote:
Can someone confirm what's the status of play-slick module, as it was supposed to be integrated into Play 2.3, but I understand that's no longer the case? I'm trying to upgrade one of my projects to Play 2.3 / Scala 2.11 / Slick 2.1, but absence of Scala 2.11 compatible play-slick module is a total showstopper.

Oops, I agree we should do this. I've created an issue to track the task. Feel free to add a comment.


In the meantime, you can use Play 2.3 and Slick 2.1 together, but you'll need to stick to Scala 2.10.

I think we're planning on looking at play-slick integration in Play 2.4 now. We were going to do it in Play 2.3 but it ended up needing bigger changes than we expected so we decided to shift the work to Play 2.4 instead.

Cheers
Rich

Rich Dougherty

unread,
May 12, 2014, 11:25:36 PM5/12/14
to play-framework
Thanks for the explanation. I created a new issue since I couldn't see an existing issue.


Cheers
Rich
 
Message has been deleted

Martina Riehm

unread,
May 13, 2014, 4:59:49 AM5/13/14
to play-fr...@googlegroups.com
I didn't see anything about this in the release notes: has JPA made the default ORM now as was planned or did you stick with EBean?

Angel Scull

unread,
May 13, 2014, 8:37:59 AM5/13/14
to play-fr...@googlegroups.com
How can i download activator with play 2.3 and all the dependencies (not the minimal)

On Thursday, May 8, 2014 1:11:25 AM UTC-4, James Roper wrote:

The Play team is pleased to announce the first release candidate for Play 2.3.0. This release candidate is a feature complete version of Play 2.3.0, but it may have bugs in it. If it has any serious bugs then we’ll put out another release candidate with fixes. Otherwise this release will become Play 2.3.0.


We encourage the Play community to download this release candidate and test it out. See further down this email for instructions.


What’s new in Play 2.3


  1. Introducing the activator command. You can use activator exactly like you would use play, but Activator brings new features too. (More about the Activator change.)

  2. Better tooling for static assets. Play now uses sbt-web which gives faster asset processing, more features, and better extensibility.

  3. Support for Java 8 (and continued support for Java 6 and 7).

  4. Better Java performance. Simple Java controllers give 40–90% better throughput. (Thanks to YourKit for sponsoring licenses.)

  5. Support for Scala 2.11 (and continued support for Scala 2.10).

  6. Anorm enhancements: SQL string interpolation, multi-value parameters, new types, and more.

  7. Web Services enhancements: separate client, SSL configuration, and more.

  8. Play templates have become Twirl templates: separate project, new sbt plugin, still excellent integration with Play

  9. Actors for WebSockets

  10. Custom SSLEngine for HTTPS

  11. Asset performance: faster serving, better caching.

  12. One Result to rule them all: all the result types which were deprecated in 2.2 are now gone and only Result remains.

  13. Lots of bug fixes. :)


For details see the Play 2.3 Highlights and the Play 2.3 Migration Guide.


Testing out Play 2.3


You can help out by testing this release candidate. Discuss issues on the mailing list—use a subject starting with [2.3.0-RC1]—or report bugs on Github.


Using Play 2.3 in a new project


We will use Activator to create a new project from a Play 2.3 template.


Command line instructions


  1. Download the Activator minimal distribution (1MB).

  2. Run activator new.

  3. Enter one of the following template names:

  4. Enter a name for your new project.

  5. Change to the the project directory.

  6. Type activator to reach the console. [Known issue: You may not see any activity for several minutes while new dependencies are being downloaded.]

  7. Use the compile, run, test, etc commands to build and run the project.


Activator UI instructions


Most Activator templates include a tutorial that can be viewed from within the Activator UI. The play-2.3-highlights template has a tutorial that showcases the new features of Play 2.3.


  1. Download the Activator minimal distribution (1MB)

  2. Run activator new.

  3. Enter one of the following template names:

  4. Enter a name for your new project.

  5. Change to the the project directory.

  6. Type activator ui to view the project in a the Activator UI [Known issue: You may not see any activity for several minutes while new dependencies are being downloaded.]

  7. Follow the tutorial on the right of the screen or use the buttons on the left to interact with the project.


Using Play 2.3 in an existing project


See the Play 2.3 Migration Guide for complete instructions on changing your existing project to use Play 2.3.


Known Issues


  1. If there are a large number of assets to be processed by sbt-coffeescript, sbt-less or sbt-jshint then a timeout can occur during asset compilation when using the default JavaScript engine (Trireme). If this occurs then “set JsEngineKeys.parallelism := 1” or use Node instead of Trireme (export SBT_OPTS="$SBT_OPTS -Dsbt.jse.engineType=Node").


Thanks

Play Team


--
James Roper
Software Engineer

Typesafe – Build reactive apps!
Twitter: @jroper

Greg Ederer

unread,
May 13, 2014, 2:42:14 PM5/13/14
to play-fr...@googlegroups.com
Excited about the new release; however, ./activator ~run is eating a lot of CPU time (hovering ~100%). This is on an OS X Mavericks machine.

Cheers,

Greg

virtualeyes

unread,
May 13, 2014, 2:56:17 PM5/13/14
to play-fr...@googlegroups.com
not sure if you can pass flags to activator, but try:
./activator -Dsbt.task.forcegc=false

there's an open SBT issue on this, assume will be resolved without above workaround in the not too distant future given the high cpu usage...

Greg Ederer

unread,
May 13, 2014, 3:03:05 PM5/13/14
to play-fr...@googlegroups.com
That seems to do the trick. Many thanks.

It's interesting to note that the problem occurs when I run ~run; but, not when I run run, which led me to suspect a problem with JNotify. But, your suggestion works.

Cheers,

Greg

Rich Dougherty

unread,
May 13, 2014, 4:29:07 PM5/13/14
to play-framework
On Wed, May 14, 2014 at 7:03 AM, Greg Ederer <gr...@makereal.com> wrote:
That seems to do the trick. Many thanks.

It's interesting to note that the problem occurs when I run ~run; but, not when I run run, which led me to suspect a problem with JNotify. But, your suggestion works.


FYI, here's the issue:


Commands with the "~" prefix are provided by SBT which apparently doesn't use JNotify.

Cheers
Rich

Rich Dougherty

unread,
May 13, 2014, 4:34:03 PM5/13/14
to play-framework
On Wed, May 14, 2014 at 12:37 AM, Angel Scull <scu...@gmail.com> wrote:
How can i download activator with play 2.3 and all the dependencies (not the minimal)

At this point we don't have a full download available, sorry. There will be a full release available for the final release of 2.3.0.

At least one good thing with the new release is that Play 2.3 caches dependencies in ~/.ivy2. In previous releases of Play, dependencies were stored in the Play folder. That meant dependencies couldn't be shared across different versions of Play. Anyway, my point is that when you download Play 2.3.0-RC2 at some point in the future there shouldn't be too many new dependencies to download.

Cheers

Rich Dougherty

unread,
May 13, 2014, 4:36:26 PM5/13/14
to play-framework
On Tue, May 13, 2014 at 8:58 PM, Martina Riehm <t...@cantamen.de> wrote:
I didn't see anything about this in the release notes: has JPA made the default ORM now as was planned or did you stick with EBean?

I think this was mainly planned as a documentation change to emphasise JPA a bit more. But I don't think we made that change in 2.3, at this stage it's something planned for 2.4.

Cheers
Rich

Greg Ederer

unread,
May 13, 2014, 4:38:32 PM5/13/14
to play-fr...@googlegroups.com
That explains it. :)

Cheers,

Greg

virtualeyes

unread,
May 14, 2014, 1:10:27 AM5/14/14
to play-fr...@googlegroups.com
> Commands with the "~" prefix are provided by SBT which apparently doesn't use JNotify.

Don't think that's the case. Anyone on Linux can try to ctrl-d out of ~run and get a lovely JNotify stack trace.

I think the reason for low CPU usage in plain run is due to recompilation being offloaded to the browser (i.e. recompilation does not happen until browser event like a link click), whereas with ~run JNotify monitors source files and directories in real-time.

The bug with ~ commands seems to be that SBT is going hog wild with GC while JNotify is picking up changed files, which leads to high CPU and laggy recompilation.

Anyway, thankfully @retronym came up with the workaround, now the latest and greatest from SBT, Scala, and Play are delivering performance improvements as advertised ;-)

Martina Riehm

unread,
May 14, 2014, 4:17:41 AM5/14/14
to play-fr...@googlegroups.com
I read somewhere that in 2.3 JPA will be the default (for example here https://groups.google.com/forum/#!searchin/play-framework/2.3/play-framework/7pL-Gq_pj7M/UykJdAC6wyYJ). For some reason I thought that this would mean that the play Model base class would be JPA, not ebean, making projects like https://github.com/jensjaeger/play4jpa/ obsolete. But that doesn't seem to actually be in the roadmap (https://docs.google.com/a/cantamen.de/document/d/11sVi1-REAIDFVHvwBrfRt1uXkBzROHQYgmcZNGJtDnA/pub), there it just mentioned documentation as you have written.

So will the play Model base class derive from JPA in 2.4?

naturallog

unread,
May 14, 2014, 4:50:50 AM5/14/14
to play-fr...@googlegroups.com
There is already an sbt 0.13.5-RC3 which switches off the aggressive gc behavior

virtualeyes

unread,
May 14, 2014, 7:48:00 AM5/14/14
to play-fr...@googlegroups.com
Heh, that was fast ;-)

Thanks for the update...

James Roper

unread,
May 15, 2014, 8:57:18 PM5/15/14
to play-framework
On Wed, May 14, 2014 at 6:17 PM, Martina Riehm <t...@cantamen.de> wrote:
I read somewhere that in 2.3 JPA will be the default (for example here https://groups.google.com/forum/#!searchin/play-framework/2.3/play-framework/7pL-Gq_pj7M/UykJdAC6wyYJ). For some reason I thought that this would mean that the play Model base class would be JPA, not ebean, making projects like https://github.com/jensjaeger/play4jpa/ obsolete. But that doesn't seem to actually be in the roadmap (https://docs.google.com/a/cantamen.de/document/d/11sVi1-REAIDFVHvwBrfRt1uXkBzROHQYgmcZNGJtDnA/pub), there it just mentioned documentation as you have written.

So will the play Model base class derive from JPA in 2.4?

The model base class is not needed at all for JPA - a model base class like that doesn't make sense in JPA.  That's just an ebean specific thing.

In practice, the only change that will happen when we make JPA the default is to change the order in the documentation, so JPA appears first.  We will probably also increase the amount of documentation around JPA, update tutorials to use JPA instead of ebean, etc.  So making JPA the default is really only a documentation issue.  From a code perspective, what you get in Play now is how it will always stay.

--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to play-framewor...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Message has been deleted

Rich Dougherty

unread,
May 18, 2014, 7:10:12 AM5/18/14
to play-framework
On Sat, May 17, 2014 at 9:24 PM, Михаил Голубцов <golub...@gmail.com> wrote:
Where is scalaws lib now?
"import play.api.libs.ws.WS" is invalid now. I could not find any dependency for it.

In Play 2.3 the WS module moved into a separate dependency. Check out the "Play WS" section in the migration guide.


Cheers
Rich

Sean Scott

unread,
May 19, 2014, 6:21:18 PM5/19/14
to play-fr...@googlegroups.com
How do accomplish using the CDN functionality available in webjars in Play2.3 ?

I tried prefixing my urls as described  in the webjars docs for Play 2.2, but it didn't work:   http://www.webjars.org/documentation

<script type='text/javascript' src='@routes.Assets.at("lib/angularjs/angular.js")'></script>


became:


<script type='text/javascript' src='@routes.Assets.at("//cdn.jsdelivr.net/lib/angularjs/angular.js")'></script>



And in the HTML I see this:


<script type='text/javascript' src='/assets///cdn.jsdelivr.net/lib/angularjs/angular.js'></script>



Any ideas?


Thanks!


-sean

planetenkiller

unread,
May 20, 2014, 2:54:39 AM5/20/14
to play-fr...@googlegroups.com
I tried to use the separate play-ws jar in my project and it works good except one thing:

In the 'What’s new in Play 2.3' page I read: 
The WS client library has been refactored into its own library which can be used outside of Play. 

play-ws depends on play so this sentence is wrong (Why did you create the play-ws jar? I don't see the difference between 2.2 and 2.3-RC1 (both need full play stack)):
<dependency>
     <groupId>com.typesafe.play</groupId>
     <artifactId>play_2.10</artifactId>
     <version>2.3.0-RC1</version>
</dependency>

James Roper

unread,
May 20, 2014, 3:17:46 AM5/20/14
to play-framework
Currently the CDN functionality is only available when using requirejs.

It could probably be implemented as part of the fingerprinting.

--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To unsubscribe from this group and stop receiving emails from it, send an email to play-framewor...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
James Roper
Software Engineer

Typesafe – Build reactive apps!
Twitter: @jroper

Christopher Hunt

unread,
May 20, 2014, 4:12:35 AM5/20/14
to play-fr...@googlegroups.com
As well as the reverse router, another thing we have on our to-do list at some point is to provide static html and css url substitution as asset pipeline plugins (volunteers anyone?). This could also include CDN url substitution.

You received this message because you are subscribed to a topic in the Google Groups "play-framework" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/play-framework/OJBAdiWMc_A/unsubscribe.
To unsubscribe from this group and all its topics, send an email to play-framewor...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


-- 
Christopher Hunt
Senior Engineer
Typesafe – Build Reactive Apps on the JVM!

Twitter: @huntchr

Message has been deleted

Sean Scott

unread,
May 20, 2014, 11:25:11 AM5/20/14
to play-fr...@googlegroups.com
Dang, ok, Thanks.

-sean

Sean Scott

unread,
May 20, 2014, 11:26:00 AM5/20/14
to play-fr...@googlegroups.com
I presume something is wrong on my end, but I am getting this stack trace and I am not sure why.



! @6i9ipp5fg - Internal server error, for (GET) [/] ->


play.PlayExceptions$UnexpectedException: Unexpected exception[IndexOutOfBoundsException: 28]

at play.PlayReloader$$anon$1$$anonfun$play$PlayReloader$$anon$$taskFailureHandler$1.apply(PlayReloader.scala:295) ~[na:na]

at play.PlayReloader$$anon$1$$anonfun$play$PlayReloader$$anon$$taskFailureHandler$1.apply(PlayReloader.scala:287) ~[na:na]

at scala.Option.map(Option.scala:145) ~[scala-library-2.11.0.jar:na]

at play.PlayReloader$$anon$1.play$PlayReloader$$anon$$taskFailureHandler(PlayReloader.scala:287) ~[na:na]

at play.PlayReloader$$anon$1$$anonfun$reload$2.apply(PlayReloader.scala:320) ~[na:na]

Caused by: java.lang.IndexOutOfBoundsException: 28

at scala.collection.LinearSeqOptimized$class.apply(LinearSeqOptimized.scala:52) ~[scala-library-2.11.0.jar:na]

at scala.collection.immutable.List.apply(List.scala:84) ~[scala-library-2.11.0.jar:na]

at play.twirl.sbt.TemplateProblem$TemplatePosition$.apply(TemplateProblem.scala:37) ~[na:na]

at play.twirl.sbt.TemplateProblem$.exception(TemplateProblem.scala:19) ~[na:na]

at play.twirl.sbt.TemplateCompiler$$anonfun$handleError$1.applyOrElse(TemplateCompiler.scala:57) ~[na:na]

java.lang.IndexOutOfBoundsException: 28

at scala.collection.LinearSeqOptimized$class.apply(LinearSeqOptimized.scala:52)

at scala.collection.immutable.List.apply(List.scala:84)

at play.twirl.sbt.TemplateProblem$TemplatePosition$.apply(TemplateProblem.scala:37)

at play.twirl.sbt.TemplateProblem$.exception(TemplateProblem.scala:19)

at play.twirl.sbt.TemplateCompiler$$anonfun$handleError$1.applyOrElse(TemplateCompiler.scala:57)

at play.twirl.sbt.TemplateCompiler$$anonfun$handleError$1.applyOrElse(TemplateCompiler.scala:55)

at scala.runtime.AbstractPartialFunction.apply(AbstractPartialFunction.scala:33)

at play.twirl.sbt.TemplateCompiler$.compile(TemplateCompiler.scala:28)

at play.twirl.sbt.SbtTwirl$$anonfun$compileTemplatesTask$1.apply(SbtTwirl.scala:77)

at play.twirl.sbt.SbtTwirl$$anonfun$compileTemplatesTask$1.apply(SbtTwirl.scala:76)

at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47)

at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:42)

at sbt.std.Transform$$anon$4.work(System.scala:64)

at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:237)

at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:237)

at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:18)

at sbt.Execute.work(Execute.scala:244)

at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:237)

at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:237)

at sbt.ConcurrentRestrictions$$anon$4$$anonfun$1.apply(ConcurrentRestrictions.scala:160)

at sbt.CompletionService$$anon$2.call(CompletionService.scala:30)

at java.util.concurrent.FutureTask.run(FutureTask.java:266)

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

at java.util.concurrent.FutureTask.run(FutureTask.java:266)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

at java.lang.Thread.run(Thread.java:744)

[error] (root/compile:twirlCompileTemplates) java.lang.IndexOutOfBoundsException: 28

[error] application - 

Sean Scott

unread,
May 20, 2014, 11:29:06 AM5/20/14
to play-fr...@googlegroups.com
Ok, to answer my own question... I had a syntax error error in a template.


    <link rel='stylesheet' href='@routes.Assets.at("stylesheets/less/main.css'>

Should have been

    <link rel='stylesheet' href='@routes.Assets.at("stylesheets/less/main.css")'>



Didn't 2.2 give you a better error?



Thanks!


-sean

Will Sargent

unread,
May 20, 2014, 12:11:20 PM5/20/14
to play-fr...@googlegroups.com
That should be "used outside of a play.api.Application context."  You still need all the Play libraries.

Will Sargent
Consultant, Professional Services
Typesafe, the company behind Play Framework, Akka and Scala


--

Chanan Braunstein

unread,
May 21, 2014, 1:31:29 PM5/21/14
to play-fr...@googlegroups.com
Looks like something broke in windows. Previously this worked. I downloaded activator 1.1.3 today and started a new app using the play-java-preview template. Went into the folder and did activator compile. I get an error:

Error: Unable to access jarfile C:\Java\Gradebook-Services\\activator-launch-1.1.3.jar

Note the double slash after my app name. 

Workaround: If I rename activator.bat in my app folder and use the "global" activator it works fine. Looks like the activator.bat that gets put in the app folder has an error in it.

Rich Dougherty

unread,
May 21, 2014, 8:25:47 PM5/21/14
to play-framework
On Tue, May 13, 2014 at 3:25 PM, Rich Dougherty <ri...@rd.gen.nz> wrote:
On Tue, May 13, 2014 at 1:13 PM, alex s <iwt...@gmail.com> wrote:
If you read carefully last 5 messages in https://groups.google.com/forum/#!msg/play-framework/4vII9sQc6kk/Swr2rOaYaRQJ , it seems, that block of code was introduced to handle UnsatisfiedLinkError which is subclass of LinkageError, i.e. doesn't match NonFatal(e).

The FreeBSD case (https://gist.github.com/anonymous/1aa680f2a68cf2f67b8c) should be handled too.

Thanks for the explanation. I created a new issue since I couldn't see an existing issue.


Hi Alex

I've implemented a fix for this. Would you mind testing it when the next RC comes out? Or you can test directly off master if you like. :)

Cheers
Rich

--
Rich Dougherty - @richdougherty
Engineer - Typesafe, Inc

Adithya C

unread,
May 22, 2014, 8:29:59 AM5/22/14
to play-fr...@googlegroups.com
having a problem testing 2.3.0-RC1, things I followed:

1.) Downloaded activator-1.1.3-minimal
2.) Tried using these templates in "activator new"  : play-2.3-highlights, play-java-preview, play-scala-preview
3.) Tried to run using "activator run"

Most dependencies got downloaded fine, except the hawtjni-runtime plugin, gave me the following unresolved dependency exception : 

sbt.ResolveException: unresolved dependency: org.fusesource.hawtjni#hawtjni-runtime;${hawtjni-version}: not found

alex s

unread,
May 22, 2014, 3:05:58 PM5/22/14
to play-fr...@googlegroups.com


четверг, 22 мая 2014 г., 4:25:47 UTC+4 пользователь Rich Dougherty написал:

Hi Alex

I've implemented a fix for this. Would you mind testing it when the next RC comes out? Or you can test directly off master if you like. :)

Yes, this is indeed a non-issue in RC2. Thanks for the fix.

Rich Dougherty

unread,
May 22, 2014, 9:01:53 PM5/22/14
to play-framework
On Fri, May 23, 2014 at 7:05 AM, alex s <iwt...@gmail.com> wrote:
I've implemented a fix for this. Would you mind testing it when the next RC comes out? Or you can test directly off master if you like. :)

Yes, this is indeed a non-issue in RC2. Thanks for the fix.


You're welcome. I hope you enjoy using Play on FreeBSD!

Cheers
Rich
Message has been deleted

Steve Lustbader

unread,
Jul 3, 2014, 11:56:16 AM7/3/14
to play-fr...@googlegroups.com
Did you ever get a response to this? I'm wondering why play-ws depends on play, too, since that seems to defeat the purpose of separating them.
Reply all
Reply to author
Forward
0 new messages