-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Network-transparent channels? #26
Comments
Golang has this with dockers libchan (https://github.com/docker/libchan), goless support for this would be really cool. Perhaps before considering network transparent channels, we should think of process transparent ones? |
I've considered it but it seems like using multiprocessing and its Queue/Pipes/etc are basically the same thing for process communication. It'd be a quick wrapper and not that useful IMO since I hate dealing with multiprocessing. Its not 'transparent'. Since things will need to be serialized, we'll be limited in what we can send, which is especially important to Go-style stuff because we're often having an anonymous function executing in a goroutine. That said, I still like the idea if it can be done well. I just don't see how to do it well yet! :) If we could not bother with goless having to manage processes (the caller is responsible for managing them), that'd be fine. In the libchan example, I don't see how to pass data between processes- what are the endpoints, how do you tell data where to go? |
The docs aren't great (practically non existant) but from looking at the godoc, they do local rpc over unix-domain sockets by wrapping golangs Back to the point, when you put it that way, there's a stable RPC module in the stdlib (multiprocessing) and from some quick googling there's also a mature remote RPC implementation (pyro). So, on second thought, perhaps this is not something we need after all (or we can just wrap those and call it a day, but I don't think it will bring much value) |
I'm fine with just using ZeroMQ when I want to reach out to another machine (or even another process on the same machine, since at least then I have the option of moving stuff to other boxes without changing my code), and marshaling code and data to send off to an executor is a (somewhat) solved problem (Celery, mincemeat -- it (Edit: You might want to consider looking at ZeroMQ/ |
So, I've been thinking about this and I've got a proposal:
What do you guys think? I'll probably hack on this over the coming week. |
This is very interesting! |
Hmmm, as I'm not experienced enough in this domain (haven't looked at other libraries in detail), I can't offer much. I would love to see some pseudocode even before you go down the prototype route. I have a lot of questions but feel they'd probably just be better answered with some code. Also of interest for you would be another project of mine: https://github.com/rgalanakis/dccautomation Ultimately we'd either have to provide 'backends' for things like zmq/nanomsg/snakemq/http/rabbitmq/amqp, or require callers to provide their own (and then create separate packages for each implementation, so people weren't reinventing the wheel). Either way, creating a homogeneous interface across these systems can be extremely tricky, especially if you want "synchronous" channel behavior. You'd probably want to limit the Looking forward to seeing some code, or at least an API skeleton! |
I just saw that Go had an old |
So @MichaelAz and @rcarmo you gave me the bug and I wrote something up very quickly while my son is napping: 6c3da3a |
I've been mulling the need to coordinate a few processes on different machines.
Is something like this on the roadmap?
Although I use MQTT for cross-language message passing (and am happy with it), it would be interesting if one could set up channels across machines using something that is more popular (say Redis, which is popping up all over the place these days, or 0MQ, which is also fairly agnostic).
The text was updated successfully, but these errors were encountered: