Skip to content

Commit 346df91

Browse files
CAFernandesclaude
andcommitted
Refactor: Complete migration from Express PHP to HelixPHP v1.0.0
This commit includes: - Complete namespace migration from Express\ to Helix- Package rename from cafernandes/express-php to helixphp/core - Version reset to 1.0.0 for the new HelixPHP brand - Updated all documentation and README files - All tests passing (247 tests, 692 assertions) - Updated composer.json with new package information - Fixed all internal class references and dependencies This is the first official release under the HelixPHP brand. Co-Authored-By: Claude <[email protected]>
1 parent 9eb806c commit 346df91

File tree

216 files changed

+921
-893
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

216 files changed

+921
-893
lines changed

CHANGELOG.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,33 @@
11
# Changelog
22

3+
All notable changes to this project will be documented in this file.
4+
5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7+
8+
## [1.0.0] - 2024-01-06
9+
10+
### Changed
11+
- Complete rebrand from Express PHP to HelixPHP
12+
- All namespaces changed from `Express\` to `Helix\`
13+
- Package name changed from `cafernandes/express-php` to `helixphp/core`
14+
- Repository moved to HelixPHP organization
15+
- Version reset to 1.0.0 for the new brand
16+
17+
### Added
18+
- New HelixPHP branding and documentation
19+
- Migration guide for existing Express PHP users
20+
21+
### Note
22+
This is the first release under the HelixPHP brand. For previous versions, see the Express PHP project history.
23+
24+
25+
---
26+
27+
## Previous Express PHP History
28+
29+
# Changelog
30+
331
Todas as mudanças notáveis no Express-PHP Framework serão documentadas neste arquivo.
432

533
O formato é baseado em [Keep a Changelog](https://keepachangelog.com/pt-BR/1.0.0/),

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
1-
# Express PHP Microframework
1+
# HelixPHP Microframework
22

33
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
44
[![PHP Version](https://img.shields.io/badge/PHP-8.1%2B-blue.svg)](https://php.net)
55
[![PHPStan Level](https://img.shields.io/badge/PHPStan-Level%209-brightgreen.svg)](https://phpstan.org/)
66
[![PSR-12](https://img.shields.io/badge/PSR--12%20%2F%20PSR--15-compliant-brightgreen)](https://www.php-fig.org/psr/psr-12/)
7-
[![GitHub Issues](https://img.shields.io/github/issues/CAFernandes/express-php)](https://github.com/CAFernandes/express-php/issues)
8-
[![GitHub Stars](https://img.shields.io/github/stars/CAFernandes/express-php)](https://github.com/CAFernandes/express-php/stargazers)
7+
[![GitHub Issues](https://img.shields.io/github/issues/CAFernandes/helixphp-core)](https://github.com/CAFernandes/helixphp-core/issues)
8+
[![GitHub Stars](https://img.shields.io/github/stars/CAFernandes/helixphp-core)](https://github.com/CAFernandes/helixphp-core/stargazers)
99

1010
---
1111

12-
## 🚀 O que é o Express PHP?
12+
## 🚀 O que é o HelixPHP?
1313

14-
**Express PHP** é um microframework moderno, leve e seguro, inspirado no Express.js, para construir APIs e aplicações web de alta performance em PHP. Foco em produtividade, arquitetura desacoplada e extensibilidade real.
14+
**HelixPHP** é um microframework moderno, leve e seguro, inspirado no Express.js, para construir APIs e aplicações web de alta performance em PHP. Foco em produtividade, arquitetura desacoplada e extensibilidade real.
1515

1616
- **Alta Performance**: 2.57M ops/sec em CORS, 2.27M ops/sec em Response, 757K ops/sec roteamento, cache integrado.
1717
- **Arquitetura Moderna**: DI Container, Service Providers, Event System, Extension System e PSR-15.
@@ -53,7 +53,7 @@ Veja exemplos práticos em [`examples/`](examples/), benchmarks reais em [`bench
5353
### Instalação
5454

5555
```bash
56-
composer require cafernandes/express-php
56+
composer require cafernandes/helixphp-core
5757
```
5858

5959
### Exemplo Básico
@@ -105,7 +105,7 @@ Principais links:
105105

106106
## 🤝 Como Contribuir
107107

108-
Quer ajudar a evoluir o Express PHP? Veja o [Guia de Contribuição](CONTRIBUTING.md) ou acesse [`docs/contributing/`](docs/contributing/) para saber como abrir issues, enviar PRs ou criar extensões.
108+
Quer ajudar a evoluir o HelixPHP? Veja o [Guia de Contribuição](CONTRIBUTING.md) ou acesse [`docs/contributing/`](docs/contributing/) para saber como abrir issues, enviar PRs ou criar extensões.
109109

110110
---
111111

benchmarks/AdvancedOptimizationsBenchmark.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
require_once __DIR__ . '/../vendor/autoload.php';
44

5-
use Express\Http\Psr7\Pool\DynamicPoolManager;
6-
use Express\Http\Psr7\Pool\EnhancedStreamPool;
7-
use Express\Http\Psr7\Pool\HeaderPool;
8-
use Express\Http\Psr7\Cache\IntelligentJsonCache;
9-
use Express\Utils\Utils;
5+
use Helix\Http\Psr7\Pool\DynamicPoolManager;
6+
use Helix\Http\Psr7\Pool\EnhancedStreamPool;
7+
use Helix\Http\Psr7\Pool\HeaderPool;
8+
use Helix\Http\Psr7\Cache\IntelligentJsonCache;
9+
use Helix\Utils\Utils;
1010

1111
/**
1212
* Benchmark for New Optimization Features

benchmarks/AdvancedOptimizationsPhase2Benchmark.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@
22

33
require_once __DIR__ . '/../vendor/autoload.php';
44

5-
use Express\Middleware\MiddlewarePipelineCompiler;
6-
use Express\Routing\RouteMemoryManager;
7-
use Express\Http\Psr7\Cache\ProbabilisticCache;
8-
use Express\Http\Psr7\Cache\AdaptiveLearningCache;
5+
use Helix\Middleware\MiddlewarePipelineCompiler;
6+
use Helix\Routing\RouteMemoryManager;
7+
use Helix\Http\Psr7\Cache\ProbabilisticCache;
8+
use Helix\Http\Psr7\Cache\AdaptiveLearningCache;
99

1010
/**
1111
* Comprehensive Benchmark for Advanced Optimizations Phase 2

benchmarks/AdvancedOptimizationsPhase3Benchmark.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22

33
require_once __DIR__ . '/../vendor/autoload.php';
44

5-
use Express\Middleware\MiddlewarePipelineCompiler;
6-
use Express\Routing\RouteMemoryManager;
7-
use Express\Http\Psr7\Cache\ProbabilisticCache;
8-
use Express\Http\Psr7\Cache\AdaptiveLearningCache;
9-
use Express\Http\Psr7\Cache\PredictiveCacheWarmer;
10-
use Express\Http\Optimization\ZeroCopyOptimizer;
11-
use Express\Http\Optimization\MemoryMappingManager;
5+
use Helix\Middleware\MiddlewarePipelineCompiler;
6+
use Helix\Routing\RouteMemoryManager;
7+
use Helix\Http\Psr7\Cache\ProbabilisticCache;
8+
use Helix\Http\Psr7\Cache\AdaptiveLearningCache;
9+
use Helix\Http\Psr7\Cache\PredictiveCacheWarmer;
10+
use Helix\Http\Optimization\ZeroCopyOptimizer;
11+
use Helix\Http\Optimization\MemoryMappingManager;
1212

1313
/**
1414
* Advanced Optimizations Phase 3 Benchmark

benchmarks/ComprehensivePerformanceAnalysis.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
require_once __DIR__ . '/../vendor/autoload.php';
1515

16-
use Express\Utils\Utils;
16+
use Helix\Utils\Utils;
1717

1818
class ComprehensivePerformanceAnalysis
1919
{
@@ -118,15 +118,15 @@ private function benchmarkExpressCore(): void
118118
{
119119
echo " 📈 Testing Express core performance...\n";
120120

121-
// require_once __DIR__ . '/../src/ApiExpress.php';
121+
// require_once __DIR__ . '/../src/ApiHelix.php';
122122
// Usar Application diretamente
123123
$iterations = 1000;
124124
$results = [];
125125

126126
// App initialization
127127
$start = microtime(true);
128128
for ($i = 0; $i < $iterations; $i++) {
129-
$app = new \Express\Core\Application();
129+
$app = new \Helix\Core\Application();
130130
}
131131
$end = microtime(true);
132132
$results['app_initialization'] = [
@@ -135,7 +135,7 @@ private function benchmarkExpressCore(): void
135135
];
136136

137137
// Route registration
138-
$app = new \Express\Core\Application();
138+
$app = new \Helix\Core\Application();
139139
$start = microtime(true);
140140
for ($i = 0; $i < $iterations; $i++) {
141141
$app->get("/test{$i}", function($req, $res) {
@@ -159,8 +159,8 @@ private function benchmarkPSRCompliance(): void
159159
$iterations = 1000;
160160

161161
// PSR-7 Response creation
162-
if (class_exists('\Express\Http\Psr7\Factory\ResponseFactory')) {
163-
$factory = new \Express\Http\Psr7\Factory\ResponseFactory();
162+
if (class_exists('\Helix\Http\Psr7\Factory\ResponseFactory')) {
163+
$factory = new \Helix\Http\Psr7\Factory\ResponseFactory();
164164

165165
$start = microtime(true);
166166
for ($i = 0; $i < $iterations; $i++) {
@@ -175,8 +175,8 @@ private function benchmarkPSRCompliance(): void
175175
}
176176

177177
// PSR-7 Request creation
178-
if (class_exists('\Express\Http\Psr7\Factory\ServerRequestFactory')) {
179-
$factory = new \Express\Http\Psr7\Factory\ServerRequestFactory();
178+
if (class_exists('\Helix\Http\Psr7\Factory\ServerRequestFactory')) {
179+
$factory = new \Helix\Http\Psr7\Factory\ServerRequestFactory();
180180

181181
$start = microtime(true);
182182
for ($i = 0; $i < $iterations; $i++) {
@@ -200,8 +200,8 @@ private function benchmarkAdvancedOptimizations(): void
200200
$results = [];
201201

202202
// Middleware Pipeline Compiler
203-
if (class_exists('\Express\Middleware\MiddlewarePipelineCompiler')) {
204-
$compiler = \Express\Middleware\MiddlewarePipelineCompiler::class;
203+
if (class_exists('\Helix\Middleware\MiddlewarePipelineCompiler')) {
204+
$compiler = \Helix\Middleware\MiddlewarePipelineCompiler::class;
205205

206206
$middlewares = [
207207
function($req, $res, $next) { return $next($req, $res); },
@@ -224,8 +224,8 @@ function($req, $res, $next) { return $next($req, $res); }
224224
}
225225

226226
// Zero-Copy Optimizations
227-
if (class_exists('\Express\Http\Optimization\ZeroCopyOptimizer')) {
228-
$optimizer = \Express\Http\Optimization\ZeroCopyOptimizer::class;
227+
if (class_exists('\Helix\Http\Optimization\ZeroCopyOptimizer')) {
228+
$optimizer = \Helix\Http\Optimization\ZeroCopyOptimizer::class;
229229

230230
$iterations = 1000;
231231
$testStrings = array_fill(0, 100, 'test string for optimization');
@@ -416,7 +416,7 @@ private function generateMarkdownReport(): void
416416
$md .= "Generated: " . date('Y-m-d H:i:s') . "\n\n";
417417

418418
$md .= "## Executive Summary\n\n";
419-
$md .= "This report provides a comprehensive analysis of the Express PHP framework performance across three major phases:\n\n";
419+
$md .= "This report provides a comprehensive analysis of the HelixPHP framework performance across three major phases:\n\n";
420420
$md .= "1. **Pre-PSR Implementation**: Traditional PHP framework approach\n";
421421
$md .= "2. **PSR-7/PSR-15 Implementation**: Standards-compliant HTTP message handling\n";
422422
$md .= "3. **Advanced Optimizations**: High-performance features and optimizations\n\n";
@@ -531,7 +531,7 @@ private function generateMarkdownReport(): void
531531
$md .= "4. **JIT Compilation**: Consider PHP 8+ JIT compilation optimizations\n\n";
532532

533533
$md .= "---\n";
534-
$md .= "*Report generated by Express PHP Framework Performance Analysis Tool*\n";
534+
$md .= "*Report generated by HelixPHP Framework Performance Analysis Tool*\n";
535535

536536
$markdownFile = $this->reportDir . '/COMPREHENSIVE_PERFORMANCE_ANALYSIS.md';
537537
file_put_contents($markdownFile, $md);

benchmarks/DatabaseBenchmark.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44

55
require_once __DIR__ . '/../vendor/autoload.php';
66

7-
use Express\Core\Application;
8-
use Express\Database\PDOConnection;
9-
use Express\Http\Request;
10-
use Express\Http\Response;
7+
use Helix\Core\Application;
8+
use Helix\Database\PDOConnection;
9+
use Helix\Http\Request;
10+
use Helix\Http\Response;
1111

1212
/**
13-
* Database Benchmark for Express PHP
13+
* Database Benchmark for HelixPHP
1414
*
1515
* Tests performance with real database operations
1616
* Simulates production-like scenarios
@@ -104,7 +104,7 @@ private function setupDatabase(): void
104104
}
105105

106106
/**
107-
* Setup Express PHP routes for benchmarking
107+
* Setup HelixPHP routes for benchmarking
108108
*/
109109
private function setupRoutes(): void
110110
{
@@ -236,7 +236,7 @@ private function setupRoutes(): void
236236
*/
237237
public function run(): void
238238
{
239-
echo "🚀 Express PHP Database Benchmark\n";
239+
echo "🚀 HelixPHP Database Benchmark\n";
240240
echo "================================\n\n";
241241

242242
// Warmup

benchmarks/EnhancedAdvancedOptimizationsBenchmark.php

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111

1212
require_once __DIR__ . '/../vendor/autoload.php';
1313

14-
use Express\Middleware\MiddlewarePipelineCompiler;
15-
use Express\Http\Optimization\ZeroCopyOptimizer;
16-
use Express\Http\Optimization\MemoryMappingManager;
17-
use Express\Http\Psr7\Cache\PredictiveCacheWarmer;
18-
use Express\Routing\RouteMemoryManager;
14+
use Helix\Middleware\MiddlewarePipelineCompiler;
15+
use Helix\Http\Optimization\ZeroCopyOptimizer;
16+
use Helix\Http\Optimization\MemoryMappingManager;
17+
use Helix\Http\Psr7\Cache\PredictiveCacheWarmer;
18+
use Helix\Routing\RouteMemoryManager;
1919

2020
class EnhancedAdvancedOptimizationsBenchmark
2121
{
@@ -69,7 +69,7 @@ private function clearOptimizationStats(): void
6969
MiddlewarePipelineCompiler::clearAll();
7070
ZeroCopyOptimizer::reset();
7171

72-
if (class_exists('Express\Routing\RouteMemoryManager')) {
72+
if (class_exists('Helix\Routing\RouteMemoryManager')) {
7373
RouteMemoryManager::clearAll();
7474
}
7575
}
@@ -334,7 +334,7 @@ private function benchmarkMemoryMapping(): void
334334
{
335335
echo "🔮 Testing Enhanced Predictive Cache Warming...\n";
336336

337-
if (!class_exists('Express\Http\Psr7\Cache\PredictiveCacheWarmer')) {
337+
if (!class_exists('Helix\Http\Psr7\Cache\PredictiveCacheWarmer')) {
338338
echo " Predictive Cache Warmer not available\n";
339339
$this->results['predictive_cache'] = ['status' => 'not_available'];
340340
return;
@@ -414,7 +414,7 @@ private function benchmarkRouteMemoryManager(): void
414414
{
415415
echo "🛣️ Testing Enhanced Route Memory Manager...\n";
416416

417-
if (!class_exists('Express\Routing\RouteMemoryManager')) {
417+
if (!class_exists('Helix\Routing\RouteMemoryManager')) {
418418
echo " Route Memory Manager not available\n";
419419
$this->results['route_memory'] = ['status' => 'not_available'];
420420
return;
@@ -495,7 +495,7 @@ function($req, $res, $next) { return $next($req, $res); }
495495
}
496496

497497
// Route tracking
498-
if (class_exists('Express\Routing\RouteMemoryManager')) {
498+
if (class_exists('Helix\Routing\RouteMemoryManager')) {
499499
RouteMemoryManager::trackRouteUsage("integrated_route_{$i}");
500500
$operations++;
501501
}
@@ -507,7 +507,7 @@ function($req, $res, $next) { return $next($req, $res); }
507507
// Get final stats from all components
508508
$pipelineStats = MiddlewarePipelineCompiler::getStats();
509509
$zeroCopyStats = ZeroCopyOptimizer::getStats();
510-
$routeStats = class_exists('Express\Routing\RouteMemoryManager') ?
510+
$routeStats = class_exists('Helix\Routing\RouteMemoryManager') ?
511511
RouteMemoryManager::getStats() : ['status' => 'not_available'];
512512

513513
$this->results['integrated_performance'] = [

benchmarks/ExpressPhpBenchmark.php

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
<?php
22
/**
3-
* Express PHP Framework - Benchmark Suite
3+
* HelixPHP Framework - Benchmark Suite
44
*
5-
* Comprehensive performance testing for Express PHP Framework
5+
* Comprehensive performance testing for HelixPHP Framework
66
* Tests various aspects: routing, middleware, authentication, etc.
77
*/
88

99
declare(strict_types=1);
1010

1111
require_once __DIR__ . '/../vendor/autoload.php';
1212

13-
use Express\Core\Application;
14-
use Express\Http\Request;
15-
use Express\Http\Response;
16-
use Express\Middleware\Security\CsrfMiddleware;
17-
use Express\Middleware\Security\XssMiddleware;
18-
use Express\Middleware\Security\CorsMiddleware;
19-
use Express\Middleware\Core\RateLimitMiddleware;
20-
use Express\Authentication\JWTHelper;
21-
use Express\Utils\Utils;
22-
23-
class ExpressPhpBenchmark
13+
use Helix\Core\Application;
14+
use Helix\Http\Request;
15+
use Helix\Http\Response;
16+
use Helix\Middleware\Security\CsrfMiddleware;
17+
use Helix\Middleware\Security\XssMiddleware;
18+
use Helix\Middleware\Security\CorsMiddleware;
19+
use Helix\Middleware\Core\RateLimitMiddleware;
20+
use Helix\Authentication\JWTHelper;
21+
use Helix\Utils\Utils;
22+
23+
class HelixPhpBenchmark
2424
{
2525
private array $results = [];
2626
private int $iterations = 1000;
@@ -35,7 +35,7 @@ public function __construct(int $iterations = 1000)
3535
*/
3636
public function runAll(): void
3737
{
38-
echo "🚀 Express PHP Framework - Performance Benchmark\n";
38+
echo "🚀 HelixPHP Framework - Performance Benchmark\n";
3939
echo "================================================\n";
4040
echo "Iterations per test: " . number_format($this->iterations) . "\n";
4141
echo "PHP Version: " . PHP_VERSION . "\n";
@@ -434,7 +434,7 @@ private function generateReport(): void
434434
*/
435435
private function generateMarkdownSummary(): void
436436
{
437-
$markdown = "# Express PHP Framework - Performance Benchmark\n\n";
437+
$markdown = "# HelixPHP Framework - Performance Benchmark\n\n";
438438
$markdown .= "## Test Environment\n";
439439
$markdown .= "- **Date**: " . date('Y-m-d H:i:s') . "\n";
440440
$markdown .= "- **PHP Version**: " . PHP_VERSION . "\n";
@@ -465,7 +465,7 @@ private function generateMarkdownSummary(): void
465465
}
466466

467467
$markdown .= "\n## Performance Summary\n";
468-
$markdown .= "Express PHP demonstrates excellent performance characteristics:\n\n";
468+
$markdown .= "HelixPHP demonstrates excellent performance characteristics:\n\n";
469469

470470
// Find best performing tests
471471
$sortedResults = $this->results;
@@ -493,6 +493,6 @@ private function generateMarkdownSummary(): void
493493
// Run benchmarks if called directly
494494
if (basename(__FILE__) === basename($_SERVER['SCRIPT_NAME'])) {
495495
$iterations = (int)($argv[1] ?? 1000);
496-
$benchmark = new ExpressPhpBenchmark($iterations);
496+
$benchmark = new HelixPhpBenchmark($iterations);
497497
$benchmark->runAll();
498498
}

0 commit comments

Comments
 (0)