Re: [racket-users] How to use the web-server package without continuations?

2015-09-01 Thread Jay McCarthy
On Tue, Sep 1, 2015 at 10:03 AM, Ben  wrote:
> Hi,
>
> I'm trying to build a web application using Racket.  But I don't understand
> continuations yet.  I think the package is capable of writing simple
> applications without continuations.  So
>
> 1. Which part of the web-server package should I stay away from if I don't
> want to use continuations?

The web-server/servlet module

> 2. Why not separate the basic functionalities of handling requests and
> sending responses out from the package?  I think the advanced concepts like
> continuations will scare some beginners like me away.

It is divided in the way you suggest. The only things that require
continuations are the functions in web-server/servlet, all other
functions and modules do not use them.

> 3. I'm actually interested in continuation.  Are there any resources to
> learn about it?

The tutorial discusses them: http://docs.racket-lang.org/continue/index.html

> 4. URLs like 'standalone.rkt;(("k" . "(1 3 49600023)"))' is not pretty in my
> eye. Is it possible to make it "standalone.rkt" if I'm programming in the
> continuation style?

Yes, but the continuation encoding has to be somewhere in the request.
It could be in the URL (the default), it could be in a hidden form
field, in POST data, in an HTTP header, etc. For everything other than
the URL, you need to have special HTML application support to put it
in the right spot.

Jay

> Thanks,
> Ben
>
> --
> You received this message because you are subscribed to the Google Groups
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



-- 
Jay McCarthy
http://jeapostrophe.github.io

   "Wherefore, be not weary in well-doing,
  for ye are laying the foundation of a great work.
And out of small things proceedeth that which is great."
  - D&C 64:33

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[racket-users] How to use the web-server package without continuations?

2015-09-01 Thread Ben
Hi,

I'm trying to build a web application using Racket.  But I don't understand
continuations yet.  I think the package is capable of writing simple
applications without continuations.  So

1. Which part of the web-server package should I stay away from if I don't
want to use continuations?

2. Why not separate the basic functionalities of handling requests and
sending responses out from the package?  I think the advanced concepts like
continuations will scare some beginners like me away.

3. I'm actually interested in continuation.  Are there any resources to
learn about it?

4. URLs like 'standalone.rkt;(("k" . "(1 3 49600023)"))' is not pretty in
my eye. Is it possible to make it "standalone.rkt" if I'm programming in
the continuation style?

Thanks,
Ben

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.