rafaeljesus / Nsq Event Bus
Licence: mit
A tiny wrapper around NSQ topic and channel 🚀
Stars: ✭ 66
Programming Languages
go
31211 projects - #10 most used programming language
Projects that are alternatives of or similar to Nsq Event Bus
Event Sourcing Jambo
An Hexagonal Architecture with DDD + Aggregates + Event Sourcing using .NET Core, Kafka e MongoDB (Blog Engine)
Stars: ✭ 159 (+140.91%)
Mutual labels: microservices, event-driven
Dotnet New Caju
Learn Clean Architecture with .NET Core 3.0 🔥
Stars: ✭ 228 (+245.45%)
Mutual labels: microservices, event-driven
Event Sourcing Microservices Example
Learn about building microservices with event sourcing using Spring Boot and how to deploy a social network to Kubernetes using Docker Compose or Helm.
Stars: ✭ 167 (+153.03%)
Mutual labels: microservices, event-driven
Dotnet Istanbul Microservices Demo
This is the demo application that i created for my talk 'Microservice Architecture & Implementation with Asp.Net Core' at Dotnet İstanbul Meetup Group.
Stars: ✭ 109 (+65.15%)
Mutual labels: microservices, event-driven
Spring Cloud Stream Demo
Simple Event Driven Microservices with Spring Cloud Stream
Stars: ✭ 58 (-12.12%)
Mutual labels: microservices, event-driven
Rebus
🚌 Simple and lean service bus implementation for .NET
Stars: ✭ 1,733 (+2525.76%)
Mutual labels: microservices, message-bus
Pos
Sample Application DDD, Reactive Microservices, CQRS Event Sourcing Powered by DERMAYON LIBRARY
Stars: ✭ 207 (+213.64%)
Mutual labels: microservices, event-driven
Fluentmediator
🔀 FluentMediator is an unobtrusive library that allows developers to build custom pipelines for Commands, Queries and Events.
Stars: ✭ 128 (+93.94%)
Mutual labels: event-driven, message-bus
Akkatecture
a cqrs and event sourcing framework for dotnet core using akka.net
Stars: ✭ 414 (+527.27%)
Mutual labels: microservices, event-driven
Eventmesh
EventMesh is a dynamic cloud-native eventing infrastruture used to decouple the application and backend middleware layer, which supports a wide range of use cases that encompass complex multi-cloud, widely distributed topologies using diverse technology stacks.
Stars: ✭ 356 (+439.39%)
Mutual labels: event-driven, message-bus
Microservice Patterns
Code to share the knowledge I gained while designing and implementing micro services
Stars: ✭ 87 (+31.82%)
Mutual labels: microservices, event-driven
Pitstop
This repo contains a sample application based on a Garage Management System for Pitstop - a fictitious garage. The primary goal of this sample is to demonstrate several software-architecture concepts like: Microservices, CQRS, Event Sourcing, Domain Driven Design (DDD), Eventual Consistency.
Stars: ✭ 708 (+972.73%)
Mutual labels: microservices, event-driven
Rabbus
A tiny wrapper over amqp exchanges and queues 🚌 ✨
Stars: ✭ 86 (+30.3%)
Mutual labels: microservices, event-driven
Dapr
Dapr is a portable, event-driven, runtime for building distributed applications across cloud and edge.
Stars: ✭ 16,274 (+24557.58%)
Mutual labels: microservices, event-driven
Qmq
QMQ是去哪儿网内部广泛使用的消息中间件,自2012年诞生以来在去哪儿网所有业务场景中广泛的应用,包括跟交易息息相关的订单场景; 也包括报价搜索等高吞吐量场景。
Stars: ✭ 2,420 (+3566.67%)
Mutual labels: event-driven, message-bus
Space Cloud
Open source Firebase + Heroku to develop, scale and secure serverless apps on Kubernetes
Stars: ✭ 3,323 (+4934.85%)
Mutual labels: microservices, event-driven
incubator-eventmesh
EventMesh is a dynamic event-driven application runtime used to decouple the application and backend middleware layer, which supports a wide range of use cases that encompass complex multi-cloud, widely distributed topologies using diverse technology stacks.
Stars: ✭ 939 (+1322.73%)
Mutual labels: message-bus, event-driven
Plumber
A swiss army knife CLI tool for interacting with Kafka, RabbitMQ and other messaging systems.
Stars: ✭ 514 (+678.79%)
Mutual labels: event-driven, message-bus
Remit
RabbitMQ-backed microservices supporting RPC, pubsub, automatic service discovery and scaling with no code changes.
Stars: ✭ 24 (-63.64%)
Mutual labels: microservices, event-driven
Tinyipc
.NET inter process broadcast message bus with supporting classes
Stars: ✭ 55 (-16.67%)
Mutual labels: message-bus
Event Bus NSQ
Installation
go get -u github.com/rafaeljesus/nsq-event-bus
Usage
The nsq-event-bus package exposes a interface for emitting and listening events.
Emitter
import "github.com/rafaeljesus/nsq-event-bus"
topic := "events"
emitter, err := bus.NewEmitter(bus.EmitterConfig{
Address: "localhost:4150",
MaxInFlight: 25,
})
e := event{}
if err = emitter.Emit(topic, &e); err != nil {
// handle failure to emit message
}
// emitting messages on a async fashion
if err = emitter.EmitAsync(topic, &e); err != nil {
// handle failure to emit message
}
Listener
import "github.com/rafaeljesus/nsq-event-bus"
if err = bus.On(bus.ListenerConfig{
Topic: "topic",
Channel: "test_on",
HandlerFunc: handler,
HandlerConcurrency: 4,
}); err != nil {
// handle failure to listen a message
}
func handler(message *Message) (reply interface{}, err error) {
e := event{}
if err = message.DecodePayload(&e); err != nil {
message.Finish()
return
}
if message.Attempts > MAX_DELIVERY_ATTEMPTS {
message.Finish()
return
}
err, _ = doWork(&e)
if err != nil {
message.Requeue(BACKOFF_TIME)
return
}
message.Finish()
return
}
Request (Request/Reply)
import "github.com/rafaeljesus/nsq-event-bus"
topic := "user_signup"
emitter, err = bus.NewEmitter(bus.EmitterConfig{})
e := event{Login: "rafa", Password: "ilhabela_is_the_place"}
if err = bus.Request(topic, &e, handler); err != nil {
// handle failure to listen a message
}
func handler(message *Message) (reply interface{}, err error) {
e := event{}
if err = message.DecodePayload(&e); err != nil {
message.Finish()
return
}
reply = &Reply{}
message.Finish()
return
}
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
Badges
GitHub @rafaeljesus · Medium @_jesus_rafael · Twitter @_jesus_rafael
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].