softlivery/softwork
最新稳定版本:v2.1.0
Composer 安装命令:
composer require softlivery/softwork
包简介
SoftWork is an API-first framework for internet applications
README 文档
README
Lightweight API-first framework primitives used by the Contact Center Platform.
What this project owns
- Routing (
SoftWork\\Routing\\Router) - HTTP handler lifecycle (
SoftWork\\Handler\\HttpHandler) - Request bootstrap and proxy/PSR-7 bridge (
SoftWork\\Http\\RequestFactory) - Runtime config loading (
SoftWork\\Config\\ConfigManager) - API response rendering (
SoftWork\\EventListener\\RenderResponseListener+SoftWork\\Render\\JsonRender) - Supporting utilities (event dispatcher, error handlers)
v2.0.0 breaking changes
- Smarty/template rendering was removed from the active runtime contract.
SoftWork\\Http\\Response::$templatewas removed.- HTML/template-based responses are no longer part of framework behavior.
- Legacy static HTML assets and template files were removed from repository runtime paths.
html/is now a minimal API bootstrap surface (index.php,.htaccess).- Default startup no longer loads runtime config from
sw_parameters. - Default startup no longer bootstraps ORM/DB connections (
SoftWork\\DB\\ORMremoved). - Legacy
SoftWork\\OAuth2\\*module was removed from framework source. - Repository-local Docker scaffolding (
.docker/,docker-compose.yml) was removed.
Migration from v1.x
- Remove assignments to
Response::$template. - Return payloads via
Response::set()/Response::replace(). - Ensure consumers treat SoftWork responses as JSON (
application/json). - Move any HTML/template rendering to consumer applications, not framework core.
- Pass runtime config overrides in memory via
HttpManager::run($root, $routes, $configOverrides). - If consumer startup relied on
SoftWork\\DB\\ORM::configure(), move DB bootstrap to the consumer application. - If consumer code imported
SoftWork\\OAuth2\\*, migrate to consumer-owned OAuth implementation.
Quick start
composer install
cp .env.example .env
Quality gate
composer validate --strict
composer quality-gate
Optional local coverage run:
composer test-coverage
Documentation
- docs/README.md
- docs/V2_RELEASE_NOTES.md
- docs/INTEGRATION_FIX_PLAN.md
- docs/INTEGRATION_GUIDE.md
- docs/CONSUMER_CHECKLIST.md
- docs/COMPATIBILITY_POLICY.md
- docs/COMPATIBILITY_MATRIX.md
- docs/ENVIRONMENT.md
- docs/TESTING.md
Versioning
Current release version is stored in VERSION.
统计信息
- 总下载量: 2
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 3
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-10-03