components-contrib/pubsub
Francisco Beltrao 8086a01455 Fix azure service bus error message typo (#117) 2019-11-11 12:29:56 -08:00
..
azureservicebus Fix azure service bus error message typo (#117) 2019-11-11 12:29:56 -08:00
nats Use consumerID for queue name (#99) 2019-11-04 11:42:21 -08:00
redis Add TLS connection option to Redis pub sub (#96) 2019-11-04 11:00:57 -08:00
Readme.md Azure ServiceBus PubSub Implementation (#93) 2019-11-05 14:50:48 -08:00
envelope.go added cloud events content type (#32) 2019-10-14 12:52:39 -07:00
envelope_test.go Adding license header and updating to MIT license. (#26) 2019-10-09 10:58:08 -07:00
metadata.go Adding license header and updating to MIT license. (#26) 2019-10-09 10:58:08 -07:00
pubsub.go Adding license header and updating to MIT license. (#26) 2019-10-09 10:58:08 -07:00
requests.go Adding license header and updating to MIT license. (#26) 2019-10-09 10:58:08 -07:00

Readme.md

Pub Sub

Pub Subs provide a common way to interact with different message bus implementations to achieve reliable, high-scale scenarios based on event-driven async communications, while allowing users to opt-in to advanced capabilities using defined metadata.

Currently supported pub-subs are:

  • Redis Streams
  • NATS
  • Azure Service Bus

Implementing a new Pub Sub

A compliant pub sub needs to implement the following interface:

type PubSub interface {
	Init(metadata Metadata) error
	Publish(req *PublishRequest) error
	Subscribe(req SubscribeRequest, handler func(msg *NewMessage) error) error
}