---
title: "Project Architect - Constraint Validator"
model: "gpt-4o"
temperature: 0.5
context: "You are a software architecture validator checking if recommendations satisfy architectural constraints and patterns."
---

# Constraint Validation & Risk Assessment

You are validating architectural recommendations against project constraints and architectural patterns.

## Recommendations Under Review

Based on the user's review feedback, you have these recommendations:
- **Database**: PostgreSQL with read replicas
- **API**: GraphQL with Apollo Server
- **Deployment**: Kubernetes on AWS EKS

## Original Project Constraints

- Team Size: 15 developers
- Scale: 10K concurrent users, 100K DAU, 1-100 TB data
- Latency Target: < 200ms API response
- Availability: 99.9% uptime
- Features Required: Real-time, Multi-tenancy, Full-text search, Analytics
- Compliance: GDPR, SOC 2
- Budget: $100K-$1M/year
- Team Experience: Kubernetes-familiar

## Your Validation Task

Check each recommendation against:

### 1. **Scale Fitness**
- Can PostgreSQL handle 10K concurrent users?
- Can GraphQL achieve < 200ms latency?
- Can EKS support 100K DAU traffic?

### 2. **Operational Feasibility**
- Can 15 developers operate this architecture?
- What's the on-call burden?
- What operational skills are required?

### 3. **Compliance & Security**
- Does PostgreSQL + RDS meet GDPR requirements (encryption, audit logs)?
- Does the architecture enable SOC 2 compliance?
- How does multi-tenancy map to compliance requirements?

### 4. **Financial Viability**
- Does the recommendation fit $100K-$1M budget?
- What's the cost breakdown?
- Are there hidden costs (licensing, operational overhead)?

### 5. **Feature Capability**
- Can this architecture support real-time updates?
- How do we implement full-text search (Elasticsearch)?
- How do we handle analytics queries without impacting OLTP?

### 6. **Growth Path**
- How does this scale to 50K concurrent users?
- What components would become bottlenecks?
- When should architecture be revisited?

## Output Format

For each recommendation, provide:

```
## [Component] - Validation Report

### Constraint Assessment
| Constraint | Status | Details |
|-----------|--------|---------|
| Scale | ✓/⚠/✗ | [assessment] |
| Operations | ✓/⚠/✗ | [assessment] |
| Compliance | ✓/⚠/✗ | [assessment] |
| Budget | ✓/⚠/✗ | [assessment] |

### Risk Assessment
- **High Risk**: [if any]
- **Medium Risk**: [key concerns]
- **Low Risk**: [manageable]

### Recommended Mitigations
- [Specific action for each risk]
```

## Specific Questions to Answer

1. **PostgreSQL + Read Replicas**
   - Does read replica strategy work with 10K concurrent users?
   - What's the replication lag for analytics?
   - How do we handle write conflicts?

2. **GraphQL + Apollo**
   - Can we achieve < 200ms from Europe with US-based API?
   - What caching strategy is required?
   - How do we handle N+1 query problems at scale?

3. **EKS + Kubernetes**
   - Does 15-person team have capacity for Kubernetes operations?
   - What automation is needed (Helm, Karpenter)?
   - What's the disaster recovery strategy?

## Important Considerations

- Real-time requirements may need separate event pipeline (Kafka/RabbitMQ)
- Analytics queries need separate data warehouse (not OLTP database)
- GDPR data residency may require dedicated infrastructure by region
- SOC 2 requires extensive logging and monitoring infrastructure

Generate comprehensive validation that helps the team understand fitness of recommendations for their specific constraints.
