Questions tagged [playframework-2.6]

Play is based on a lightweight, stateless, web-friendly architecture and features predictable and minimal resource consumption (CPU, memory, threads) for highly-scalable applications.

Play is based on a lightweight, stateless, web-friendly architecture and features predictable and minimal resource consumption (CPU, memory, threads) for highly-scalable applications.

What's new in Play 2.6

Migration Guide

307 questions
19
votes
1 answer

Getting Java Play framework to cache Ebean entities using memcached

I am running Java Play framework version v2.6.1 and using Ebean for persistence. My intention is to get bean caching going using play2-memcached plugin. What have I done so far? installed memcached on localhost and enabled verbose logging. replaced…
mindas
  • 25,644
  • 13
  • 93
  • 149
10
votes
2 answers

How to apply play-evolutions when running tests in play-framework?

I have problems with evolutions when running tests in play framework using playframework v2.6.6 for scala play-slick v3.0.2 play-slick-evolutions v3.0.2 The test looks like this: class TestFooController extends PlaySpec with GuiceOneServerPerSuite…
9
votes
2 answers

Content Security Policy headers in Play! Framework

I have a question on the Content Security Policy using the Play! framework (2.6). I have added an external library to the project for drawing charts, the javascript file is in the project and the charts are rendering fine. The problem I am having…
7
votes
1 answer

Using JWT authentication with Play Framework 2.6

I'm having issues with using JWT Authentication using guides for older versions but I'd like to focus on the new Play 2.6 According to the official documentation, JWT is now used under the hood. It seems like there would be an easier way instead of…
LtDan33
  • 183
  • 1
  • 10
6
votes
1 answer

play 2.6 auto-reload doesn't show changes after first compile

When I execute sbt run and refresh, localhost:9000 will show my changes. If i change something else, save my project and hit refresh again localhost:9000 does not show my changes. If i try sbt ~run I can see sbt recompiling every time i change a…
plambre
  • 5,568
  • 2
  • 15
  • 30
5
votes
0 answers

Play 2.6 Ebeans relationship error

Posts Model /*set many to one relation with Privacy_Level model*/ @ManyToOne//(fetch = FetchType.LAZY) @JoinColumn(name = "privacy_level_id",referencedColumnName = "id", insertable = false, updatable = false) public Privacy_Level…
CraZyDroiD
  • 5,264
  • 21
  • 64
  • 138
5
votes
2 answers

Play Framework sbt assembly jar running error :- "No root server path supplied"

I built play framework project jar with sbt assembly command. when I run the jar with Java -jar "jarName.jar" it throws error "No root server path supplied" any suggestions ?
4
votes
0 answers

Does "EntityStreamException: Entity stream truncation" simply mean client timeout?

Since upgrading to Play 2.6, I'm seeing a lot of "EntityStreamException: Entity stream truncation" in our logs. It looks to strongly correlate with a client timeout, which is not alarming. It is a little alarming to have an Exception bubble up to…
Adam Rabung
  • 5,184
  • 2
  • 24
  • 42
4
votes
0 answers

How to stop the actor when event source flow is closed?

I'm creating a EventSourceActor for each event source connection, and this actor create a eventsource flow. When the client calls eventsource.close(), I want the actor to be notified and close itself. I've tried to use Flow.watchTermination, but the…
徐辰曦
  • 41
  • 1
4
votes
1 answer

Play Framework and autogenerated evolutions

I love bootstrapping projects with Play! Ebean, in memory database : evolutions generates automatically when I need a new model, this is awesome. I am learning Play Scala, and there is a lack of support between Ebean and Scala It can work, with…
Julien D
  • 1,219
  • 9
  • 20
4
votes
1 answer

What does DefaultUrlEncodedCookieDataCodec mean

I am getting the following error when a request is send to the server. What does this message mean and how could I solve this. p.a.m.DefaultUrlEncodedCookieDataCodec - Cookie failed message authentication check I am trying to integrate Silhouette in…
Manu Chadha
  • 11,886
  • 11
  • 51
  • 115
4
votes
2 answers

How can I get content from InputStream based results in Play tests

I am on Play 2.6, using Java My controller returns: public Result xml() { return Results.ok(new ByteArrayInputStream("".getBytes())); } I want to parse the result in tests: Result result = new MyController().xml(); …
apflieger
  • 408
  • 3
  • 9
4
votes
2 answers

Unit testing a controller in Play 2.6

I'm getting a null pointer exception when trying to test a controller in Play 2.6 in Scala. This is a test for an OK response: class ApplicationControllerSpec extends PlaySpec with MockitoSugar with ScalaFutures { val mockOrchestrator =…
ChazMcDingle
  • 535
  • 1
  • 7
  • 18
3
votes
1 answer

Dockerizing play framework

My docker compose file is: version: '3' services: postgres: container_name: crm-psql image: postgres:9.3 restart: always environment: - POSTGRES_DB=crm - POSTGRES_USER=root - POSTGRES_PASSWORD=root volumes: -…
androider
  • 856
  • 4
  • 15
  • 30
3
votes
1 answer

Play framework Scala: Create infinite source using scala akka streams and keep Server sent events connection open on server

We have requirement to implements server sent events for following uses cases: Send notification to UI after some processing on server. This processing is based on some logic Send notification to UI after reading messages from RabbitMQ followed by…
1
2 3
20 21