From simon.urbanek at r-project.org  Mon Jul 19 17:34:29 2010
From: simon.urbanek at r-project.org (Simon Urbanek)
Date: Mon, 19 Jul 2010 11:34:29 -0400
Subject: [Rd] Non-blocking Eval
In-Reply-To: <COL117-W11775CC4DBBCB41511CEA7C0BF0@phx.gbl>
References: <COL117-W11775CC4DBBCB41511CEA7C0BF0@phx.gbl>
Message-ID: <A84E66CA-9A25-4991-8533-208FE241AC9E@r-project.org>

On Jul 19, 2010, at 10:58 AM, Martin Kerr wrote:

> 
> Hello,
> I'm currently working with the C++ version of the Rserve Client as part of a student project.
> Is there an implementation of a non-blocking interface to Rserve in C++? I can find one via the Java JRI but no equivalent in C++.

(Please note that stats-rosuda-devel is the correct list for this.)

I'm not quite sure what you mean, because in JRI there is idleEval() which is non-blocking in the sense that it doesn't do anything if R is busy but that doesn't apply to Rserve as by definition R cannot be busy there. There is no non-blocking interface to JRI - all calls are synchronous.

If your question is whether you can start an evaluation in Rserve and not wait for the result then there is CMD_detachedVoidEval in Rserve, but the C++ client only implements a subset of the API which does not include that -- however, it is trivial to implement (just send a request with CMD_detachedVoidEval as there is nothing to decode).

Cheers,
Simon



[Rd] Non-blocking Eval
Simon Urbanek