{"id":24485424,"url":"https://github.com/abc-arbitrage/zebus","last_synced_at":"2026-01-24T20:17:22.003Z","repository":{"id":16978555,"uuid":"19741280","full_name":"Abc-Arbitrage/Zebus","owner":"Abc-Arbitrage","description":"A lightweight Peer to Peer Service Bus","archived":false,"fork":false,"pushed_at":"2024-12-20T16:13:11.000Z","size":33440,"stargazers_count":311,"open_issues_count":7,"forks_count":61,"subscribers_count":48,"default_branch":"master","last_synced_at":"2025-05-15T23:07:47.802Z","etag":null,"topics":["bus","c-sharp","distributed-systems","peer-to-peer","service-bus"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"FallibleInc/security-guide-for-developers","license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Abc-Arbitrage.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2014-05-13T14:02:14.000Z","updated_at":"2025-04-11T14:16:02.000Z","dependencies_parsed_at":"2023-11-30T17:50:29.941Z","dependency_job_id":"5c72c2b7-f656-479a-85cc-490bcd2e1f7a","html_url":"https://github.com/Abc-Arbitrage/Zebus","commit_stats":{"total_commits":1115,"total_committers":26,"mean_commits":42.88461538461539,"dds":0.7354260089686099,"last_synced_commit":"c3c8be8b96aa8dbef79558687fedd6f5e6b23d13"},"previous_names":[],"tags_count":130,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Abc-Arbitrage%2FZebus","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Abc-Arbitrage%2FZebus/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Abc-Arbitrage%2FZebus/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Abc-Arbitrage%2FZebus/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Abc-Arbitrage","download_url":"https://codeload.github.com/Abc-Arbitrage/Zebus/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254436949,"owners_count":22070947,"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":["bus","c-sharp","distributed-systems","peer-to-peer","service-bus"],"created_at":"2025-01-21T14:17:54.990Z","updated_at":"2026-01-24T20:17:21.997Z","avatar_url":"https://github.com/Abc-Arbitrage.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Zebus\n\n[![Build](https://github.com/Abc-Arbitrage/Zebus/actions/workflows/build.yml/badge.svg?branch=master\u0026event=push)](https://github.com/Abc-Arbitrage/Zebus/actions/workflows/build.yml)\n[![NuGet](https://img.shields.io/nuget/v/Zebus.svg?label=NuGet\u0026logo=NuGet)](http://www.nuget.org/packages/Zebus/)\n[![Gitter](https://img.shields.io/gitter/room/Abc-Arbitrage/Zebus.svg?label=Chat\u0026logo=Gitter\u0026color=blue)](https://gitter.im/Abc-Arbitrage/Zebus)\n\nZebus is a lightweight peer to peer service bus, built with [CQRS](http://martinfowler.com/bliki/CQRS.html) principles in mind. It allows applications to communicate with each other in a fast and easy manner. Most of the complexity is hidden in the library and you can focus on writing code that matters to you, not debugging messaging code.\n\n# Introduction\n\nZebus is **peer to peer**, so it does not depend on a broker to dispatch messages between the peers. This allows it to reach a throughput of 140k msg/s and a roundtrip latency under 500µs (have a look at the [Performance](https://github.com/Abc-Arbitrage/Zebus/wiki/Performance) page for details).\n\nIt is **resilient** thanks to the absence of a broker and an optional persistence feature that ensures that messages are not lost if a peer is down or disconnected.\n\nIt is **stable**, since we have been using it on a production environment at [ABC Arbitrage](http://www.abc-arbitrage.com/) since 2013, handling hundreds of millions of messages per day.\n\n## Key concepts\n\n### Peer\n\nWe call a peer any program that is connected to the bus, a peer is identified by a unique identifier called a PeerId that looks like this: `MyAmazingPeer.0` (we use this convention to identify different instances of the same service).\n\n### Event\n\nAn event is sent by a peer to notify everyone who is interested that something happened (ex: `MyBusinessObjectWasSaved`, `AlertTriggered`...).\n\n### Command\n\nA command is sent to a peer asking for an action to be performed (ex: `SaveMyBusinessObjectCommand`).\n\n### Message Handler\n\nA class deriving from `IMessageHandler\u003cT\u003e` will be scanned by the bus and will be used to handle messages of the `T` kind on reception.\n\n### Bus\n\nThe piece of code that is the point of entry to use Zebus, the methods that you will use the most are `Publish(IEvent)` and `Send(ICommand)`.\n\n## A quick demo\n\nOn startup, the bus will scan your assemblies for message handlers and notify the other peers that you are interested by those messages. When a peer publishes a message, it will use the Directory to know who handles it and send the message directly to the correct recipients.\n\n### Receiver\n\n```csharp\npublic class MyHandler : IMessageHandler\u003cMyEvent\u003e\n{\n    public void Handle(MyEvent myEvent)\n    {\n        Console.WriteLine(myEvent.Value);\n    }\n}\n```\n\n### Sender\n\n```csharp\npublic void MethodThatSends(IBus bus)\n{\n    bus.Publish(new MyEvent { Value = 42 });\n}\n```\n\n### Event description\n\n```csharp\n[ProtoContract]\npublic class MyEvent : IEvent\n{\n    [ProtoMember(1)]\n    public int Value { get; set; }\n}\n```\n\nAnd you're set ! This is all the code you need to send an event from one machine to the other. If you want to read more about how the magic happens, have a look at the [wiki](https://github.com/Abc-Arbitrage/Zebus/wiki). Or if you want a more detailed walkthrough (what to reference, how to start the Bus...) visit the [Quick start](https://github.com/Abc-Arbitrage/Zebus/wiki/Quick-start) page.\n\n# Release notes\n\nWe try to stick to the [semantic versioning](http://semver.org/) principles and keep the [release notes](https://github.com/Abc-Arbitrage/Zebus/blob/master/RELEASE_NOTES.md) and [directory release notes](https://github.com/Abc-Arbitrage/Zebus/blob/master/RELEASE_NOTES_DIRECTORY.md) up to date.\n\n# Other repositories\n\n - [Zebus.MessageDsl](https://github.com/Abc-Arbitrage/Zebus.MessageDsl) - a DSL which simplifies the writing of ProtoBuf contracts for Zebus\n - [Zebus.TinyHost](https://github.com/Abc-Arbitrage/Zebus.TinyHost) - a lightweight host used to run Zebus enabled services\n - [Zebus.Samples](https://github.com/Abc-Arbitrage/Zebus.Samples) - miscellaneous samples that show how to get started with Zebus\n\n# Copyright\n\nCopyright © ABC Arbitrage Asset Management\n\n# License\n\nZebus is licensed under MIT, refer to [LICENSE.md](https://github.com/Abc-Arbitrage/Zebus/blob/master/LICENSE.md) for more information.\n\n# Tools\nWe use\n\n[![resharper_icon](https://raw.githubusercontent.com/wiki/Abc-Arbitrage/Zebus/content/icon_ReSharper.png)](https://www.jetbrains.com/resharper/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabc-arbitrage%2Fzebus","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabc-arbitrage%2Fzebus","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabc-arbitrage%2Fzebus/lists"}