Channel documentation
rogeriochaves opened this issue · 7 comments
I don't know if channels are ready yet, but there is no documentation
@rogeriochaves I believe that channels are ready, but I'll defer to @mighe on that. He implemented that feature. We definitely need documentation for that set of abstractions. To be perfectly honest, I don't even know how they work! 😊
I'll add some documentation in the next days.
Channels are implemented "taking inspiration" from Go channels: they are more o less synchronized queue to pass data between threads. The interesting feature is that they are selectable, following the same pattern used by non-blocking IO.
Thank you! I'm very interested to learn how to use them
What's the status on this?
I've completely re-implemented channels. PR #415 has those changes. Top-level documentation is provided in the doc/channel.md file on the new-channel
branch. The new implementation is capable of replicating all the channel examples from Go by Example and A Tour of Go. Those example scripts (which are also used with automated integration testing) are available in the examples/a-tour-of-go-channels and examples/go-by-example-channels directories on that branch. Although I haven't finished full yardoc for all classes, the current documentation is pretty extensive and should be more than enough for anyone to get started.
@Ch4s3 My current plan is to release the new channel implementation as part of the Edge gem, replacing the original implementation. That will happen in the release of Edge which corresponds with the 1.0 release of the core gem. If you would like to start working with channels right away I'd be happy to include the new implementation in the next pre-release. I'd love to get your feedback and input.
@jdantonio I'll take a look soon. I'm out of the country for a couple of weeks, but I'll grab Edge when its out and run through the Go Examples with it. If I can fully wrap my head around it, I'll try to help with docs.