mirror of
https://github.com/ktds-dg0501/kt-event-marketing-fe.git
synced 2025-12-06 10:16:25 +00:00
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
72 lines
3.5 KiB
Plaintext
72 lines
3.5 KiB
Plaintext
graph TB
|
|
%% KT AI 기반 소상공인 이벤트 자동 생성 서비스 - 논리 아키텍처 (Event-Driven + Kafka)
|
|
|
|
%% Services
|
|
subgraph "Services"
|
|
UserSvc["User Service<br/>• 회원가입/로그인<br/>• 프로필 관리<br/>• 회원정보 제공"]
|
|
EventSvc["Event Service<br/>• 이벤트 생성/수정/삭제<br/>• 플로우 오케스트레이션<br/>• AI 작업 요청<br/>• 배포 작업 요청<br/>• Redis → DB 저장"]
|
|
PartSvc["Participation<br/>Service<br/>• 참여 접수<br/>• 참여자 목록<br/>• 당첨자 추첨"]
|
|
AnalSvc["Analytics Service<br/>• 실시간 대시보드<br/>• 성과 분석<br/>• 채널별 통계<br/>[Circuit Breaker]"]
|
|
end
|
|
|
|
%% Async Services
|
|
subgraph "Async Services"
|
|
AISvc["AI Service<br/>• 트렌드 분석<br/>• 이벤트 추천<br/>• Redis 저장<br/>[Circuit Breaker]<br/>[Timeout: 5분]"]
|
|
ContentSvc["Content Service<br/>• Redis 데이터 읽기<br/>• SNS 이미지 생성<br/>• Redis 저장<br/>[Circuit Breaker]<br/>[Timeout: 5분]"]
|
|
DistSvc["Distribution<br/>Service<br/>• 다중 채널 배포<br/>[Circuit Breaker]<br/>[Retry: 3회]<br/>[Bulkhead]"]
|
|
end
|
|
|
|
%% Kafka (Event Bus + Job Queue)
|
|
Kafka["Kafka<br/>━━━━━━━━━━<br/><Event Topics><br/>• EventCreated<br/>• ParticipantRegistered<br/>• DistributionCompleted<br/>━━━━━━━━━━<br/><Job Topics><br/>• ai 이벤트 생성"]
|
|
|
|
%% External System
|
|
External["외부시스템<br/>[Circuit Breaker]<br/>━━━━━━━━━━<br/>• AI API<br/>• 이미지 생성 API<br/>• 배포 채널 APIs<br/>(비동기)"]
|
|
|
|
%% Redis
|
|
Redis["Redis Cache<br/>━━━━━━━━━━<br/>• AI 결과<br/>• 이미지 URL<br/>• 이벤트 데이터"]
|
|
|
|
%% Event Publishing
|
|
EventSvc ==>|"EventCreated<br/>발행"| Kafka
|
|
PartSvc ==>|"ParticipantRegistered<br/>발행"| Kafka
|
|
DistSvc ==>|"DistributionCompleted<br/>발행"| Kafka
|
|
|
|
%% Job Publishing (비동기 작업 요청)
|
|
EventSvc -->|"ai 이벤트 생성 발행"| Kafka
|
|
|
|
%% Event Subscription
|
|
Kafka -.->|"EventCreated<br/>구독"| AnalSvc
|
|
Kafka -.->|"ParticipantRegistered<br/>구독"| AnalSvc
|
|
Kafka -.->|"DistributionCompleted<br/>구독"| AnalSvc
|
|
|
|
%% Job Subscription
|
|
Kafka -.->|"ai 이벤트 생성 구독"| AISvc
|
|
|
|
%% Service to Service (동기 호출)
|
|
EventSvc -->|"다중 채널 배포<br/>[Circuit Breaker]"| DistSvc
|
|
EventSvc -->|"회원정보 조회"| UserSvc
|
|
|
|
%% Redis Interactions
|
|
AISvc -->|"AI 결과 저장"| Redis
|
|
ContentSvc -->|"AI 데이터 읽기"| Redis
|
|
ContentSvc -->|"이미지 URL 저장"| Redis
|
|
EventSvc -->|"Redis → DB 저장"| Redis
|
|
|
|
%% Services to External (Resilience 패턴)
|
|
AISvc -->|"트렌드 분석/추천"| External
|
|
ContentSvc -->|"이미지 생성"| External
|
|
DistSvc -->|"다중 채널 배포<br/>(비동기)"| External
|
|
AnalSvc -->|"채널별 통계<br/>[Fallback: Cache]"| External
|
|
|
|
%% Styling
|
|
classDef service fill:#4ECDC4,stroke:#14B8A6,stroke-width:3px
|
|
classDef async fill:#8B5CF6,stroke:#7C3AED,stroke-width:3px,color:#fff
|
|
classDef kafka fill:#F59E0B,stroke:#D97706,stroke-width:3px
|
|
classDef external fill:#E5E7EB,stroke:#9CA3AF,stroke-width:2px
|
|
classDef cache fill:#EF4444,stroke:#DC2626,stroke-width:3px
|
|
|
|
class UserSvc,EventSvc,PartSvc,AnalSvc service
|
|
class AISvc,ContentSvc,DistSvc async
|
|
class Kafka kafka
|
|
class External external
|
|
class Redis cache
|