warning("[ErrorAggregation] Pattern alert triggered", \App\Framework\Logging\ValueObjects\LogContext::withData([ 'pattern_id' => $this->patternId, 'event_id' => $this->eventId, 'urgency' => $this->urgency->value, 'occurrence_count' => $this->patternData['occurrence_count'] ?? 0 ]) ); } // Here you would: // 1. Send notifications to ops team // 2. Trigger alerting systems (PagerDuty, Slack, etc.) // 3. Create incident tickets // 4. Update monitoring dashboards return [ 'type' => 'error_pattern_alert', 'pattern_id' => $this->patternId, 'event_id' => $this->eventId, 'urgency' => $this->urgency->value, 'processed_at' => time(), 'success' => true ]; } public function getType(): string { return 'error_aggregation.alert'; } }