docs: consolidate documentation into organized structure

- Move 12 markdown files from root to docs/ subdirectories
- Organize documentation by category:
  • docs/troubleshooting/ (1 file)  - Technical troubleshooting guides
  • docs/deployment/      (4 files) - Deployment and security documentation
  • docs/guides/          (3 files) - Feature-specific guides
  • docs/planning/        (4 files) - Planning and improvement proposals

Root directory cleanup:
- Reduced from 16 to 4 markdown files in root
- Only essential project files remain:
  • CLAUDE.md (AI instructions)
  • README.md (Main project readme)
  • CLEANUP_PLAN.md (Current cleanup plan)
  • SRC_STRUCTURE_IMPROVEMENTS.md (Structure improvements)

This improves:
 Documentation discoverability
 Logical organization by purpose
 Clean root directory
 Better maintainability
This commit is contained in:
2025-10-05 11:05:04 +02:00
parent 887847dde6
commit 5050c7d73a
36686 changed files with 196456 additions and 12398919 deletions

View File

@@ -6,9 +6,11 @@ namespace App\Framework\Logging;
use App\Framework\Config\TypedConfiguration;
use App\Framework\Core\PathProvider;
use App\Framework\DI\Container;
use App\Framework\DI\Initializer;
use App\Framework\Logging\Handlers\ConsoleHandler;
use App\Framework\Logging\Handlers\FileHandler;
use App\Framework\Logging\Handlers\MultiFileHandler;
use App\Framework\Logging\Handlers\QueuedLogHandler;
use App\Framework\Logging\Handlers\WebHandler;
use App\Framework\Queue\FileQueue;
@@ -20,8 +22,18 @@ use App\Framework\Redis\RedisConnection;
final readonly class LoggerInitializer
{
#[Initializer]
public function __invoke(TypedConfiguration $config, PathProvider $pathProvider): Logger
public function __invoke(TypedConfiguration $config, PathProvider $pathProvider, Container $container): Logger
{
// LogContextManager als Singleton im Container registrieren
if (! $container->has(LogContextManager::class)) {
$contextManager = new LogContextManager();
$container->singleton(LogContextManager::class, $contextManager);
// Globalen Kontext mit App-Informationen initialisieren
$contextManager->addGlobalData('app_version', $config->app->version);
$contextManager->addGlobalData('environment', $config->app->environment->value);
$contextManager->addGlobalTags('application', 'framework');
}
$processorManager = new ProcessorManager();
// Set log level based on environment
@@ -52,6 +64,17 @@ final readonly class LoggerInitializer
$handlers[] = new QueuedLogHandler($queue);
$handlers[] = new WebHandler();
// MultiFileHandler für automatisches Channel-Routing
$handlers[] = new MultiFileHandler(
$logConfig,
$pathProvider,
$minLevel,
'[{timestamp}] [{level_name}] [{channel}] {message}',
0644
);
// Fallback FileHandler für Kompatibilität (nur für 'app' Channel ohne Channel-Info)
$handlers[] = new FileHandler(
$logConfig->getLogPath('app'),
$minLevel,
@@ -61,10 +84,14 @@ final readonly class LoggerInitializer
$pathProvider
);
// LogContextManager aus Container holen
$contextManager = $container->get(LogContextManager::class);
return new DefaultLogger(
minLevel: $minLevel,
handlers: $handlers,
processorManager: $processorManager,
contextManager: $contextManager,
);
}
}