Git Product home page Git Product logo

o5-messaging's Introduction

O5 Messaging

Messaging defines the way o5/j5 applications share data. There are three topologies available, defined below.

Applications are called Workers when they are the recipient of messages, Senders are the ... sender.

Workers expose gRPC endpoints for each group of messages they receive, and an rpc endpoint for each specific message type.

The gRPC definition for all messaging endpoints must return google.protobuf.Empty - even for Reply type queues - as no service should ever be waiting for a reply.

service FooTopic {
  option (pentops.messaging.v1.config).broadcast.topic_name = "foo";
  rpc Bar(BarMessage) returns (google.protobuf.Empty);
}

Senders fall into two broad categories: Those with databases and those without.

Any sender with a database should use the Outbox pattern, where outbound messages are stored in a table, and committed atomically with other database changes. The platform will then take messages from the outbox table and send the message through the messaging infrastructure.

Senders without databases, e.g. a translation service, or even senders which have a database but do not mutate state in message processing (e.g. a read-only lookup reply) can instead send messages to the messaging infrastrcutre using gRPC requests intercepted by the platform. The platform will expose the gRPC service as defined in the protos and foward the messages as required. The platform returns OK + Empty when the message has been safely stored in the messaging infrastructure.

Broadcast

Broadcast Topology

  • Zero or more Sender applications
  • Exactly one 'Topic'
  • Zero or more Worker applications

Unicast

Unicast Topology

  • Zero or more Sender applications
  • Exactly one Worker application

Reply

Reply Topology

  • Exactly one Worker application
  • Exactly one Input Queue
  • Zero or more Sender applications

o5-messaging's People

Contributors

daemonl avatar

Watchers

Daniel Hess avatar Matthew Mayer avatar Brent Johnson avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.