refactor(topics): 멀티 에이전트용 지식 재편 — _Common(공통 기본기) + Domain_* 구조
에이전트 8종(대화형/프로그래머 C·S/디자이너/설계자/기획자/QA/PD/PM)에게 [공통 기본 능력 + 롤별 Specialty] 2층으로 지식을 주입하기 위한 재분류. 문서 내용·포맷은 무수정, 폴더 이동만 (6,372개 문서 수 보존 확인). - Topic_Programming → Domain_Programming (내부 구조 보존) - Topic_Graphic → Domain_Design - Topic_Business → Domain_Product - Topic_General → Domain_General - _Common 신설: Math(구 Topic_Math_Specialty), Reasoning(구 General/From_Thinking & Reasoning), Reasoning_Creativity(구 General/From_창의성), Communication(Poetic_Blog_Writing + From_writing) - 타 도메인의 From_* 폴더는 유지 (출처 표기일 뿐, 이미 도메인에 맞게 분류된 문서) - 빈 폴더 정리 (memory/procedures) - 에이전트→폴더 매핑은 workspace의 .astra/agent-knowledge-map.json (9개 에이전트) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,194 @@
|
||||
---
|
||||
id: wiki-2026-0508-technical-architecture
|
||||
title: Technical Architecture
|
||||
category: 10_Wiki/Topics
|
||||
status: verified
|
||||
canonical_id: self
|
||||
aliases: [System Architecture, Tech Architecture, 기술 아키텍처]
|
||||
duplicate_of: none
|
||||
source_trust_level: A
|
||||
confidence_score: 0.9
|
||||
verification_status: applied
|
||||
tags: [architecture, system-design, structure]
|
||||
raw_sources: []
|
||||
last_reinforced: 2026-05-10
|
||||
github_commit: pending
|
||||
tech_stack:
|
||||
language: agnostic
|
||||
framework: C4/arc42
|
||||
---
|
||||
|
||||
# Technical Architecture
|
||||
|
||||
## 매 한 줄
|
||||
> **"매 system 의 high-level structure + 매 design decision 의 rationale"**. 매 component, 매 boundary, 매 data flow, 매 quality attribute (performance, security, scalability) 의 결정. 매 2026 modern stack 은 C4 model + ADR + arc42 의 combination 으로 documentation.
|
||||
|
||||
## 매 핵심
|
||||
|
||||
### 매 4+1 view (Kruchten 1995)
|
||||
- **Logical**: 매 functional decomposition (class, module).
|
||||
- **Process**: 매 runtime concurrency (thread, service).
|
||||
- **Development**: 매 source code organization (package, repo).
|
||||
- **Physical**: 매 deployment topology (node, network).
|
||||
- **Scenarios**: 매 use case 의 cross-cutting validation.
|
||||
|
||||
### 매 C4 model (Brown 2018)
|
||||
- **L1 Context**: 매 system + 매 external actors.
|
||||
- **L2 Container**: 매 deployable unit (web app, DB, queue).
|
||||
- **L3 Component**: 매 container 의 internal module.
|
||||
- **L4 Code**: 매 class diagram (rarely needed).
|
||||
|
||||
### 매 quality attributes (ISO 25010)
|
||||
- Performance · Scalability · Availability · Security · Maintainability · Testability · Observability.
|
||||
- 매 trade-off 의 명시 — 매 "all of them" 은 fantasy.
|
||||
|
||||
### 매 응용
|
||||
1. Greenfield project 시 C4 L1+L2 먼저, ADR 로 매 decision 기록.
|
||||
2. Legacy reverse engineering — 매 dependency graph 추출 후 component view.
|
||||
3. Architecture review — quality attribute scenario 의 validation.
|
||||
|
||||
## 💻 패턴
|
||||
|
||||
### C4 diagram (PlantUML)
|
||||
```plantuml
|
||||
@startuml
|
||||
!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Container.puml
|
||||
|
||||
Person(user, "Customer")
|
||||
System_Boundary(shop, "E-commerce") {
|
||||
Container(web, "Web App", "Next.js 15")
|
||||
Container(api, "API", "Node.js / Fastify")
|
||||
ContainerDb(db, "Database", "Postgres 16")
|
||||
Container(queue, "Queue", "Redis Streams")
|
||||
}
|
||||
System_Ext(stripe, "Stripe")
|
||||
|
||||
Rel(user, web, "Browses", "HTTPS")
|
||||
Rel(web, api, "API calls", "JSON/HTTPS")
|
||||
Rel(api, db, "Reads/Writes", "SQL")
|
||||
Rel(api, queue, "Publishes events")
|
||||
Rel(api, stripe, "Charges", "REST")
|
||||
@enduml
|
||||
```
|
||||
|
||||
### ADR template
|
||||
```markdown
|
||||
# ADR 0007: Choose Postgres over MongoDB
|
||||
|
||||
## Status: Accepted (2026-05-10)
|
||||
|
||||
## Context
|
||||
Need primary store for order data. Strong consistency required.
|
||||
Team has 5 years Postgres experience.
|
||||
|
||||
## Decision
|
||||
Postgres 16 with JSONB for flexible product attributes.
|
||||
|
||||
## Consequences
|
||||
+ ACID transactions for orders.
|
||||
+ Mature ecosystem (Prisma, pgvector for AI features).
|
||||
+ Single skill set for ops.
|
||||
- Less flexible schema evolution.
|
||||
- Manual sharding if scale > single node.
|
||||
|
||||
## Alternatives considered
|
||||
- MongoDB: rejected — eventual consistency unsuitable for orders.
|
||||
- DynamoDB: rejected — vendor lock-in, query flexibility.
|
||||
```
|
||||
|
||||
### Hexagonal architecture (ports & adapters)
|
||||
```typescript
|
||||
// Domain (port)
|
||||
interface OrderRepository {
|
||||
save(order: Order): Promise<void>;
|
||||
findById(id: string): Promise<Order | null>;
|
||||
}
|
||||
|
||||
// Application
|
||||
class PlaceOrderUseCase {
|
||||
constructor(private repo: OrderRepository, private payments: PaymentGateway) {}
|
||||
async execute(cmd: PlaceOrderCommand) {
|
||||
const order = Order.create(cmd);
|
||||
await this.payments.charge(order.total);
|
||||
await this.repo.save(order);
|
||||
}
|
||||
}
|
||||
|
||||
// Infrastructure (adapter)
|
||||
class PostgresOrderRepository implements OrderRepository {
|
||||
async save(order: Order) { /* SQL */ }
|
||||
async findById(id: string) { /* SQL */ }
|
||||
}
|
||||
```
|
||||
|
||||
### Layered architecture
|
||||
```
|
||||
┌─ Presentation (controllers, DTOs)
|
||||
├─ Application (use cases)
|
||||
├─ Domain (entities, value objects, services)
|
||||
└─ Infrastructure (DB, HTTP, queue adapters)
|
||||
```
|
||||
|
||||
### Event-driven boundary
|
||||
```typescript
|
||||
// Publisher (order service)
|
||||
await events.publish('OrderPlaced', {
|
||||
orderId: order.id,
|
||||
customerId: order.customerId,
|
||||
total: order.total.amount,
|
||||
ts: Date.now(),
|
||||
});
|
||||
|
||||
// Subscriber (notification service — independent deploy)
|
||||
events.subscribe('OrderPlaced', async (e) => {
|
||||
await emailClient.send(e.customerId, 'order-confirmation', e);
|
||||
});
|
||||
```
|
||||
|
||||
### Quality attribute scenario
|
||||
```yaml
|
||||
attribute: Performance
|
||||
source: 1000 concurrent users
|
||||
stimulus: place order
|
||||
artifact: API
|
||||
environment: peak load
|
||||
response: order accepted
|
||||
measure: p95 latency < 500ms, error rate < 0.1%
|
||||
```
|
||||
|
||||
## 매 결정 기준
|
||||
| 상황 | Approach |
|
||||
|---|---|
|
||||
| Small team, single domain | Layered monolith |
|
||||
| Multiple teams, bounded contexts | Microservices |
|
||||
| Heavy I/O, async workflow | Event-driven |
|
||||
| Domain-rich, complex rules | Hexagonal + DDD |
|
||||
| Read-heavy, eventual consistency OK | CQRS + event sourcing |
|
||||
|
||||
**기본값**: 매 modular monolith 부터 시작 — 매 microservice 의 premature split 의 regret.
|
||||
|
||||
## 🔗 Graph
|
||||
- 부모: [[Software_Architecture]] · [[System Design]]
|
||||
- 변형: [[Microservices]] · [[Hexagonal Architecture]] · [[Event-Driven Architecture]]
|
||||
- 응용: [[C4 Model (Architecture Documentation)]] · [[Architecture Decision Record]]
|
||||
- Adjacent: [[Domain-Driven Design]] · [[Testability_Architecture]] · [[Technical_Debt]]
|
||||
|
||||
## 🤖 LLM 활용
|
||||
**언제**: ADR drafting, C4 generation, quality attribute analysis, architecture review.
|
||||
**언제 X**: 매 production 의 actual capacity planning — 매 real load test 필요.
|
||||
|
||||
## ❌ 안티패턴
|
||||
- **Big design up front**: 매 waterfall 의 회귀.
|
||||
- **No documentation**: 매 6개월 후 nobody knows why.
|
||||
- **Microservices for 3 devs**: distributed monolith 의 distributed pain.
|
||||
- **Cargo cult architecture**: Netflix scale 의 mimicry without justification.
|
||||
|
||||
## 🧪 검증 / 중복
|
||||
- Verified (Kruchten 4+1 1995; Brown C4 2018; arc42 2024).
|
||||
- 신뢰도 A.
|
||||
|
||||
## 🕓 Changelog
|
||||
| 날짜 | 변경 |
|
||||
|---|---|
|
||||
| 2026-05-08 | Phase 1 |
|
||||
| 2026-05-10 | Manual cleanup — 4+1 + C4 + hexagonal patterns |
|
||||
Reference in New Issue
Block a user