I'd like to delay http response sent to the user. Naive solution is to use Thread.sleep but it will starve the application out threads. Is it possible to do it in more graceful way ?
--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code
Well both, I can solve my problem different way but would like to know if that is possible in Lift and if not how that could be done, sounds to me like some continuations stuff maybe but I don't know how requests are handled that deeply.Ok so our problem is to prevent spamming our login page with requests. Some sites give captcha after few unsuccessful log in attempts. I thought in first about delay after few. It should prevent it but captcha solution might be good here as well.
On Saturday, May 19, 2012 5:44:43 PM UTC+2, David Pollak wrote:On Sat, May 19, 2012 at 1:32 AM, Lukasz Kuczera <kuk...@gmail.com> wrote:I'd like to delay http response sent to the user. Naive solution is to use Thread.sleep but it will starve the application out threads. Is it possible to do it in more graceful way ?Are you talking about a full page load or a REST request? Why the delay?--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code
--Visi.Pro, Cloud Computing for the Rest of Us http://visi.proLift, the simply functional web framework http://liftweb.net
--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code
I'd expect nasty user to do that. It would take our site down if launched properly am I right ?
Thanks for hearty response. Indeed we are not afraid of it now, but looking into the future and was wandering about potential ways to go around. Our company is built on top of "security" so we have to take it seriously.