Forum OpenACS Development: Re: OpenACS on Apache?

Collapse
3: Re: OpenACS on Apache? (response to 2)
Posted by Jamie Rasmussen on
Also, starting with AOLserver 4.0 you can "load nsd" in a TCL interpreter to get access to many of AOLserver's commands.  (The commands that are missing require a connection, ns_adp_*, ns_return*, and a few others.)  I use this all the time to test the AOLserver API in tclsh, etc.

Just for fun, I added an ns_load command into my libnsd that allows you to also load AOLserver modules into TCL.  It is definitely a hack, but works for simple modules like nssha1.  You can see a screenshot at http://www.jamierasmussen.com/documents/programming/openacs/ns_load.png

I believe John was considering modifying portable.nsd to load libnsd if it was available and to fall back on the pure TCL implementation of the API if not - I don't know if he did.  Building on the work John and Michael have already done on portable.nsd I think it should be possible to run at least a basic OpenACS instance on TclHttpd or Apache without investing too many hours.

Collapse
5: Re: OpenACS on Apache? (response to 3)
Posted by Malte Sussdorff on
Out of curiosity, wouldn't it make sense to load your libnsd into apache and modify the OpenACS core functions to either call ns_return_* (aso.) or the apache equivalent (if there is any, I fear there isn't for ns_adp_*), depending on what server it is running on ?
Collapse
6: Re: OpenACS on Apache? (response to 5)
Posted by John Sequeira on
Malte,

I think you're describing the approach mod_aolserver took.  I don't know too much about it,  but it's more complicated than just rewiring the return function.  The biggest issue with using a binary interface to wire openacs into another web server is that it has to be updated when the interface changes,  or rewritten for each new web server you want to support.  I think that's why the idea continues to not gain traction (aD tried it with both IIS and Apache).

I feel pretty good about the prospects of running portablensd under apache and iis,  and avoiding the binary issue by using fastcgi.  It worked well on the platforms I tried it on (apache 1.3x/win32 + apache 2/rh9)

I got hung up on implementing ad_form and the new listbuilder -- the templating code was too messy and too different from Michael's nstcl for me to reconcile.  I don't think it would be hard from someone better at TCL than myself (like Michael, say).

There were a few other issues,  but no show-stoppers.

fwiw,  I did plan to look for libnsd and fall back to tcl-only routines if they exist,  but I'm not sure if the functionality exposed in libnsd offers enough of a performance increase to justify the maintainence overhead (i.e. adding another row to the pnsd test matrix.)