[racket] web server: module servlets
Hi Jay,
On 9/23/2014 6:04 PM, Jay McCarthy wrote:
> On Tue, Sep 23, 2014 at 4:42 PM, George Neuner <gneuner2 at comcast.net> wrote:
> >
> > 1) Is there any way to speed up initial [module] servlet loading?
>
> This is why I recommend that new users use serve/servlet, which is
> much faster because it does not use namespaces or live loading.
That's an option for a finished application ... if a web application
ever really can
be said to be finished ... but it's tough when you're developing.
I guess the question is "where is all the time spent"? Loading required
modules
from the library I suppose?
Not really knowing much about Racket's internals he naively asks: Could
a server
pre-load the commonly used webserver modules and make them available
to new module servlets, or does the custodian implementation make doing
that
difficult/impossible?
> > 2) Debugging module servlets is a pain due to having to stop/restart
> > the server. Is there some clever way to force the server to unload a
> > particular servlet but keep running?
>
> Doing this pretty much requires not following my advice in question 1,
> but the default server (used by the command line tool) allows you to
> go to "/conf/refresh-servlets" and unload/reload all the servlet code.
That might help. Does unloading & reloading affect a stateless servlet
that isn't
been changed? More to the point, can you stop/restart the server and
continue
a stateless servlet?
My application so far is based on stateful servlets and AJAX ...
stateful mainly because
it's easier for me to understand. Currently there is little use of
continuations, but
some planned functionality will use them extensively and it certainly
would help if
debugging didn't always mean starting over setting up conditions in the
application.
George
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20140923/187c2d08/attachment.html>