nexus-actors/skeleton

Minimal skeleton for building applications on the Nexus actor system (PHP 8.5+).

Maintainers

Package info

github.com/nexus-actors/skeleton

Type:project

pkg:composer/nexus-actors/skeleton

Transparency log

Statistics

Installs: 3

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v0.1.0 2026-07-21 18:21 UTC

This package is auto-updated.

Last update: 2026-07-21 18:30:27 UTC


README

Start a Nexus actor-system project in three commands:

composer create-project nexus-actors/skeleton my-app
cd my-app
bin/console run

create-project launches an interactive setup wizard (nexus:setup) that picks your runtime (Fiber for development, Swoole for production) and optional modules — persistence, OpenTelemetry observability, TCP clustering, and the Symfony Messenger bridge. TCP clustering and the Symfony Messenger bridge are marked experimental: pre-1.0, not production-ready, APIs may change.

Everyday commands

bin/console make:actor Payment --with-message   # generate src/Actor/PaymentActor.php + message
bin/console make:actor Ticker --functional      # closure-based actor (Behavior::receive factory)
bin/console make:actor Order --type=event-sourced   # persistent actor factory (also: stateful, durable-state)
bin/console make:message OrderPlaced            # generate src/Message/OrderPlaced.php
bin/console run                                 # boot the actor system (alias of nexus:run)
bin/console nexus:setup                         # re-run the wizard to add modules later

Project layout

bin/console            command-line entry point
config/services.php    DI container config (autowires src/)
config/packages/       per-module config (runtime.php picks your Runtime)
src/Actor/             #[AsActor] handlers — auto-spawned at boot
src/Message/           message classes
src/Kernel.php         boots the container and the ActorSystem

Actors are plain classes with #[AsActor('name')] — the Kernel spawns every tagged handler at boot. See the Quick Start for a guided tour.