Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/brynbellomy/go-rx
A set of basic, common Go concurrency patterns, very loosely adapted to the Rx model
https://github.com/brynbellomy/go-rx
Last synced: about 1 month ago
JSON representation
A set of basic, common Go concurrency patterns, very loosely adapted to the Rx model
- Host: GitHub
- URL: https://github.com/brynbellomy/go-rx
- Owner: brynbellomy
- Created: 2015-12-04T16:41:50.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2016-01-07T19:07:32.000Z (almost 9 years ago)
- Last Synced: 2024-04-17T00:55:58.582Z (7 months ago)
- Language: Go
- Homepage:
- Size: 18.6 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# go-rx
[![Build Status](https://drone.io/github.com/brynbellomy/go-rx/status.png)](https://drone.io/github.com/brynbellomy/go-rx/latest)
`go-rx` is an encapsulation of some basic, common patterns using Go's concurrency primitives. It draws *very loosely* from the metaphor/architecture used by Microsoft's Reactive Extensions (Rx).
I've heard people say that Rx and Go shouldn't be grafted together — they're too different. Taking that as a challenge, I've tried to adapt the Rx metaphor to Go's concurrency model in a way that does it justice. For example, `.Subscribe()` returns a channel and a disposable, instead of accepting a callback and returning a disposable:
```go
out, dispose := blah.Subscribe()x := <-out.Out() // receive from the subscribed channel
dispose.Cancel() // cancel the goroutine managing the subscription
```# help
As in: please let me know if you'd like to offer some :) Pull requests encouraged.
# Authors / contributors
- Bryn Bellomy ()