{"id":13700925,"url":"https://github.com/matryer/vice","last_synced_at":"2025-10-25T03:33:20.898Z","repository":{"id":37732937,"uuid":"98572401","full_name":"matryer/vice","owner":"matryer","description":"Go channels at horizontal scale (powered by message queues)","archived":false,"fork":false,"pushed_at":"2022-07-22T03:09:35.000Z","size":226,"stargazers_count":1546,"open_issues_count":9,"forks_count":78,"subscribers_count":33,"default_branch":"master","last_synced_at":"2025-03-31T22:16:44.034Z","etag":null,"topics":["channels","golang","idiomatic","queues"],"latest_commit_sha":null,"homepage":"https://medium.com/@matryer/introducing-vice-go-channels-across-many-machines-bcac1147d7e2","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/matryer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-07-27T19:20:18.000Z","updated_at":"2025-03-21T20:42:59.000Z","dependencies_parsed_at":"2022-07-12T15:18:07.119Z","dependency_job_id":null,"html_url":"https://github.com/matryer/vice","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matryer%2Fvice","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matryer%2Fvice/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matryer%2Fvice/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matryer%2Fvice/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/matryer","download_url":"https://codeload.github.com/matryer/vice/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247744333,"owners_count":20988783,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["channels","golang","idiomatic","queues"],"created_at":"2024-08-02T20:01:08.940Z","updated_at":"2025-10-25T03:33:20.838Z","avatar_url":"https://github.com/matryer.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"![](docs/vicelogo-small.png)\n\n# Go channels at horizontal scale [![Build Status](https://travis-ci.org/matryer/vice.svg?branch=master)](https://travis-ci.org/matryer/vice)\n\n* Use Go channels transparently over a [messaging queue technology of your choice](https://github.com/matryer/vice/tree/master/queues) (Currently [NATS](http://nats.io), [Redis](http://redis.io) or [NSQ](http://nsq.io), [Amazon SQS](https://aws.amazon.com/sqs/))\n* Swap `vice.Transport` to change underlying queueing technologies transparently\n* Write idiomatic Go code instead of learning queue specific APIs\n* Develop against in-memory implementation before putting it into the wild\n* Independent unit tests (no need for running queue technology)\n\nPROJECT STATUS: [v1 released](https://github.com/matryer/vice/releases/tag/v1.0.0)\n\n## Usage\n\nThis code receives names on the `|names|` queue, and sends greetings on the `|greetings|`\nqueue:\n\n```go\n// get a Go channel that will receive messages on the\n// |names| queue\nnames := transport.Receive(\"names\")\n\n// get a Go channel that will send messages on the\n// |greetings| queue\ngreetings := transport.Send(\"greetings\")\n\n// respond to |names| messages with |greetings|\nfor name := range names {\n\tgreetings \u003c- []byte(\"Hello \" + string(name))\n}\n```\n\n* The code above is illustrative, be sure to read the [design patterns](https://github.com/matryer/vice/blob/master/docs/design-patterns.md)\n* Always stop the Transport, some technologies register and deregister their interest in the queues (this means trapping signals and gracefully shutting down services before exiting)\n* Use `Send` and `Receive` methods to get channels, which you can then use as normal\n* Be sure to always handle the `ErrChan()` error channel to make sure the underlying queue technology is healthy\n\n## Quick start guide\n\n* Write your services with unit tests using normal Go channels (see our [design patterns](https://github.com/matryer/vice/blob/master/docs/design-patterns.md))\n* Install Vice with `go get github.com/matryer/vice/...`\n* Select a [messaging queue technology](https://github.com/matryer/vice/tree/master/queues)\n* Build a command to run your service\n\nRead the blog post: [Introducing vice: Go channels across many machines](https://medium.com/@matryer/introducing-vice-go-channels-across-many-machines-bcac1147d7e2)\n\n## Acknowledgements \n\nSpecial thanks go to [David Hernandez](https://github.com/dahernan), [Jason Hancock](https://github.com/jasonhancock) and [Piotr Rojek](https://github.com/piotrrojek) for their support on this project.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatryer%2Fvice","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmatryer%2Fvice","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatryer%2Fvice/lists"}