[Rprotobuf-yada] RprotoBuf initiation

Romain Francois romain.francois at dbmail.com
Wed Feb 10 20:05:17 CET 2010


On 02/10/2010 07:57 PM, Dirk Eddelbuettel wrote:
>
>
> On 10 February 2010 at 19:43, Romain Francois wrote:
> | On 02/10/2010 04:53 PM, Dirk Eddelbuettel wrote:
> |>
> |>
> |>  On 10 February 2010 at 10:31, Etienne Bellemare Racine wrote:
> |>  | I've gone to some of the vignettes and Google's documentation and I
> |>  | understand (I'm sorry if this is obvious I just want to be sure I
> |>  | understand right) that with proto buffer, you don't introduce a new way
> |>  | of creating structures in R, you provide a way to share a common
> |>  | structure with other languages.
> |>
> |>  Precisely. In a portable, efficient, fast and extensible matter.
> |>
> |>  | So you can, to take the address book example, get stats in R from an
> |>  | address book which would be managed by some Java code, without passing
> |>  | by Java to let R access the data or vice versa.
> |>
> |>  Right. You'd use native Java code to read, write, alter, ... the addressbook
> |>  encoded in a binary file and describe in a '.proto' ProtoBuf definiton. Now
> |>  thanks to RProtoBuf you can read, write, alter, ... the same addressbook with
> |>  having to pass data back and for to Java -- you simple read, write, ... the
> |>  protobuf file.
> |>
> |>  Plus, and while Google does not provide a network layer, you can do the same
> |>  thing 'over the wire' instead of with files, or store it in a database and
> |>  have clients in R, Java, Python, C++, ... all access the (binary) data as
> |>  they all can deparse the ProtoBuf representation.
> |
> | Yep. But this part of the R package does not quite work yet.
> |
> | But it will at some point be possible to have say an "protobuf message
> | server" embedded in the R session and a protobuf message client in
> | another session, or in java or in whatever other language ...
>
> Right. Or go the other way and store the Protobuf binary bits as 'values' in
> a key/value database. I have a looked at a few of these new NoSQL databases.
> But that would be yet-another-project and maybe no a good idea :)

Not for me right now, but should be fairly easy with the new Rcpp

> | If all goes as planned, something like this should be demonstrable at
> | useR! this year.
>
> Yep!

Obviously there is some science fiction in this. For the server side, we 
need the http server [1] to be more flexible, or write our own. I've 
looked into boost asio some time ago, and this might be possible, but we 
would have to deal with the threading and input handlers, and stuff like 
that; i prefer not to dive in this right now.

[1] 
http://journal.r-project.org/archive/2009-2/RJournal_2009-2_Murdoch+Urbanek.pdf

-- 
Romain Francois
Professional R Enthusiast
+33(0) 6 28 91 30 30
http://romainfrancois.blog.free.fr
|- http://tr.im/NrTG : Rcpp 0.7.5
|- http://tr.im/MPYc : RProtoBuf: protocol buffers for R
`- http://tr.im/KfKn : Rcpp 0.7.2




More information about the Rprotobuf-yada mailing list