[nanomsg] Re: .NET wrapper for nanomsg

  • From: Gonzalo Diethelm <gonzalo.diethelm@xxxxxxxxx>
  • To: nanomsg <nanomsg@xxxxxxxxxxxxx>
  • Date: Mon, 23 Sep 2013 21:08:26 -0300

> We just recently discussed it on IRC. The complicated part is that
> when there is nn_poll for nanomsg we need to integrate other kinds of
> sockets into nn_poll. When it's done (e.g. in a way zmq_poll works),
> then everything written in Java doesn't work on top of that anyway.
> E.g. you (probably) can't run java.nio loop on top of nn_poll. So IMO
> it's better to write integration code for every platform, than to have
> nn_poll solving only half of the problem.

I agree, best would be to integrate nanomsg's polling functionality
directly into the "Java way" (NIO).

> Anyway there are rumors that it's impossible (to integrate
> NN_RCVFD/NN_SNDFD into Java). Can you disprove that?

This might be the case; I really don't know. One thing, though, is that
Java NIO does support the lower-level polling mechanisms, so it should be
possible to look at how they implemented support for that in the JRE and
replicate for nanomsg. But this really is a complex part of the JRE,
compounded by the portability issues (especially under Windows); as I said,
I have not found the time and energy to delve into how they did it and try
to come up with an implementation for nanomsg.



On Mon, Sep 23, 2013 at 12:52 PM, Paul Colomiets <paul@xxxxxxxxxxxxxx>wrote:

> Hi,
>
> On Mon, Sep 23, 2013 at 4:02 PM, gonzalo diethelm <gdiethelm@xxxxxx>
> wrote:
> > In the Java binding for nanomsg there is (yet) no polling support. It
> should be possible to integrate nanomsg polling into the native Java
> mechanism, but this is such a poorly documented area in Java that I have
> not been able to find the time / energy to do it.
> >
> > In that sense, maybe adding a ZQM-style nn_poll() function could be of
> help for Java and other non-BSD-friendly languages... But I don't really
> want to push this if it totally breaks the simplicity of nanomsg.
> >
>
> We just recently discussed it on IRC. The complicated part is that
> when there is nn_poll for nanomsg we need to integrate other kinds of
> sockets into nn_poll. When it's done (e.g. in a way zmq_poll works),
> then everything written in Java doesn't work on top of that anyway.
> E.g. you (probably) can't run java.nio loop on top of nn_poll. So IMO
> it's better to write integration code for every platform, than to have
> nn_poll solving only half of the problem.
>
> Anyway there are rumors that it's impossible (to integrate
> NN_RCVFD/NN_SNDFD into Java). Can you disprove that?
>
> --
> Paul
>
>


-- 
Gonzalo Diethelm
gonzalo.diethelm@xxxxxxxxx

Other related posts: