GithubHelp home page GithubHelp logo

shipsaas / laravel-inbox-process Goto Github PK

View Code? Open in Web Editor NEW
11.0 0.0 0.0 4.71 MB

The Inbox Pattern/Process for Laravel apps. Ensure the ordering, uniqueness, and reliable handling of webhook requests.

Home Page: https://inbox.shipsaas.tech

License: MIT License

PHP 100.00%
design-patterns inbox inbox-pattern laravel library microservice exactly-once ordering sequential

laravel-inbox-process's Introduction

ShipSaaS - Laravel Inbox Process

Build & Test (MySQL & PgSQL) codecov

Talking about distributed computers & servers, it is quite normal nowadays to communicate between servers.

Unlike a regular conversation though, there's no guarantee the message gets delivered only once, arrives in the right order, or even gets a "got it!" reply.

Thus, we have Inbox Pattern to help us to achieve that.

What is the Inbox Pattern

The Inbox Pattern is a popular design pattern in the microservice architecture that ensures:

  • High availability ✅
  • Guaranteed webhook deliverance, no msg lost ✅
  • Guaranteed exactly-once/unique webhook requests ✅
  • Execute webhook requests in ORDER/sequence
  • (Optional) High visibility & debug all prev requests ✅

And with that being said:

Laravel Inbox Process (powered by ShipSaaS) ships everything out-of-the-box and helps you to roll out the inbox process in no time 😎🚀.

Supports

  • Laravel 10 & 11
  • PHP 8.2+
  • MySQL 8, MariaDB, Postgres 13+ and SQLite

Architecture Diagram

ShipSaaS - Laravel Inbox Process

Installation

Install the library:

composer require shipsaas/laravel-inbox-process

Export config & migration files and then run the migration:

php artisan vendor:publish --tag=laravel-inbox-process
php artisan migrate

Documentation & Usage

Visit: ShipSaaS Inbox Documentation

Best practices, usage & notes are well documented too 😎!

Testing

Run composer test 😆

Available Tests:

  • Unit Testing 💪
  • Integration Testing against MySQL & PostgreSQL for the inbox:work command 😎
  • Human validation (lol) 🔥

ShipSaaS loves tests, we won't ship sh!tty libraries 🌹

Contributors

  • Seth Phat

Contributions & Support the Project

Feel free to submit any PR, please follow PSR-1/PSR-12 coding conventions and testing is a must.

If this package is helpful, please give it a ⭐️⭐️⭐️. Thank you!

License

MIT License

laravel-inbox-process's People

Contributors

sethsandaru avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

laravel-inbox-process's Issues

Supports "customize" built-in inbox route

My projects have been using inbox for handling webhooks, it's super great, helpful and reduce a lot of work.

What I do like in general, is that inbox should have a configuration to let userland configure the route.

TODO

Add a new config: inbox.route-path.

Default: inbox

Final route: config('inbox.route-path')/{topic}

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.