thephpleague/tactician

A small, flexible command bus

PHP

863

203 commits

updated Dec 21, 2025

See the code

README

Tactician

Scrutinizer Code Quality Code Coverage Build Status MIT License SensioLabsInsight

A small, pluggable command bus.

See the full docs or the examples directory to get started.

Install

Using Composer:

composer require league/tactician

Plugins

The core Tactician package is small but there are several plugin packages that extend the usefulness of Tactician:

  • Logger: Adds PSR-3 logging support for receiving, completing or failing commands.
  • Container: Lazy load handlers from any container implementing container-interop.
  • Doctrine: Wraps commands in separate Doctrine ORM transactions.
  • Bernard: Allows queuing your commands in the background, using the Bernard Queuing library.
  • Command Events: Fires events for all major moments in the command life-cycle.
  • Locking: Only allows one command to be executed at a time.
  • and many more

Framework Integration

There are a number of framework integration packages for Tactician, search for Tactician on Packagist for the most up-to-date listings.

Testing

To run all unit tests, use the locally installed PHPUnit:

$ ./vendor/bin/phpunit

Security

Tactician has no previous security disclosures and due to the nature of the project is unlikely to. However, if you're concerned you've found a security sensitive issue in Tactician or one of its related projects, please email disclosures [at] rosstuck dot com.

Contributing

Please see CONTRIBUTING for details.

command-bus
hacktoberfest
tactician

thephpleague/tactician

A small, flexible command bus

PHP

863

203 commits

updated Dec 21, 2025

See the code

README

Tactician

Scrutinizer Code Quality Code Coverage Build Status MIT License SensioLabsInsight

A small, pluggable command bus.

See the full docs or the examples directory to get started.

Install

Using Composer:

composer require league/tactician

Plugins

The core Tactician package is small but there are several plugin packages that extend the usefulness of Tactician:

  • Logger: Adds PSR-3 logging support for receiving, completing or failing commands.
  • Container: Lazy load handlers from any container implementing container-interop.
  • Doctrine: Wraps commands in separate Doctrine ORM transactions.
  • Bernard: Allows queuing your commands in the background, using the Bernard Queuing library.
  • Command Events: Fires events for all major moments in the command life-cycle.
  • Locking: Only allows one command to be executed at a time.
  • and many more

Framework Integration

There are a number of framework integration packages for Tactician, search for Tactician on Packagist for the most up-to-date listings.

Testing

To run all unit tests, use the locally installed PHPUnit:

$ ./vendor/bin/phpunit

Security

Tactician has no previous security disclosures and due to the nature of the project is unlikely to. However, if you're concerned you've found a security sensitive issue in Tactician or one of its related projects, please email disclosures [at] rosstuck dot com.

Contributing

Please see CONTRIBUTING for details.

command-bus
hacktoberfest
tactician

Project health

Overall

3.3/10

Maintained

0/10

Code review

5/10
OpenSSF Scorecard

Significant stargazers

Luís Cobucci

1,127 followers · starred Apr 2018

Michael Moravec

195 followers · starred Mar 2019

Jáchym Toušek

119 followers · starred Feb 2020

Benjamin Morel

238 followers · starred Oct 2020