[2.1.5-scala] action without a response

61 views
Skip to first unread message

Razvan Cojocaru

unread,
Oct 22, 2013, 1:35:08 AM10/22/13
to play-fr...@googlegroups.com
is it possible for an Action to complete without a response? Code-wise, the only way is via an exception - however, I know even those are logged.
 
the following log file demonstrates that an Action ended wihtout a reponse:
 
- you see this thread: play-akka.actor.default-dispatcher-87 simply terminates in the first request, without the log indicating sending the reply - which would be something like this: 2013-10-21 19:28:44,440 TRACE [play-internal-execution-context-2] play: Sending simple result: SimpleResult(200, Map(Con
tent-Type -> text/html; charset=utf-8))
 
that same thread 87 is simply re-used a few seconds later to process a completely differnet request, although the first one never sent a reply to the client browser - which is why I was looking at the log file in the first place...
 
Cookie: PLAY_SESSION="9bc0ce6e8253ae8aa101475c907b6ff229d5ae15-connected=j7BNek9U5iAg3eCy5XJNvg"; __utmc=61195567; __utm
a=61195567.1405362193.1382283682.1382382853.1382395258.8; __utmz=61195567.1382283682.1.1.utmcsr=(direct)|utmccn=(direct)
|utmcmd=(none); __utmb=61195567.18.10.1382395258
X-Forwarded-For: 184.151.190.169
X-Forwarded-Host: www.racerkidz.com
X-Forwarded-Server: www.racerkidz.com
Connection: Keep-Alive
Content-Length: 442
2013-10-21 19:27:58,275 INFO  [New I/O worker #7] clog: <<  ROUTE_REQ: POST /wikie/edited/Race:Friday_training_date_Dec_
7,2014_at_Mt_St_Louis_Moonstone_Ski_by_Glacier_Ski_Club
2013-10-21 19:27:58,275 INFO  [New I/O worker #7] razie: BINDER Race:Friday_training_date_Dec_7,2014_at_Mt_St_Louis_Moon
stone_Ski_by_Glacier_Ski_Club
2013-10-21 19:27:58,276 TRACE [New I/O worker #7] play: Serving this request with: <function1>
2013-10-21 19:27:58,276 TRACE [play-akka.actor.default-dispatcher-87] play: Parsing AnyContent as urlFormEncoded
2013-10-21 19:27:58,278 TRACE [play-akka.actor.default-dispatcher-87] play: Invoking action with request: POST /wikie/ed
ited/Race:Friday_training_date_Dec_7,2014_at_Mt_St_Louis_Moonstone_Ski_by_Glacier_Ski_Club
2013-10-21 19:27:58,279 INFO  [play-akka.actor.default-dispatcher-87] Wiki: Wiki.save [[Race:Friday_training_date_Dec_7,
2014_at_Mt_St_Louis_Moonstone_Ski_by_Glacier_Ski_Club]]
2013-10-21 19:27:58,279 INFO  [play-akka.actor.default-dispatcher-87] clog: <<  dbop.BEFORE for findOne WikiEntry catego
ry -> Race,name -> Friday_training_date_Dec_7,2014_at_Mt_St_Louis_Moonstone_Ski_by_Glacier_Ski_Club
2013-10-21 19:27:58,280 INFO  [play-akka.actor.default-dispatcher-87] clog: <<  dbop.AFTER 1 millis for findOne WikiEntr
y category -> Race,name -> Friday_training_date_Dec_7,2014_at_Mt_St_Louis_Moonstone_Ski_by_Glacier_Ski_Club
2013-10-21 19:27:58,281 DEBUG [play-akka.actor.default-dispatcher-87] RazAuthService: AUTH SESSION.connected=Some(j7BNek
9U5iAg3eCy5XJNvg)
2013-10-21 19:27:58,281 DEBUG [play-akka.actor.default-dispatcher-87] RazAuthService: AUTH SESSION.connected=Some(j7BNek
9U5iAg3eCy5XJNvg)
 
//-------------- there is no gap in log file here - just that it now switches to handling a different request below - above there is no reply sent to client
// also, the thread should have done a lot more --- instead, it just stops doing what it was doing...

2013-10-21 19:28:44,401 TRACE [New I/O worker #8] play: Http request received by netty: DefaultHttpRequest(chunked: fals
e)
GET /wiki/Post:Blipping_the_Throttle HTTP/1.1
Host: cloud3.apefsjdolj.ro:9000
Referer: http://ventelnos.com/
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1) Opera 7.54 [en]
X-Forwarded-For: 91.207.4.206
X-Forwarded-Host: www.racerkidz.com
X-Forwarded-Server: www.racerkidz.com
Connection: Keep-Alive
2013-10-21 19:28:44,402 INFO  [New I/O worker #8] clog: <<  ROUTE_REQ: GET /wiki/Post:Blipping_the_Throttle
2013-10-21 19:28:44,402 INFO  [New I/O worker #8] razie: BINDER Post:Blipping_the_Throttle
2013-10-21 19:28:44,403 TRACE [New I/O worker #8] play: Serving this request with: <function1>
2013-10-21 19:28:44,403 TRACE [play-akka.actor.default-dispatcher-87] play: Parsing AnyContent as empty
2013-10-21 19:28:44,403 TRACE [play-akka.actor.default-dispatcher-87] play: Invoking action with request: GET /wiki/Post
:Blipping_the_Throttle
2013-10-21 19:28:44,404 DEBUG [play-akka.actor.default-dispatcher-87] RazAuthService: AUTH SESSION.connected=None
2013-10-21 19:28:44,404 DEBUG [play-akka.actor.default-dispatcher-87] Wiki: show2 Post:Blipping_the_Throttle
2013-10-21 19:28:44,404 INFO  [play-akka.actor.default-dispatcher-87] clog: <<  dbop.BEFORE for findOne WikiEntry catego
ry -> Post,name -> Blipping_the_Throttle
2013-10-21 19:28:44,406 INFO  [play-akka.actor.default-dispatcher-87] clog: <<  dbop.AFTER 2 millis for findOne WikiEntr
 
cheers - I would appreciate some direction here...
 

Ryan Tanner

unread,
Oct 22, 2013, 5:44:16 PM10/22/13
to play-fr...@googlegroups.com
What would be the use case for this?  Even if you don't have any content to return, you should at least return *something* to the client so they know that request is complete, even if it's just an empty 200.

Razvan Cojocaru

unread,
Oct 22, 2013, 9:17:05 PM10/22/13
to play-fr...@googlegroups.com

– that’s what’s puzzling. It shouldn’t happen, yet it did… I’m having very annoying stability issues – it’s getting stuck all over the place, once thought impossible with the quasi-single threaded processing and low traffic etc… and it’s not easy to figure out what I’m doing wrong… this however only happens on my Ubuntu “production” server – I am upgrading everything to the latest versions now, JVM etc.

 

Cheers

--
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/78h__ltBwwo/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/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages