PHPackages                             black/cqrs-php - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. black/cqrs-php

AbandonedArchivedLibrary

black/cqrs-php
==============

Implements CQRS (for DDD in PHP)

v1.0.2(11y ago)52372[1 issues](https://github.com/black-project/cqrs-php/issues)PHPPHP &gt;=5.4.0

Since Aug 16Pushed 10y ago1 watchersCompare

[ Source](https://github.com/black-project/cqrs-php)[ Packagist](https://packagist.org/packages/black/cqrs-php)[ Docs](http://www.lablackroom.com)[ RSS](/packages/black-cqrs-php/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependenciesVersions (4)Used By (0)

CQRS PHP
========

[](#cqrs-php)

**CQRS in PHP** is a simple project (a folder structure) for your project build with [Domain Driven Design](http://dddcommunity.org/).

[![Latest Stable Version](https://camo.githubusercontent.com/f4030f5f8911fe6d4a8f9403d4a76900373357d1fe1dfa821ebac02ee7af83c2/68747470733a2f2f706f7365722e707567782e6f72672f626c61636b2f637172732d7068702f762f737461626c652e706e67)](https://packagist.org/packages/black/cqrs-php)[![Total Downloads](https://camo.githubusercontent.com/ef6235870bca341b7f1f927f792a3c7fc420426d36bc1357c1363f6040ca380f/68747470733a2f2f706f7365722e707567782e6f72672f626c61636b2f637172732d7068702f646f776e6c6f6164732e706e67)](https://packagist.org/packages/black/cqrs-php)

Installation
------------

[](#installation)

The recomanded way to install CQRS in PHP is through [Composer](http://getcomposer.org/):

```
{
    "require": {
        "black/cqrs-php": "@stable"
    }
}
```

**Protip:** You should browse the [`black/cqrs-php`](https://packagist.org/packages/black/cqrs-php) page to choose a stable version to use, avoid the `@stable` meta constraint.

Why?
----

[](#why)

I want to use a very basic library for CQRS without Event Sourcing. There is one Bus, register your handler with the related command and go for it!

Usage
-----

[](#usage)

1 - Create a Command implementing `Black\DDD\CQRSinPHP\Infrastructure\CQRS\Command`
2 - Create an Handler implementing `Black\DDD\CQRSinPHP\Infrastructure\CQRS\CommandHandler`
3 - Register the Handler/Command to the Bus

```
