views:

775

answers:

3

I would like to to choose one of these languages for building web applications. I'm not interested in framework per se, but have the following needs:

  • Rapid development.
  • Easy to scale.
  • Strong community for the web.
  • Quick and easy to deploy.

I'm very familiar with Haskell, and have some familiarity with scheme (in particular PLT). Scheme appeals to me as good candidate for web development due to it's simple syntax which is homogenous across libraries. I state this despite my subjective opinion that Haskell is a 'cleaner' language.

Haskell web apps seem to require learning and building a patchwork of different combinator libraries. On the plus side, I realise this can be quite expressive, although I'd prefer to eliminate impedance mismatches where possible.

While scheme-plt looks to be a good fit, I can find but one example of it being used in the "real world". Haskell doesn't seem to fair too much better here, but there seems to be a bigger community behind the web side.

Please help me make up my mind. For the most part I'm interested in real-world use cases.

+12  A: 

Sounds like you want people to make the case for the various languages and toolchains for you. Well, here's what I know about Haskell -- there's a lot of people, tools and experience to help you out:

I think there's no choice, really.

Don Stewart
Cheers for speedy reply Don, and also for your contributions to Haskell. I'll give happstack another look. Since I'm more familiar with Haskell I also wanted to see what life is like on the scheme side pertaining to the web.
Robert E. Lester
Note that happstack 0.5 was released this week, so some of the backing material may be lagging: http://www.haskell.org/pipermail/haskell-cafe/2010-May/077218.html
Don Stewart
+10  A: 
Norman Ramsey
Agreed. There is so much stuff the choice is a problem.I'd start with the happstack tutorial: http://tutorial.happstack.com/
Don Stewart
@Don: I already upvoted your answer, but why don't you edit it to suggest to people that http://tutorial.happstack.com is the right thread to pull on first? (I'd edit it myself but it feels impolite.)
Norman Ramsey
Well, happstack is a framework, and the OP states they're not specifically interested in frameworks.
Don Stewart
@Don: Ah. I don't think I even know what the work "framework" really means. Is it the same as "library", only dressed up to go out? Or claiming to solve all your problems?
Norman Ramsey
@Norman Ramsey: It's sort of a reversal--a framework is usually more "an application with pieces missing", managing all the core control flow and infrastructure, calling out into user code as needed for custom behavior. In the case of building a GUI, for instance, a "framework" would generally control the main event loop and communication with the windowing system. Development with a framework tends to involve a skeleton application that's customized from outside in, rather than building up from a base. Give or take, at any rate, the term can be a bit hand-wavy sometimes...
camccann
+12  A: 

Hi Robert,

[Note: We have renamed "PLT Scheme" to "Racket"; I will refer to it as that.]

"Rapid development."

I find Racket great for rapid development. If you follow the Continue tutorial on using Racket for Web, I think you will as well. You can start prototyping your application without ever saving a file, it's easy to integrate the many packages on PLaneT, and macros remove the burden of ever writing boiler-plate more than once.

"Easy to scale."

I've done a lot of research into scaling Web applications written in Racket. Racket Web applications can use stateful continuations (recorded in the server's RAM) or stateless (recorded in a serializable format and stored by users or databases/etc) or any combination of the two. A brief summary of these distinctions is described in the documentation. For each regime there are an assortment of ways of dealing with scale, such as stateful continuation management policies and stateless stuffers.

I've put a lot of thought into making the defaults scale well, but also easy enough to change for your circumstances.

On the less Web-specific front, we have native support for trendy scalable databases like MongoDB and memcached.

"Strong community for the web."

Apart from usage of our software in education, it seems we are most often deployed on the Web. If you scan through PLaneT you'll see a preponderance of Web-related libraries. I'm not sure of another metric for you.

"Quick and easy to deploy."

I think the rapid development point speaks to this. If you have other questions related to deployment, I'm happy to answer.

"I can find but one example of it being used in the 'real world'."

The guys at Untyped have a few products using it. I've written two commercial sites and at least four other reasonably large community sites. We know of a dozen or so contractors building applications using it. There are a few startups I've talked to that are using it as well. There's no point pretending we're as common as Python or Ruby, etc, but we're not purely academic or theoretical either.

If you have any other questions, feel free to email me directly or the mailing list, so others in our community can more easily benefit from the discussion. Happy hacking!

Jay McCarthy