Loading ...
Sorry, an error occurred while loading the content.
 

ocaml powered website

Expand Messages
  • code17
    Dear list Does anyone have a whole solution for ocaml powered website? I mean sth in the programming layer like cgi/php and sth in the application layer like
    Message 1 of 7 , Dec 26, 2005
      Dear list

      Does anyone have a whole solution for ocaml powered website? I mean sth
      in the programming layer like cgi/php and sth in the application layer
      like cms/wiki/blog/forum etc.

      I recently helped a friend setup and customize his personal portal with
      some php+mysql system without pre-knowledge of them. It's just fine, as
      both kinds of code are not so difficult to understand. On the other
      hand, I also realized that I can not get any further jobs done without
      reading a large pile of tech documents and getting custom to them by
      huge amount of practice. A worse point I can already image is that the
      dynamic programming approach based on string manipulation will probably
      make debugging process a nightmare and leave a lot of hidden bugs. So, I
      would like to hear about high-order solutions based on ocaml
      programming, and possibly to build some website on them.

      There are two concrete questions at this moment:

      1) I've heard of several libraries for ocaml web programming
      e.g. ocamlnet and mod_caml, and ocaml database interfaces, also
      applications like cocanwiki, but I still don't know what kind of
      combinations, at current stage, can be a best choice for an integrated
      web application develop platform (or even some pre-build
      multifunctional application such as CMS), so that I can begin to play
      with and contribute to. If someone has already build his/her website
      mostly on ocaml, please give some experiences and suggestions.

      2) It's hard to find some ocaml-friendly hosting, if one wants to make
      his/her ocaml powered site public. One can find cheap (but still not
      bad) hosting for php+mysql with low price around $1/m-$3/m and even
      free. But to host a ocaml based solution, either you can find some
      unreasonably expensive hosting for they support numerous languages but
      you still don't have the control, or a better choice, some VPS (VDS)
      can give you root access to control everything by yourself, which
      usually cost from 10$/m for the lowest configuration (not sure
      whether it can satisfy average ocaml web applications). If anyone has
      information on ocaml hosting, don't hesitate to give suggestions pls.

      Thanks in advance.

      - code17
    • vly3
      ... languages but ... I don t know much about this, but maybe you could use binary CGI programs written in OCaml. So long as a host allows compiled binary CGI
      Message 2 of 7 , Dec 26, 2005
        --- In ocaml_beginners@yahoogroups.com, code17 <code17@g...> wrote:

        > 2) It's hard to find some ocaml-friendly hosting, if one wants to make
        > his/her ocaml powered site public. One can find cheap (but still not
        > bad) hosting for php+mysql with low price around $1/m-$3/m and even
        > free. But to host a ocaml based solution, either you can find some
        > unreasonably expensive hosting for they support numerous
        languages but
        > you still don't have the control,


        I don't know much about this, but maybe you could use binary CGI
        programs written in OCaml. So long as a host allows compiled binary
        CGI programs, it would't matter what language the binary was created
        with. It would just have to be compiled for the same operating system
        as the host uses. Powweb.com ($7.77 per month) allows CGI binaries I
        think.

        - Vincent
      • Richard Jones
        ... mod_caml + ocamldbi[*] is a complete solution for building websites. Here are some database-backed websites built using it: http://merjis.com/
        Message 3 of 7 , Dec 28, 2005
          On Mon, Dec 26, 2005 at 08:28:55PM +0100, code17 wrote:
          > Does anyone have a whole solution for ocaml powered website? I mean sth
          > in the programming layer like cgi/php and sth in the application layer
          > like cms/wiki/blog/forum etc.

          mod_caml + ocamldbi[*] is a complete solution for building websites.
          Here are some database-backed websites built using it:

          http://merjis.com/
          http://www.ocaml-tutorial.org/
          http://j-london.com/
          http://subjectlink.com/

          I'm currently building another one for a UK investment company.

          You can get the source for j-london.com and COCANWIKI, which should
          give you some ideas about how to write forums.

          > 1) I've heard of several libraries for ocaml web programming
          > e.g. ocamlnet and mod_caml, and ocaml database interfaces, also
          > applications like cocanwiki, but I still don't know what kind of
          > combinations, at current stage, can be a best choice for an integrated
          > web application develop platform (or even some pre-build
          > multifunctional application such as CMS), so that I can begin to play
          > with and contribute to. If someone has already build his/her website
          > mostly on ocaml, please give some experiences and suggestions.

          Here was something I wrote ages ago, comparing the approaches:

          http://caml.inria.fr/pub/ml-archives/caml-list/2004/10/81bbc08defeb05351c2e0e3164dca32c.en.html

          [*] Recently I've been thinking about how to make the database layer
          type safe. One approach is to store the schema in XML documents, as
          they do in AS/XCAML. However I really don't like that because it
          limits you to a small subset of SQL, and it's hard to make it work
          when you've got a database already. If you just want to work with
          PostgreSQL, then I outlined one possible way here:

          http://caml.inria.fr/pub/ml-archives/caml-list/2005/07/857083d0d55ca642e4452ab82abd02cc.en.html

          (It's worth reading the follow-up comments too).

          > 2) It's hard to find some ocaml-friendly hosting, if one wants to make
          > his/her ocaml powered site public.

          You're not going to find ocaml webhosting. Probably your best bet is
          to get a "virtual machine" webhost running Debian. We are currently
          using these people:

          http://www.bytemark.co.uk/hosting/virtualmachine/index.html

          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
        • code17
          Hi, Richard ... Thanks for the survey and suggestion, quite informative. It seems that numerous libraries have been provided with pros, cons, applicable scope
          Message 4 of 7 , Dec 30, 2005
            Hi, Richard

            Richard Jones <rich@...> writes:
            > mod_caml + ocamldbi[*] is a complete solution for building websites.
            > Here are some database-backed websites built using it:
            > Here was something I wrote ages ago, comparing the approaches:
            > http://caml.inria.fr/pub/ml-archives/caml-list/2004/10/81bbc08defeb05351c2e0e3164dca32c.en.html
            > http://caml.inria.fr/pub/ml-archives/caml-list/2005/07/857083d0d55ca642e4452ab82abd02cc.en.html
            > (It's worth reading the follow-up comments too).

            Thanks for the survey and suggestion, quite informative. It seems that
            numerous libraries have been provided with pros, cons, applicable scope
            of their own. Meanwhile, there is no much agreement shared among their
            design and structure, nor do I see enough numbers of web applications
            really written in OCaml. Maybe I'm wrong to say so for I still don't
            know much about this field, in either case, I'm still willing to give a
            try on OCaml for web application.

            I also find this project [1] seems to take a different high-level
            approach to web programming in OCaml, but it's not release yet.

            > You're not going to find ocaml webhosting. Probably your best bet is
            > to get a "virtual machine" webhost running Debian. We are currently
            > using these people:
            > http://www.bytemark.co.uk/hosting/virtualmachine/index.html

            About hosting, bytemark uses "user-mode linux" tech which is probably
            still expensive on cost, I found this company [2] using "xen" as
            solution which offers better price. If anyone has experiences with them
            or know more cheap solution, please give more suggestion.

            Ref:
            [1] http://www.ocsigen.org/
            [2] http://unixshell.com/

            - code17
          • Christophe TROESTLER
            ... I am trying to unify the various approaches into a comfortable, powerful and coherent whole. It is closer to OcamlNet because it is the more mature
            Message 5 of 7 , Dec 30, 2005
              On Fri, 30 Dec 2005, code17 <code17@...> wrote:
              >
              > Thanks for the survey and suggestion, quite informative. It seems that
              > numerous libraries have been provided with pros, cons, applicable scope
              > of their own. Meanwhile, there is no much agreement shared among their
              > design and structure,

              I am trying to unify the various approaches into a comfortable,
              powerful and coherent whole. It is closer to OcamlNet because it is
              the more mature project today. It has a "mod_caml" type connector.
              You can find the doc (.mli) at

              http://ocaml-cgi.sourceforge.net/netcgi/doc/

              and browse the code at:

              http://cvs.sourceforge.net/viewcvs.py/ocaml-cgi/ocamlnet/netcgi/

              It is not yet accepted by the OcamlNet maintainers but, really, I hope
              this will eventually succeed to provide a common basis on which web
              applications can be build AND SHARED!

              > I also find this project http://www.ocsigen.org/ seems to take a
              > different high-level approach to web programming in OCaml, but it's
              > not release yet.

              It indeed looks interesting and I have been thinking to develop
              something about these lines myself (I have some preliminary code but
              nothing I can show at the moment).

              But one has to distinguish between the connectors (which is the goal
              of OcamlNet) and higher level libraries built on top of them. Right
              now, there is unfortunately not even a good base that would be
              accepted by the community...

              Hope that helps,
              ChriS
            • code17
              Hi, thanks for the info Christophe TROESTLER writes: ... This is definitely a good news for people want to try OCaml with web
              Message 6 of 7 , Dec 30, 2005
                Hi, thanks for the info
                Christophe TROESTLER <Christophe.Troestler@...> writes:>
                > I am trying to unify the various approaches into a comfortable,
                > powerful and coherent whole. It is closer to OcamlNet because it is
                > the more mature project today. It has a "mod_caml" type connector.
                > You can find the doc (.mli) at
                > http://ocaml-cgi.sourceforge.net/netcgi/doc/
                > and browse the code at:
                > http://cvs.sourceforge.net/viewcvs.py/ocaml-cgi/ocamlnet/netcgi/
                This is definitely a good news for people want to try OCaml with web
                application development.

                Something off topic but maybe interesting for the people here:
                I got your reply also from my Gmail mailbox, and there, Google maps your
                message with the following advertisement on the right hand:
                ___________________________
                / Related Pages \
                | Standard_ML_of_New_Jersey |
                | SML/NJ is a compiler and |
                | programming environment |
                | for SML, with ... |
                | www.smlnj.org |
                \____About_these_links______/

                - code17
              • Richard Jones
                ... This is roughly right. I would like to integrate the mod_caml CGI and cookie classes into the ocamlnet classes, but sheer lack of time and volume of
                Message 7 of 7 , Dec 31, 2005
                  On Fri, Dec 30, 2005 at 10:14:11PM +0100, code17 wrote:
                  > Thanks for the survey and suggestion, quite informative. It seems that
                  > numerous libraries have been provided with pros, cons, applicable scope
                  > of their own. Meanwhile, there is no much agreement shared among their
                  > design and structure, nor do I see enough numbers of web applications
                  > really written in OCaml. Maybe I'm wrong to say so for I still don't
                  > know much about this field, in either case, I'm still willing to give a
                  > try on OCaml for web application.

                  This is roughly right. I would like to integrate the mod_caml CGI and
                  cookie classes into the ocamlnet classes, but sheer lack of time and
                  volume of existing code means this isn't going to happen in the near
                  future. (See also Chris's reply). Expect a type-safe PostgreSQL
                  layer before that happens.

                  In the meantime, I started this page to act as a list of links to
                  OCaml web options:

                  http://wiki.cocan.org/web_programming_with_ocaml

                  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
                Your message has been successfully submitted and would be delivered to recipients shortly.