Skip to main content

All Questions

0 votes
1 answer
503 views

understanding async calls in java play

Trying to make an API in java play framework 2.8. I do not know what is wrong with the code I wrote but it doesnt work. I get this response in localhost:9000 {"result":null,"stack":null,"done":...
Avishai Yaniv's user avatar
0 votes
1 answer
71 views

How can i gather results from F.promise and use that

I am using play framework for java application. I am make a async call using F.promise and I want to take the results from that call and perform some actions. How can i do this? There is a method in ...
kaushik kumar's user avatar
0 votes
1 answer
419 views

How to accept a WebSocket asynchronously?

I have an Play application that handles WebSocket requests. The routes file contains this line: GET /testsocket controllers.HomeController.defaultRoomSocket An already working, synchronous version ...
daro's user avatar
  • 3
1 vote
0 answers
48 views

Moving the HTTP Response responsibility to different methods in a Play Framework REST API

I'm currently working on a proof of concept for a fully a-synchronous Message based (Akka) REST API. Except I'm already running into some issues with the way the Play framework handles requests. From ...
cayote's user avatar
  • 11
0 votes
0 answers
454 views

How to pass in multiple arguments in Java Lambda BiFunctions using Async?

I'm working with a PlayFramework example but I'm having trouble with the asynchronous calls. The function thenCombineAsync seems to only take in a BiFunction. I'd like to pass in multiple arguments to ...
tikitaka's user avatar
1 vote
1 answer
1k views

Execute CompletableFuture which depends on an other task

I wrote a Play framework web application and I have the following problem. I have some DAOs that access the database, and sometimes one request to the database relies on information from another ...
Steinliiippp's user avatar
1 vote
1 answer
77 views

Play Framework 2.4.x execute a save operation in a callback function

I'm a newbie using play framework and I need some help because I cannot find the reason why the code is not updating the address stored in the database. I can see the log indicating success but I don'...
Rogelio Blanco's user avatar
0 votes
1 answer
851 views

play framework 2.6 ws cannot resolve

I use play framework 2.6 I need to send a http request to an url, so I use WS for sending this request first I add below line to sbt.build libraryDependencies += ws but in controller play cannot ...
Majid Lotfinia's user avatar
5 votes
1 answer
436 views

play framework - render view while doing processing/redirect after X seconds

note: I am new to play framework For my Play! project, I require some form of asynchronous programming. Simply, I need to display a view, whilst doing processing in the background, followed by a ...
CybeX's user avatar
  • 2,436
0 votes
1 answer
623 views

Play Framework - balancing asynchronous and non-blocking

I'm looking for a light-bulb moment but haven't had it yet! Using Play Framework 2.5.9 with Java 8 and trying to follow good practice with an asynchronous, non-blocking model. So my play app exposes ...
CodeClimber's user avatar
  • 4,664
0 votes
0 answers
712 views

Play framework: return a CompletableFuture<CompletableFuture<Result>>?

Is it possible to return a CompletableFuture<CompletableFuture<Result>> to the Play framework? Below is my action code: @BodyParser.Of(BodyParser.Json.class) public CompletableFuture<...
simplyblue's user avatar
  • 2,347
2 votes
1 answer
534 views

Action composition and async in Play Framework 2.5 in Java

I want to create an action that I can use with the @With annotation style. This action will need to proceed to an RPC call so if I understood correctly the documentation I should rather put this in an ...
Martin GOYOT's user avatar
6 votes
0 answers
5k views

Returning common Result as CompletionStage<Result> in play

In my view function I may return a Result or a CompletionStage<Result> based on whether or not the post/get data is valid or not: if (data.hasErrors()) { return badRequest(myview.render(...
Nitzan Tomer's user avatar
3 votes
0 answers
102 views

PlayFramework with Morphia?

PlayFramework is a NonBlockingIO application architecture whereas Morphia (driver for MongoDB) is not a non blocking IO. If I am not wrong then playframeworks MVC architecture works in following way: ...
Amit Pal's user avatar
  • 11.1k
1 vote
1 answer
225 views

Scala play framework and NIO.2

I'm programming in scala to develop a web application using play framework 2.5.3, and I need to create a TCP server/client which will take advantage of play's asynchronous model. After a bit of ...
Francis's user avatar
  • 379

15 30 50 per page