caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Which development framework for web application in OCaml?
@ 2006-06-23 16:18 David MENTRE
  2006-06-23 16:24 ` [Caml-list] " Richard Jones
  2006-06-28 17:41 ` Samuel Mimram
  0 siblings, 2 replies; 14+ messages in thread
From: David MENTRE @ 2006-06-23 16:18 UTC (permalink / raw)
  To: Ocaml

Hello,

For my demexp server, I'm considering the development of a web
interface, accessible from a simple web browser. I have standard
requirements (html forms) as well as "advanced" ones (would like to
support AJAX-like things, navigation in tree data structures, etc.).
Which development frameworks are available to do such things in OCaml?
I'm looking for frameworks under a license compatible with GNU GPL.

Right now, I know about:
 - WDialog
 - XCaml

For low level stuff (basic CGI interface), there is also OCamlNet.

I've made some experiments with WDialog but I'm not entirely convinced
by its approach of separating interface description from event
handling code. Moreover it lacks some features that would be useful
for us : i18n support (even if, thanks to Gerd, a preliminary code is
available in CVS tree), advanced widgets (tree structures), AJAX
support, etc.

What other people are using to do web stuff? Is everybody using PHP? ;-)

Any recommandation on building such complex web interface with
available OCaml software?

Best regards,
david

PS : My current demexp server is an autonomous Unix daemon, written in
OCaml, accessible through ONC RPC calls over a TCP socket. Until know,
I have made a simple CGI that access the demexp server. But I'm
considering merging the server part with the web part. Has somebody
some knowledge on the design of web architecture and recommendation or
pointer to relevant litterature?


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-23 16:18 Which development framework for web application in OCaml? David MENTRE
@ 2006-06-23 16:24 ` Richard Jones
       [not found]   ` <9d3ec8300606251007k2508a880me5ca863de4bbfef3@mail.gmail.com>
  2006-06-28 17:41 ` Samuel Mimram
  1 sibling, 1 reply; 14+ messages in thread
From: Richard Jones @ 2006-06-23 16:24 UTC (permalink / raw)
  To: David MENTRE; +Cc: Ocaml


Don't forget mod_caml!  http://www.merjis.com/developers/mod_caml/

Rich.

-- 
Richard Jones, CTO Merjis Ltd.
Merjis - web marketing and technology - http://merjis.com
Team Notepad - intranets and extranets for business - http://team-notepad.com


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
       [not found]   ` <9d3ec8300606251007k2508a880me5ca863de4bbfef3@mail.gmail.com>
@ 2006-06-26 13:23     ` David MENTRE
  0 siblings, 0 replies; 14+ messages in thread
From: David MENTRE @ 2006-06-26 13:23 UTC (permalink / raw)
  To: Till Varoquaux; +Cc: Ocaml

Hello Till,

2006/6/25, Till Varoquaux <till.varoquaux@gmail.com>:
> There is an ongoing project (which I'm part of) to make a web
> framework for cduce. You can check it out here:
> http://reglisse.ens.fr/ecduce/
> We (me for the ecduce part, the cduce team for cduce) would be more
> than happy to help you out.

Thank you for the pointer, even if, right now, I have some issue to
understand how an XML toolkit could help me design a dynamic web site.

BTW, the ECDuce pages lack a little description on the aim of the project.

> P.S. IMHO, although Cduce is a little rough around the edges, going
> back to php afterwards is about as painfull as moving back from Caml
> to C...

I'm already using CDuce to read/write XML files in my server. So I'm
suppose to already know it. ;-)

> P.P.S as for the ajax and toolkit abstraction you might want to have a
> look at openlaszlo http://www.openlaszlo.org/. An integration with an
> xml oriented should be quite easy to do...

Well... I've looked at OpenLazlo and I'm quite skeptical on such a
framework. Non-withstanding that OpenLazlo is aimed at Flash
environment and that DHTML support is apparently still under
development, I'm not really fond of technology targetting only
Javascript-only web browser. I would like to develop my web site for
both new and old browsers. Moreover, OpenLazlo servers are in Java,
and using XML has a programming language seems a bit silly to me.

Regarding my own (quite foggy) requirements, I would like to develop a
web site using a efficient language that I like (OCaml), but without
re-inventing the wheel, thus my search for an OCaml friendly web
framework. Until now, I've found technologies for developing such a
framework, but no real read-to-use framework (except maybe WDialog
which lacks support beyond basic HTML) like those[1] that can be found
for other languages (Java, PHP and Python).

Best wishes,
david

[1] http://en.wikipedia.org/wiki/List_of_web_application_frameworks
    http://en.wikipedia.org/wiki/Comparison_of_web_application_frameworks


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-23 16:18 Which development framework for web application in OCaml? David MENTRE
  2006-06-23 16:24 ` [Caml-list] " Richard Jones
@ 2006-06-28 17:41 ` Samuel Mimram
  2006-06-29 21:40   ` Paolo Donadeo
  2006-06-30 13:49   ` Vincent Balat
  1 sibling, 2 replies; 14+ messages in thread
From: Samuel Mimram @ 2006-06-28 17:41 UTC (permalink / raw)
  To: David MENTRE; +Cc: Ocaml

Hi,

David MENTRE wrote:
> For my demexp server, I'm considering the development of a web
> interface, accessible from a simple web browser. I have standard
> requirements (html forms) as well as "advanced" ones (would like to
> support AJAX-like things, navigation in tree data structures, etc.).
> Which development frameworks are available to do such things in OCaml?
> I'm looking for frameworks under a license compatible with GNU GPL.
> 
> Right now, I know about:
> - WDialog
> - XCaml

There is also Ocsigen ( http://www.ocsigen.org/ ) which is a nice
extension of OCaml (i.e. modules + camlp4) to develop websites in a
functional style.

Cheers,

Samuel.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-28 17:41 ` Samuel Mimram
@ 2006-06-29 21:40   ` Paolo Donadeo
  2006-06-30  7:47     ` David MENTRE
  2006-06-30 13:49   ` Vincent Balat
  1 sibling, 1 reply; 14+ messages in thread
From: Paolo Donadeo @ 2006-06-29 21:40 UTC (permalink / raw)
  To: caml-list

> There is also Ocsigen ( http://www.ocsigen.org/ ) which is a nice

Another attempt of self promotion: Ex Nunc
(http://ex-nunc.sourceforge.net) is an application framework written
in pure OCaml that provides strongly-typed page parameters, automatic
session and form validation. Although a live demo is available here:

http://ex-nunc.sourceforge.net/cgi-bin/ex-nunc/demo.cgi

the framework is still young and not usable for commercial purposes
and the templates page compiler is still under construction. In any
case our plan is to complete the core project features and to arrive
to a usable release of Ex Nunc in November 2006. Our first goal is to
obtain a "better PHP", usable in everyday jobs; in the future
interesting features like strongly typed embedded SQL and a better
application server engine (based on the equeue library) are planned.

Since an official announcement is probably a bit premature in this
moment, if you have any question about Ex Nunc or, better, if you want
to join the development team or to subscribe the "free human beings
from PHP slavery" club, contact me.

Best regards,


                                            Paolo Donadeo


-- 
Paolo Donadeo, Senior Software Engineer
Studio Associato 4Sigma
Email: p.donadeo@gmail.com
~
~
:wq


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-29 21:40   ` Paolo Donadeo
@ 2006-06-30  7:47     ` David MENTRE
  2006-06-30  8:03       ` Pietro Abate
  0 siblings, 1 reply; 14+ messages in thread
From: David MENTRE @ 2006-06-30  7:47 UTC (permalink / raw)
  To: p.donadeo; +Cc: caml-list

Hello Paolo,

2006/6/29, Paolo Donadeo <p.donadeo@gmail.com>:
> Ex Nunc
> (http://ex-nunc.sourceforge.net) is an application framework written
> in pure OCaml that provides strongly-typed page parameters, automatic
> session and form validation. Although a live demo is available here:

Quite interesting.

> the framework is still young and not usable for commercial purposes
> and the templates page compiler is still under construction.

I always fear "templates page compiler", because most of the time
people tend to re-invent their own language rather than using existing
one, like OCaml. Is OCaml used as template language for Ex-nunc?

Could you show us the source code of the demo page?

> in the future
> interesting features like strongly typed embedded SQL and a better

Do you plan to use existing code on SQL frameworks?

> application server engine (based on the equeue library) are planned.

> moment, if you have any question about Ex Nunc or, better, if you want
> to join the development team or to subscribe the "free human beings
> from PHP slavery" club, contact me.

I don't want to join the development team but I'm certainly interested
to see if Ex-nunc fits my needs.

Best wishes,
david


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-30  7:47     ` David MENTRE
@ 2006-06-30  8:03       ` Pietro Abate
  2006-06-30 13:51         ` David MENTRE
  0 siblings, 1 reply; 14+ messages in thread
From: Pietro Abate @ 2006-06-30  8:03 UTC (permalink / raw)
  To: caml-list

On Fri, Jun 30, 2006 at 09:47:37AM +0200, David MENTRE wrote:
> Could you show us the source code of the demo page?

I think you get it here:
http://ex-nunc.cvs.sourceforge.net/ex-nunc/ex-nunc/application_server/demo/

:)
p

-- 
++ Blog: http://blog.rsise.anu.edu.au/?q=pietro
++ 
++ "All great truths begin as blasphemies." -George Bernard Shaw
++ Please avoid sending me Word or PowerPoint attachments.
   See http://www.fsf.org/philosophy/no-word-attachments.html


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-28 17:41 ` Samuel Mimram
  2006-06-29 21:40   ` Paolo Donadeo
@ 2006-06-30 13:49   ` Vincent Balat
  2006-06-30 15:14     ` David MENTRE
  1 sibling, 1 reply; 14+ messages in thread
From: Vincent Balat @ 2006-06-30 13:49 UTC (permalink / raw)
  To: caml-list

Hi,

> There is also Ocsigen ( http://www.ocsigen.org/ ) which is a nice
> extension of OCaml (i.e. modules + camlp4) to develop websites in a
> functional style.

I have been asked for more information about Ocsigen. Ocsigen is a research 
project aiming at finding a more robust way to program Web sites, using 
functional programming (continuations) and strong typing. It is not a new 
language but a set of modules for Objective Caml and a web server.

Main features:
 - Valid xhtml generation through static typing
 - Typing of Web interaction (links, forms...)
 - Automatic session handling
 - Javascript generation (AJAX) (work in progress)
 - typed database interaction (work in progress)

It allows to program web sites in a very concise and modular way, and makes 
the maintenance of large web sites much easier compared to usual Web 
programming tools.

Ocsigen was born in 2004 (even though the idea is older) and is now usable 
(see for example www.ocsigen.org). The syntax is not completely fixed yet (as 
we are experimenting with a lot of new ideas) but the development is very 
active and we hope to publish version 1 before the end of the year.

Vincent Balat

PS: For other research projects in the same style, see for example WebSiCoLa, 
Links, Hop, or Wash/CGI


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-30  8:03       ` Pietro Abate
@ 2006-06-30 13:51         ` David MENTRE
  0 siblings, 0 replies; 14+ messages in thread
From: David MENTRE @ 2006-06-30 13:51 UTC (permalink / raw)
  To: Pietro Abate; +Cc: caml-list

Hello Pietro,

2006/6/30, Pietro Abate <Pietro.Abate@anu.edu.au>:
> I think you get it here:
> http://ex-nunc.cvs.sourceforge.net/ex-nunc/ex-nunc/application_server/demo/

Thank you for the pointer. It seems close to WDialog with the
additional benefit that (i) embedded language is OCaml and (ii) the
format of .xnunc files (templates?) are XHTML + <xnc> tags.

This raises additional questions:
 - is i18n handled, on a per page or per context basis (one user uses
French pages while another one English ones)?
 - is generated CGI compiled to native code?

Best wishes,
d.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-30 13:49   ` Vincent Balat
@ 2006-06-30 15:14     ` David MENTRE
  2006-06-30 16:00       ` Vincent Balat
  0 siblings, 1 reply; 14+ messages in thread
From: David MENTRE @ 2006-06-30 15:14 UTC (permalink / raw)
  To: Vincent Balat; +Cc: caml-list

Hello Vincent,

2006/6/30, Vincent Balat <Vincent.Balat@pps.jussieu.fr>:
>  It is not a new
> language but a set of modules for Objective Caml and a web server.

Is there a specific reason to use a dedicated web server instead of a
standard one and standard interface (CGI, FastCGI, JServ, ...)?

Best wishes,
d.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-30 15:14     ` David MENTRE
@ 2006-06-30 16:00       ` Vincent Balat
  2006-06-30 16:26         ` David MENTRE
  2006-06-30 18:26         ` Florian Weimer
  0 siblings, 2 replies; 14+ messages in thread
From: Vincent Balat @ 2006-06-30 16:00 UTC (permalink / raw)
  To: David MENTRE; +Cc: caml-list

I don't thing we can implement Ocsigen with CGI because our model is not "page 
based" (with Ocsigen, you program web site as a whole, like a usual caml 
program, you do not have a file for each URL). It may be possible with 
FastCGI (?).

We use our own web server to get more freedom than using Apache, and we are 
happy with it. We may plan to make an implementation based on fastcgi or an 
Apache module because a lot of users are asking this (mainly because they 
trust Apache) but I am not convinced that it has a lot of advantages ... It 
may not be difficult to do. Basically, an Apache module for Ocsigen would 
just say : "for all request inside this directory, delegate the page 
generation to Ocsigen".

Note that you can run Apache and Ocsigen on the same server using the "reverse 
proxy" feature of Apache.

Wishes
Vincent

Le Vendredi 30 Juin 2006 17:14, David MENTRE a écrit :
> Hello Vincent,
>
> 2006/6/30, Vincent Balat <Vincent.Balat@pps.jussieu.fr>:
> >  It is not a new
> > language but a set of modules for Objective Caml and a web server.
>
> Is there a specific reason to use a dedicated web server instead of a
> standard one and standard interface (CGI, FastCGI, JServ, ...)?
>
> Best wishes,
> d.
>
> _______________________________________________
> Caml-list mailing list. Subscription management:
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
> Archives: http://caml.inria.fr
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-30 16:00       ` Vincent Balat
@ 2006-06-30 16:26         ` David MENTRE
  2006-06-30 17:33           ` Christophe TROESTLER
  2006-06-30 18:26         ` Florian Weimer
  1 sibling, 1 reply; 14+ messages in thread
From: David MENTRE @ 2006-06-30 16:26 UTC (permalink / raw)
  To: Vincent Balat; +Cc: caml-list

Hello,

2006/6/30, Vincent Balat <Vincent.Balat@pps.jussieu.fr>:
> I don't thing we can implement Ocsigen with CGI because our model is not "page
> based" (with Ocsigen, you program web site as a whole, like a usual caml
> program, you do not have a file for each URL).

Ok, thank you for the information. BTW, the font for code example on
the Tutorial page is very small, so small that it is hardly readable
(with Firefox 1.5 on Windows).

> We use our own web server to get more freedom than using Apache, and we are
> happy with it. We may plan to make an implementation based on fastcgi or an
> Apache module because a lot of users are asking this (mainly because they
> trust Apache)

Or because they want to use another web server (lighttpd) or beacuse
they want to integrate Ocsigen web site with another web site or
framework. People rarely start a web site from scratch.

> but I am not convinced that it has a lot of advantages ...

Apache is a very complex piece of software but with a lot of
capabilities, peer review and security updates. DIY-web-server just
can't match.

For me, being tied to your web server (or even Apache) is a very
strong disadvantage.

Best wishes,
d.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-30 16:26         ` David MENTRE
@ 2006-06-30 17:33           ` Christophe TROESTLER
  0 siblings, 0 replies; 14+ messages in thread
From: Christophe TROESTLER @ 2006-06-30 17:33 UTC (permalink / raw)
  To: david.mentre; +Cc: Vincent.Balat, caml-list

On Fri, 30 Jun 2006, "David MENTRE" <david.mentre@gmail.com> wrote:
> 
> For me, being tied to your web server (or even Apache) is a very
> strong disadvantage.

Why not use OCamlNet
(https://gps.dynxs.de/wwwsvn/trunk/code/?root=lib-ocamlnet2) as the
connectors on top of which you build your lib ?  That would give you
the possibility to use CGI, FastCGI, AJP, SCGI, or an apache module
for free !  That will also help the community as the more people use
these connectors, the better and the more stable they will become.

My 0.02€,
ChriS


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [Caml-list] Which development framework for web application in OCaml?
  2006-06-30 16:00       ` Vincent Balat
  2006-06-30 16:26         ` David MENTRE
@ 2006-06-30 18:26         ` Florian Weimer
  1 sibling, 0 replies; 14+ messages in thread
From: Florian Weimer @ 2006-06-30 18:26 UTC (permalink / raw)
  To: Vincent Balat; +Cc: David MENTRE, caml-list

* Vincent Balat:

> I don't thing we can implement Ocsigen with CGI because our model is not "page 
> based" (with Ocsigen, you program web site as a whole, like a usual caml 
> program, you do not have a file for each URL). It may be possible with 
> FastCGI (?).

I've written a small C program which "runs" a small script containing
instructions which environment variables to forward to a domain name
socket, using a very simple protocol.  In my case, the reason was
reduced startup time (the application isn't written in Ocaml) and
clean separation of web server process and application (different UNIX
users).  FastCGI could have done the same, I guess, but its license is
a bit obnoxious and I found it very hard to configure correctly when I
used it a couple of years ago.  The downside with my approach is that
you need to take care of starting the service by some other means.

This small C program hasn't been published so far because I hope that
someone else has already published something similar. 8-/


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2006-06-30 18:42 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-06-23 16:18 Which development framework for web application in OCaml? David MENTRE
2006-06-23 16:24 ` [Caml-list] " Richard Jones
     [not found]   ` <9d3ec8300606251007k2508a880me5ca863de4bbfef3@mail.gmail.com>
2006-06-26 13:23     ` David MENTRE
2006-06-28 17:41 ` Samuel Mimram
2006-06-29 21:40   ` Paolo Donadeo
2006-06-30  7:47     ` David MENTRE
2006-06-30  8:03       ` Pietro Abate
2006-06-30 13:51         ` David MENTRE
2006-06-30 13:49   ` Vincent Balat
2006-06-30 15:14     ` David MENTRE
2006-06-30 16:00       ` Vincent Balat
2006-06-30 16:26         ` David MENTRE
2006-06-30 17:33           ` Christophe TROESTLER
2006-06-30 18:26         ` Florian Weimer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).