PHPackages                             indigophp/tactician-event-decorator - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. indigophp/tactician-event-decorator

Abandoned → [league/tactician-command-events](/?search=league%2Ftactician-command-events)ArchivedLibrary[Utility &amp; Helpers](/categories/utility)

indigophp/tactician-event-decorator
===================================

Event decorator for Tactician CommandBus implementations

033PHP

Since Jan 12Pushed 11y ago1 watchersCompare

[ Source](https://github.com/indigophp-archive/tactician-event-decorator)[ Packagist](https://packagist.org/packages/indigophp/tactician-event-decorator)[ RSS](/packages/indigophp-tactician-event-decorator/feed)WikiDiscussions develop Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

Tactician Event Decorator
=========================

[](#tactician-event-decorator)

[![Latest Version](https://camo.githubusercontent.com/971dc9fd18474cba00bed811b885a2fce36b78fd21435656efe08250b18c40cd/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f696e6469676f7068702f74616374696369616e2d6576656e742d6465636f7261746f722e7376673f7374796c653d666c61742d737175617265)](https://github.com/indigophp/tactician-event-decorator/releases)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE)[![Build Status](https://camo.githubusercontent.com/db929a29936e46b0cbd32dcba3f232d78de2a53fc25b5d8875b779ff17004481/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f696e6469676f7068702f74616374696369616e2d6576656e742d6465636f7261746f722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/indigophp/tactician-event-decorator)[![Code Coverage](https://camo.githubusercontent.com/0335c2d2282712b36ce791ecae0b8671d1d49586c17d496f5b037b9f0d7f8bf9/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f696e6469676f7068702f74616374696369616e2d6576656e742d6465636f7261746f722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/indigophp/tactician-event-decorator)[![Quality Score](https://camo.githubusercontent.com/1535e4ff28aa026e99dbe4d3191c3963eaef605c105dddb43df9d61ddfc6c612/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f696e6469676f7068702f74616374696369616e2d6576656e742d6465636f7261746f722e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/indigophp/tactician-event-decorator)[![HHVM Status](https://camo.githubusercontent.com/6b1894ae03d2cc47082d08a848c7adf642b2a402dcef22054e38551061e1e4d0/68747470733a2f2f696d672e736869656c64732e696f2f6868766d2f696e6469676f7068702f74616374696369616e2d6576656e742d6465636f7261746f722e7376673f7374796c653d666c61742d737175617265)](http://hhvm.h4cc.de/package/indigophp/tactician-event-decorator)[![Total Downloads](https://camo.githubusercontent.com/3143602589295c535aa4be979c970e414ebb4fcc09ad5dc11bfdb0a52ed1062e/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f696e6469676f7068702f74616374696369616e2d6576656e742d6465636f7261746f722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/indigophp/tactician-event-decorator)[![Dependency Status](https://camo.githubusercontent.com/a776a9ff1809836fc08f2015b4c348cebd1e9054a7bf8eec26d1bc0932563f49/68747470733a2f2f696d672e736869656c64732e696f2f76657273696f6e6579652f642f7068702f696e6469676f7068703a74616374696369616e2d6576656e742d6465636f7261746f722e7376673f7374796c653d666c61742d737175617265)](https://www.versioneye.com/php/indigophp:tactician-event-decorator)

**Event decorator for Tactician CommandBus implementations.**

Install
-------

[](#install)

Via Composer

```
$ composer require indigophp/tactician-event-decorator
```

Usage
-----

[](#usage)

When the command ran without failures:

```
use League\Event\EmitterInterface;
use League\Tactician\CommandBus\EventableCommandBus;
use League\Tactician\Event\CommandExecuted;

// $innerCommandBus = new CommandBus instance
// $emitter = new EmitterInterface instance OR null (optional)

$commandBus = new EventableCommandBus($innerCommandBus, $emitter);

$commandBus->addListener('commandExecuted', function(CommandExecuted $event) {
	// log the success
});

$commandBus->execute($command);
```

When the command ran with failures:

```
$commandBus->addListener('commandFailed', function(CommandFailed $event) {
	// log the failure
	$event->handle(); // without calling this the exception will be thrown
});

// something bad happens, exception thrown
$commandBus->execute($command);
```

Testing
-------

[](#testing)

```
$ phpspec run
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Credits
-------

[](#credits)

- [Márk Sági-Kazár](https://github.com/sagikazarmark)
- [All Contributors](https://github.com/indigophp/tactician-event-decorator/contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE) for more information.

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/0e4e105cea62b616d4cb376b08a849b6a428f646998537de150d16a8eb537b90?d=identicon)[mark.sagikazar](/maintainers/mark.sagikazar)

---

Top Contributors

[![sagikazarmark](https://avatars.githubusercontent.com/u/1226384?v=4)](https://github.com/sagikazarmark "sagikazarmark (6 commits)")

### Embed Badge

![Health badge](/badges/indigophp-tactician-event-decorator/health.svg)

```
[![Health](https://phpackages.com/badges/indigophp-tactician-event-decorator/health.svg)](https://phpackages.com/packages/indigophp-tactician-event-decorator)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
