[Rd] R as shared library

Horner, Jeff jeff.horner at Vanderbilt.Edu
Thu Aug 26 20:55:36 CEST 2004

>From: A.J. Rossini [mailto:rossini at blindglobe.net]
>Jeffrey Horner <jeff.horner at vanderbilt.edu> writes:
>> Good point. However, I chose this route to 1) understand R and its
>> internals, which is more complicated than I thought,  2) write an
>> apache module, which I've always wanted to do, and 3) leverage
>> Apache's robust server technology. In my opinion, no other server
>> software is as scalable and reliable as Apache. Plus, it has a module
>> API to plugin other code, like an R interpreter.
>All good reasons.  But what is the final API going to look like?  Are
>you planning on SSI's for the general interface?

For my prototype which already works, it's as simple as placing your code
in a .R file accessible from the web server. That means your R code is
responsible for generating HTML, similar to other languages embedded
into Apache like Perl and Python. PHP is different in that the interpreter
is only entered once a special tag is seen:

 /* php code here */ 

And you can jump into and out of the interpreter an unlimited number of times.
This allows for embedding parts of the HTML document within your code. Whether
or not this is a good thing is debatable.

The problem I'm working on right now, and which was talked about in the
previous emails, is how to expose the CGI data to the R interpreter. Another
part of this is how tight should R hook into Apache. Languages like Perl and
Python expose many different parts of the http request to be overidden by
language specific handlers, whereas PHP doesn't.

My intent is to release a proof of concept prototype and then work with the R
developer community to determine how it should evolve.


	[[alternative HTML version deleted]]

More information about the R-devel mailing list