English | 中文文档
SuperKernel is a component-oriented PHP framework for long-running Swoole applications. Each component is an independent Composer package under super-kernel/*, built on native PHP Attributes, a PSR-11 container, and standard PSR interfaces. SKERNEL, its command-line tool, creates, builds, runs, and packages SuperKernel projects.
- New to SuperKernel: follow Getting started from installing SKERNEL to a running application.
- Before deploying or packaging: read Building and metadata, which explains what
skernel buildgenerates and when it must run again. - Working with one package: open its page below. Every page has the same parts: the package's purpose, its capabilities with complete examples, its relation to other packages, and, where misuse is costly, what not to do.
- Each repository's README is a short entry point with installation, a quick start, and the package's public surface; it links back to the package's page here.
Examples use the layout of a project created from super-kernel/skeleton: application classes under src/ in the Src\ namespace, and scripts under bin/.
- Getting started: install SKERNEL, create a project, run it, change it, build it, and package it.
- Building and metadata: what
skernel buildgenerates, why an application does not scan at start, and how a missing or outdated build is reported.
- framework: the Symfony Console application runtime and its PSR-14 dispatcher adaptation.
- context: the process's application container and transparent execution-scope context.
- command: lazy registration of Symfony Console commands.
- event: the application lifecycle events published at start and at build time.
- event-dispatcher: PSR-14 event dispatching with listeners discovered from Attributes.
- exception-dispatcher: exception handlers discovered from Attributes and dispatch to them.
- di: the PSR-11 container that creates, injects, and shares the services classes declare with Attributes.
- config: a registry of typed, lazily loaded configuration sources.
- environment: ordered external property sources and strictly typed environment access.
- contract: the shared interfaces of applications, infrastructure, reflection, and events.
- support: dependency-free helpers for short-lived instances that the caller owns.
- attribute: the native PHP Attributes for configuration, dependency injection, events, and integrations.
- annotator: restoration and lookup of the Attribute records that
skernel buildgenerates. - reflector: a process-local cached reflection service.
- metadata: read-only restoration of the package metadata that
skernel buildgenerates. - autoloader: class-map autoloading and interception, created by a factory.
- composer-source-reference-plugin: deterministic source references for Composer path packages.
- aop: aspect declarations, method weaving, join points, and interceptor dispatch.
- mimic: source transformation with hash-validated file proxies and a stream fallback.
- server: creation and startup of the configured Swoole server, events for its creation and callbacks, and user processes.
- swoole: the
swoole:startcommand and main process supervision. - http-server: HTTP routing and middleware declared with Attributes, served by Swoole.
- http-message: PSR-7 messages and scoped access to the current HTTP message.
- process: supervised background processes and direct inter-process communication.
- pool: connection pools coordinated across coroutines, processes, and threads.
- logger: PSR-3 logger factories backed by Monolog, and named stdout logging.
- redis: Redis integration.
- filesystem: readable filesystem resources with a safe lifecycle.
- skeleton: the project template that
skernel newcreates an application from; Getting started walks through it. - SKERNEL: the command-line tool that creates, runs, builds, and packages a project, published as a standalone binary through GitHub Releases.
SuperKernel is released under the MIT License.