Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cspray/delivery-service
Abstraction to allow sending intra-process messages within an asynchronous event loop.
https://github.com/cspray/delivery-service
Last synced: about 1 month ago
JSON representation
Abstraction to allow sending intra-process messages within an asynchronous event loop.
- Host: GitHub
- URL: https://github.com/cspray/delivery-service
- Owner: cspray
- License: mit
- Created: 2015-09-05T17:03:41.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-09-24T00:54:14.000Z (about 9 years ago)
- Last Synced: 2023-03-16T10:20:28.280Z (almost 2 years ago)
- Language: PHP
- Size: 195 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# DeliveryService
A library to allow transmitting and receiving messages within an asynchronous event loop.
Includes a receipt that all listeners for a given messgae have read it.This library primarily holds the interfaces designed to provide the discussed functionality
and generic implementations that are not dependent on any particular event reactor. For
functional implementations of these interfaces please check out:- [`cspray/amp-delivery-service`](https://github.com/cspray/amp-delivery-service)
**This library requires PHP7! Because of this it will not be production ready until PHP7 is.**
## Overview
Here we talk about the interfaces that provide the messaging abstraction layer we place on
top of your favorite reactor. It is assumed from this point forward that you have a high-level
understanding of event loops, promises, and promisors.
### `Message`Represents a type and a set of data that can be transmitted and received. In other words, a message.
The payload of the message can be whatever is appropriate for your domain.
```
$listenerReturnOrThrownException]}}
```### `Receiver`
Your code needs some way to receive messages; you accomplish this by adding a listener
for a specific type of Message to a Receiver.```