tech-hub-skills 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +250 -0
- package/bin/cli.js +241 -0
- package/bin/copilot.js +182 -0
- package/bin/postinstall.js +42 -0
- package/package.json +46 -0
- package/tech_hub_skills/roles/ai-engineer/skills/01-prompt-engineering/README.md +252 -0
- package/tech_hub_skills/roles/ai-engineer/skills/02-rag-pipeline/README.md +448 -0
- package/tech_hub_skills/roles/ai-engineer/skills/03-agent-orchestration/README.md +599 -0
- package/tech_hub_skills/roles/ai-engineer/skills/04-llm-guardrails/README.md +735 -0
- package/tech_hub_skills/roles/ai-engineer/skills/05-vector-embeddings/README.md +711 -0
- package/tech_hub_skills/roles/ai-engineer/skills/06-llm-evaluation/README.md +777 -0
- package/tech_hub_skills/roles/azure/skills/01-infrastructure-fundamentals/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/02-data-factory/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/03-synapse-analytics/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/04-databricks/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/05-functions/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/06-kubernetes-service/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/07-openai-service/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/08-machine-learning/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/09-storage-adls/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/10-networking/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/11-sql-cosmos/README.md +264 -0
- package/tech_hub_skills/roles/azure/skills/12-event-hubs/README.md +264 -0
- package/tech_hub_skills/roles/code-review/skills/01-automated-code-review/README.md +394 -0
- package/tech_hub_skills/roles/code-review/skills/02-pr-review-workflow/README.md +427 -0
- package/tech_hub_skills/roles/code-review/skills/03-code-quality-gates/README.md +518 -0
- package/tech_hub_skills/roles/code-review/skills/04-reviewer-assignment/README.md +504 -0
- package/tech_hub_skills/roles/code-review/skills/05-review-analytics/README.md +540 -0
- package/tech_hub_skills/roles/data-engineer/skills/01-lakehouse-architecture/README.md +550 -0
- package/tech_hub_skills/roles/data-engineer/skills/02-etl-pipeline/README.md +580 -0
- package/tech_hub_skills/roles/data-engineer/skills/03-data-quality/README.md +579 -0
- package/tech_hub_skills/roles/data-engineer/skills/04-streaming-pipelines/README.md +608 -0
- package/tech_hub_skills/roles/data-engineer/skills/05-performance-optimization/README.md +547 -0
- package/tech_hub_skills/roles/data-governance/skills/01-data-catalog/README.md +112 -0
- package/tech_hub_skills/roles/data-governance/skills/02-data-lineage/README.md +129 -0
- package/tech_hub_skills/roles/data-governance/skills/03-data-quality-framework/README.md +182 -0
- package/tech_hub_skills/roles/data-governance/skills/04-access-control/README.md +39 -0
- package/tech_hub_skills/roles/data-governance/skills/05-master-data-management/README.md +40 -0
- package/tech_hub_skills/roles/data-governance/skills/06-compliance-privacy/README.md +46 -0
- package/tech_hub_skills/roles/data-scientist/skills/01-eda-automation/README.md +230 -0
- package/tech_hub_skills/roles/data-scientist/skills/02-statistical-modeling/README.md +264 -0
- package/tech_hub_skills/roles/data-scientist/skills/03-feature-engineering/README.md +264 -0
- package/tech_hub_skills/roles/data-scientist/skills/04-predictive-modeling/README.md +264 -0
- package/tech_hub_skills/roles/data-scientist/skills/05-customer-analytics/README.md +264 -0
- package/tech_hub_skills/roles/data-scientist/skills/06-campaign-analysis/README.md +264 -0
- package/tech_hub_skills/roles/data-scientist/skills/07-experimentation/README.md +264 -0
- package/tech_hub_skills/roles/data-scientist/skills/08-data-visualization/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/01-cicd-pipeline/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/02-container-orchestration/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/03-infrastructure-as-code/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/04-gitops/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/05-environment-management/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/06-automated-testing/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/07-release-management/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/08-monitoring-alerting/README.md +264 -0
- package/tech_hub_skills/roles/devops/skills/09-devsecops/README.md +265 -0
- package/tech_hub_skills/roles/finops/skills/01-cost-visibility/README.md +264 -0
- package/tech_hub_skills/roles/finops/skills/02-resource-tagging/README.md +264 -0
- package/tech_hub_skills/roles/finops/skills/03-budget-management/README.md +264 -0
- package/tech_hub_skills/roles/finops/skills/04-reserved-instances/README.md +264 -0
- package/tech_hub_skills/roles/finops/skills/05-spot-optimization/README.md +264 -0
- package/tech_hub_skills/roles/finops/skills/06-storage-tiering/README.md +264 -0
- package/tech_hub_skills/roles/finops/skills/07-compute-rightsizing/README.md +264 -0
- package/tech_hub_skills/roles/finops/skills/08-chargeback/README.md +264 -0
- package/tech_hub_skills/roles/ml-engineer/skills/01-mlops-pipeline/README.md +566 -0
- package/tech_hub_skills/roles/ml-engineer/skills/02-feature-engineering/README.md +655 -0
- package/tech_hub_skills/roles/ml-engineer/skills/03-model-training/README.md +704 -0
- package/tech_hub_skills/roles/ml-engineer/skills/04-model-serving/README.md +845 -0
- package/tech_hub_skills/roles/ml-engineer/skills/05-model-monitoring/README.md +874 -0
- package/tech_hub_skills/roles/mlops/skills/01-ml-pipeline-orchestration/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/02-experiment-tracking/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/03-model-registry/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/04-feature-store/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/05-model-deployment/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/06-model-observability/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/07-data-versioning/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/08-ab-testing/README.md +264 -0
- package/tech_hub_skills/roles/mlops/skills/09-automated-retraining/README.md +264 -0
- package/tech_hub_skills/roles/platform-engineer/skills/01-internal-developer-platform/README.md +153 -0
- package/tech_hub_skills/roles/platform-engineer/skills/02-self-service-infrastructure/README.md +57 -0
- package/tech_hub_skills/roles/platform-engineer/skills/03-slo-sli-management/README.md +59 -0
- package/tech_hub_skills/roles/platform-engineer/skills/04-developer-experience/README.md +57 -0
- package/tech_hub_skills/roles/platform-engineer/skills/05-incident-management/README.md +73 -0
- package/tech_hub_skills/roles/platform-engineer/skills/06-capacity-management/README.md +59 -0
- package/tech_hub_skills/roles/product-designer/skills/01-requirements-discovery/README.md +407 -0
- package/tech_hub_skills/roles/product-designer/skills/02-user-research/README.md +382 -0
- package/tech_hub_skills/roles/product-designer/skills/03-brainstorming-ideation/README.md +437 -0
- package/tech_hub_skills/roles/product-designer/skills/04-ux-design/README.md +496 -0
- package/tech_hub_skills/roles/product-designer/skills/05-product-market-fit/README.md +376 -0
- package/tech_hub_skills/roles/product-designer/skills/06-stakeholder-management/README.md +412 -0
- package/tech_hub_skills/roles/security-architect/skills/01-pii-detection/README.md +319 -0
- package/tech_hub_skills/roles/security-architect/skills/02-threat-modeling/README.md +264 -0
- package/tech_hub_skills/roles/security-architect/skills/03-infrastructure-security/README.md +264 -0
- package/tech_hub_skills/roles/security-architect/skills/04-iam/README.md +264 -0
- package/tech_hub_skills/roles/security-architect/skills/05-application-security/README.md +264 -0
- package/tech_hub_skills/roles/security-architect/skills/06-secrets-management/README.md +264 -0
- package/tech_hub_skills/roles/security-architect/skills/07-security-monitoring/README.md +264 -0
- package/tech_hub_skills/roles/system-design/skills/01-architecture-patterns/README.md +337 -0
- package/tech_hub_skills/roles/system-design/skills/02-requirements-engineering/README.md +264 -0
- package/tech_hub_skills/roles/system-design/skills/03-scalability/README.md +264 -0
- package/tech_hub_skills/roles/system-design/skills/04-high-availability/README.md +264 -0
- package/tech_hub_skills/roles/system-design/skills/05-cost-optimization-design/README.md +264 -0
- package/tech_hub_skills/roles/system-design/skills/06-api-design/README.md +264 -0
- package/tech_hub_skills/roles/system-design/skills/07-observability-architecture/README.md +264 -0
- package/tech_hub_skills/roles/system-design/skills/08-process-automation/PROCESS_TEMPLATE.md +336 -0
- package/tech_hub_skills/roles/system-design/skills/08-process-automation/README.md +521 -0
- package/tech_hub_skills/skills/README.md +336 -0
- package/tech_hub_skills/skills/ai-engineer.md +104 -0
- package/tech_hub_skills/skills/azure.md +149 -0
- package/tech_hub_skills/skills/code-review.md +399 -0
- package/tech_hub_skills/skills/compliance-automation.md +747 -0
- package/tech_hub_skills/skills/data-engineer.md +113 -0
- package/tech_hub_skills/skills/data-governance.md +102 -0
- package/tech_hub_skills/skills/data-scientist.md +123 -0
- package/tech_hub_skills/skills/devops.md +160 -0
- package/tech_hub_skills/skills/docker.md +160 -0
- package/tech_hub_skills/skills/enterprise-dashboard.md +613 -0
- package/tech_hub_skills/skills/finops.md +184 -0
- package/tech_hub_skills/skills/ml-engineer.md +115 -0
- package/tech_hub_skills/skills/mlops.md +187 -0
- package/tech_hub_skills/skills/optimization-advisor.md +329 -0
- package/tech_hub_skills/skills/orchestrator.md +497 -0
- package/tech_hub_skills/skills/platform-engineer.md +102 -0
- package/tech_hub_skills/skills/process-automation.md +226 -0
- package/tech_hub_skills/skills/process-changelog.md +184 -0
- package/tech_hub_skills/skills/process-documentation.md +484 -0
- package/tech_hub_skills/skills/process-kanban.md +324 -0
- package/tech_hub_skills/skills/process-versioning.md +214 -0
- package/tech_hub_skills/skills/product-designer.md +104 -0
- package/tech_hub_skills/skills/project-starter.md +443 -0
- package/tech_hub_skills/skills/security-architect.md +135 -0
- package/tech_hub_skills/skills/system-design.md +126 -0
|
@@ -0,0 +1,264 @@
|
|
|
1
|
+
# Skill 07: Security Monitoring & Incident Response
|
|
2
|
+
|
|
3
|
+
## 🎯 Overview
|
|
4
|
+
Azure Sentinel integration, anomaly detection, incident playbooks
|
|
5
|
+
|
|
6
|
+
## 🔗 Connections
|
|
7
|
+
- **Data Engineer**: Data foundation and pipelines (de-01, de-02, de-03)
|
|
8
|
+
- **Security Architect**: Compliance, PII detection, access control (sa-01, sa-02)
|
|
9
|
+
- **ML Engineer**: Model lifecycle and serving (ml-01, ml-04)
|
|
10
|
+
- **AI Engineer**: LLM integration and automation (ai-01, ai-02, ai-07)
|
|
11
|
+
- **MLOps**: Experiment tracking and monitoring (mo-01, mo-03, mo-06)
|
|
12
|
+
- **FinOps**: Cost optimization and tracking (fo-01, fo-07)
|
|
13
|
+
- **DevOps**: CI/CD, containerization, monitoring (do-01, do-03, do-08)
|
|
14
|
+
- **System Design**: Architecture patterns (sd-01)
|
|
15
|
+
- **Dependencies**: sa-02
|
|
16
|
+
|
|
17
|
+
## 🛠️ Tools Included
|
|
18
|
+
|
|
19
|
+
### 1. Primary Implementation Script
|
|
20
|
+
Core implementation for security monitoring & incident response.
|
|
21
|
+
|
|
22
|
+
### 2. Configuration Manager
|
|
23
|
+
Manage configuration and settings for security monitoring & incident response.
|
|
24
|
+
|
|
25
|
+
### 3. Integration Connector
|
|
26
|
+
Connect with other Tech Hub skills and external services.
|
|
27
|
+
|
|
28
|
+
### 4. Monitoring & Metrics
|
|
29
|
+
Track performance, costs, and quality metrics.
|
|
30
|
+
|
|
31
|
+
### 5. Automation Scripts
|
|
32
|
+
Automate common workflows and tasks.
|
|
33
|
+
|
|
34
|
+
## 📊 Key Metrics
|
|
35
|
+
- Implementation quality score
|
|
36
|
+
- Performance benchmarks
|
|
37
|
+
- Cost efficiency
|
|
38
|
+
- Security compliance rate
|
|
39
|
+
- Integration test coverage
|
|
40
|
+
|
|
41
|
+
## 🚀 Quick Start
|
|
42
|
+
|
|
43
|
+
```python
|
|
44
|
+
# Example implementation for Security Monitoring & Incident Response
|
|
45
|
+
from security_architect import 07_security_monitoring
|
|
46
|
+
|
|
47
|
+
# Initialize
|
|
48
|
+
service = 07SecurityMonitoringService()
|
|
49
|
+
|
|
50
|
+
# Execute
|
|
51
|
+
result = service.execute(
|
|
52
|
+
config={
|
|
53
|
+
"environment": "production",
|
|
54
|
+
"enable_monitoring": True
|
|
55
|
+
}
|
|
56
|
+
)
|
|
57
|
+
|
|
58
|
+
print(f"Status: {result.status}")
|
|
59
|
+
print(f"Metrics: {result.metrics}")
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## 📚 Best Practices
|
|
63
|
+
|
|
64
|
+
### Cost Optimization (FinOps Integration)
|
|
65
|
+
|
|
66
|
+
1. **Monitor Resource Costs**
|
|
67
|
+
- Track costs per execution
|
|
68
|
+
- Set budget alerts
|
|
69
|
+
- Optimize resource utilization
|
|
70
|
+
- Reference: FinOps fo-01 (Cost Monitoring)
|
|
71
|
+
|
|
72
|
+
2. **Right-size Resources**
|
|
73
|
+
- Use appropriate compute sizes
|
|
74
|
+
- Implement auto-scaling
|
|
75
|
+
- Leverage spot/reserved instances where applicable
|
|
76
|
+
- Reference: FinOps fo-06, fo-07
|
|
77
|
+
|
|
78
|
+
### Security & Privacy (Security Architect Integration)
|
|
79
|
+
|
|
80
|
+
3. **Implement Access Control**
|
|
81
|
+
- Use least privilege principle
|
|
82
|
+
- Enable Azure AD authentication
|
|
83
|
+
- Audit access logs
|
|
84
|
+
- Reference: Security Architect sa-02 (IAM), sa-04
|
|
85
|
+
|
|
86
|
+
4. **Data Protection**
|
|
87
|
+
- Encrypt data at rest and in transit
|
|
88
|
+
- Scan for PII before processing
|
|
89
|
+
- Implement data retention policies
|
|
90
|
+
- Reference: Security Architect sa-01 (PII Detection)
|
|
91
|
+
|
|
92
|
+
### Quality & Governance (Data Engineer Integration)
|
|
93
|
+
|
|
94
|
+
5. **Ensure Data Quality**
|
|
95
|
+
- Validate inputs and outputs
|
|
96
|
+
- Implement quality gates
|
|
97
|
+
- Monitor data freshness
|
|
98
|
+
- Reference: Data Engineer de-03 (Data Quality)
|
|
99
|
+
|
|
100
|
+
### Lifecycle Management (MLOps Integration)
|
|
101
|
+
|
|
102
|
+
6. **Version Control**
|
|
103
|
+
- Version all configurations
|
|
104
|
+
- Track changes over time
|
|
105
|
+
- Enable rollback capability
|
|
106
|
+
- Reference: MLOps mo-03 (Versioning)
|
|
107
|
+
|
|
108
|
+
7. **Continuous Monitoring**
|
|
109
|
+
- Track performance metrics
|
|
110
|
+
- Set up alerting
|
|
111
|
+
- Monitor for drift
|
|
112
|
+
- Reference: MLOps mo-06 (Monitoring)
|
|
113
|
+
|
|
114
|
+
### Deployment & Operations (DevOps Integration)
|
|
115
|
+
|
|
116
|
+
8. **Automate Deployment**
|
|
117
|
+
- Implement CI/CD pipelines
|
|
118
|
+
- Use infrastructure as code
|
|
119
|
+
- Enable blue-green deployments
|
|
120
|
+
- Reference: DevOps do-01 (CI/CD), do-03 (IaC)
|
|
121
|
+
|
|
122
|
+
9. **Observability**
|
|
123
|
+
- Implement distributed tracing
|
|
124
|
+
- Set up dashboards
|
|
125
|
+
- Enable logging and metrics
|
|
126
|
+
- Reference: DevOps do-08 (Monitoring)
|
|
127
|
+
|
|
128
|
+
### Azure-Specific Best Practices
|
|
129
|
+
|
|
130
|
+
10. **Leverage Azure Services**
|
|
131
|
+
- Use managed services where possible
|
|
132
|
+
- Implement Azure Policy for governance
|
|
133
|
+
- Enable Azure Monitor integration
|
|
134
|
+
- Use managed identities for authentication
|
|
135
|
+
|
|
136
|
+
## 💰 Cost Optimization Examples
|
|
137
|
+
|
|
138
|
+
### Cost Tracking
|
|
139
|
+
```python
|
|
140
|
+
from finops_tracker import CostTracker
|
|
141
|
+
|
|
142
|
+
tracker = CostTracker()
|
|
143
|
+
|
|
144
|
+
@tracker.track_costs
|
|
145
|
+
def run_operation(params):
|
|
146
|
+
# Your operation here
|
|
147
|
+
result = execute_operation(params)
|
|
148
|
+
return result
|
|
149
|
+
|
|
150
|
+
# Monthly report
|
|
151
|
+
report = tracker.monthly_report()
|
|
152
|
+
print(f"Total cost: ${report.total_cost:.2f}")
|
|
153
|
+
print(f"Cost per operation: ${report.avg_cost:.4f}")
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
## 🔒 Security Best Practices Examples
|
|
157
|
+
|
|
158
|
+
### Access Control Implementation
|
|
159
|
+
```python
|
|
160
|
+
from azure.identity import DefaultAzureCredential
|
|
161
|
+
from security_manager import AccessControl
|
|
162
|
+
|
|
163
|
+
credential = DefaultAzureCredential()
|
|
164
|
+
access_control = AccessControl(credential)
|
|
165
|
+
|
|
166
|
+
# Validate access before operation
|
|
167
|
+
@access_control.require_role("operator")
|
|
168
|
+
def sensitive_operation(data):
|
|
169
|
+
# Operation logic
|
|
170
|
+
return process_data(data)
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
## 📊 Enhanced Metrics & Monitoring
|
|
174
|
+
|
|
175
|
+
| Metric Category | Metric | Target | Tool |
|
|
176
|
+
|-----------------|--------|--------|------|
|
|
177
|
+
| **Performance** | Execution time (p95) | <5s | Azure Monitor |
|
|
178
|
+
| | Success rate | >99% | Custom metrics |
|
|
179
|
+
| **Cost** | Cost per operation | <$0.05 | FinOps dashboard |
|
|
180
|
+
| | Resource utilization | >75% | Azure Monitor |
|
|
181
|
+
| **Quality** | Error rate | <1% | App Insights |
|
|
182
|
+
| | Data quality score | >95% | Quality tracker |
|
|
183
|
+
| **Security** | Access violations | 0 | Security logs |
|
|
184
|
+
| | Compliance score | 100% | Audit system |
|
|
185
|
+
|
|
186
|
+
## 🚀 Deployment Pipeline
|
|
187
|
+
|
|
188
|
+
### CI/CD Example
|
|
189
|
+
```yaml
|
|
190
|
+
# .github/workflows/deploy-07-security-monitoring.yml
|
|
191
|
+
name: Deploy Security Monitoring & Incident Response
|
|
192
|
+
|
|
193
|
+
on:
|
|
194
|
+
push:
|
|
195
|
+
paths:
|
|
196
|
+
- 'security-architect/skills/07-security-monitoring/**'
|
|
197
|
+
branches:
|
|
198
|
+
- main
|
|
199
|
+
|
|
200
|
+
jobs:
|
|
201
|
+
test:
|
|
202
|
+
runs-on: ubuntu-latest
|
|
203
|
+
steps:
|
|
204
|
+
- uses: actions/checkout@v3
|
|
205
|
+
- name: Run tests
|
|
206
|
+
run: pytest tests/ -v
|
|
207
|
+
- name: Security scan
|
|
208
|
+
run: python scripts/security_scan.py
|
|
209
|
+
- name: Cost validation
|
|
210
|
+
run: python scripts/validate_costs.py
|
|
211
|
+
|
|
212
|
+
deploy:
|
|
213
|
+
needs: test
|
|
214
|
+
runs-on: ubuntu-latest
|
|
215
|
+
steps:
|
|
216
|
+
- name: Deploy to Azure
|
|
217
|
+
run: |
|
|
218
|
+
az deployment group create \
|
|
219
|
+
--resource-group rg-security-architect \
|
|
220
|
+
--template-file infra/main.bicep
|
|
221
|
+
- name: Monitor deployment
|
|
222
|
+
run: python scripts/monitor_health.py --duration 10m
|
|
223
|
+
```
|
|
224
|
+
|
|
225
|
+
## 🔄 Integration Workflow
|
|
226
|
+
|
|
227
|
+
### End-to-End Process
|
|
228
|
+
```
|
|
229
|
+
1. Input Validation
|
|
230
|
+
↓
|
|
231
|
+
2. Security Checks (sa-01, sa-02)
|
|
232
|
+
↓
|
|
233
|
+
3. Main Processing
|
|
234
|
+
↓
|
|
235
|
+
4. Quality Validation (de-03)
|
|
236
|
+
↓
|
|
237
|
+
5. Cost Tracking (fo-01)
|
|
238
|
+
↓
|
|
239
|
+
6. Monitoring & Logging (do-08)
|
|
240
|
+
↓
|
|
241
|
+
7. Output Delivery
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
## 🎯 Quick Wins
|
|
245
|
+
|
|
246
|
+
1. **Enable cost tracking** - Monitor spending from day one
|
|
247
|
+
2. **Implement security scanning** - Catch vulnerabilities early
|
|
248
|
+
3. **Set up monitoring** - Full visibility into operations
|
|
249
|
+
4. **Automate deployment** - Faster, safer releases
|
|
250
|
+
5. **Add quality gates** - Prevent bad data from propagating
|
|
251
|
+
6. **Enable caching** - Reduce redundant operations
|
|
252
|
+
7. **Implement retries** - Improve reliability
|
|
253
|
+
8. **Set up alerting** - Know about issues immediately
|
|
254
|
+
|
|
255
|
+
## 🔗 Related Skills
|
|
256
|
+
- sa-02
|
|
257
|
+
|
|
258
|
+
---
|
|
259
|
+
|
|
260
|
+
**Skill ID**: `07-security-monitoring`
|
|
261
|
+
**Complexity**: Advanced
|
|
262
|
+
**Dependencies**: sa-02
|
|
263
|
+
**Business Value**: High
|
|
264
|
+
**Estimated Implementation Time**: 2-3 days
|
|
@@ -0,0 +1,337 @@
|
|
|
1
|
+
# Skill 1: Architecture Pattern Selection & Design
|
|
2
|
+
|
|
3
|
+
## 🎯 Overview
|
|
4
|
+
Tools for selecting, documenting, and implementing architectural patterns with trade-off analysis.
|
|
5
|
+
|
|
6
|
+
## 🔗 Connections
|
|
7
|
+
- **All Roles**: Provides architectural guidance for implementations
|
|
8
|
+
- **Security Architect**: Security pattern integration (sa-02, sa-06, sa-08)
|
|
9
|
+
- **Data Engineer**: Data architecture patterns (de-01, de-02)
|
|
10
|
+
- **DevOps**: Infrastructure and deployment patterns (do-01, do-03, do-04)
|
|
11
|
+
- **ML Engineer**: ML system architecture (ml-01, ml-03)
|
|
12
|
+
- **AI Engineer**: AI application architecture (ai-02, ai-03)
|
|
13
|
+
- **FinOps**: Cost-optimized architecture design (fo-05, fo-06)
|
|
14
|
+
|
|
15
|
+
## 🛠️ Tools Included
|
|
16
|
+
|
|
17
|
+
### 1. `pattern_selector.py`
|
|
18
|
+
Decision framework for choosing architectural patterns.
|
|
19
|
+
|
|
20
|
+
### 2. `adr_generator.py`
|
|
21
|
+
Architecture Decision Record (ADR) automation.
|
|
22
|
+
|
|
23
|
+
### 3. `diagram_generator.py`
|
|
24
|
+
Mermaid diagram generation for C4 model and system architecture.
|
|
25
|
+
|
|
26
|
+
### 4. `tradeoff_analyzer.py`
|
|
27
|
+
CAP theorem and architectural trade-off analysis.
|
|
28
|
+
|
|
29
|
+
### 5. `architecture_templates.md`
|
|
30
|
+
Templates for common patterns (microservices, event-driven, layered, etc.).
|
|
31
|
+
|
|
32
|
+
## 📊 Supported Patterns
|
|
33
|
+
- Microservices
|
|
34
|
+
- Event-Driven Architecture (EDA)
|
|
35
|
+
- Layered Architecture
|
|
36
|
+
- CQRS & Event Sourcing
|
|
37
|
+
- Serverless
|
|
38
|
+
- Data Mesh
|
|
39
|
+
|
|
40
|
+
## 🚀 Quick Start
|
|
41
|
+
|
|
42
|
+
```python
|
|
43
|
+
from pattern_selector import ArchitectureSelector
|
|
44
|
+
from adr_generator import ADRGenerator
|
|
45
|
+
|
|
46
|
+
# Analyze requirements
|
|
47
|
+
selector = ArchitectureSelector()
|
|
48
|
+
recommendation = selector.recommend_pattern(
|
|
49
|
+
scalability="high",
|
|
50
|
+
consistency="eventual",
|
|
51
|
+
team_size="large",
|
|
52
|
+
deployment_frequency="daily"
|
|
53
|
+
)
|
|
54
|
+
|
|
55
|
+
# Generate ADR
|
|
56
|
+
adr = ADRGenerator()
|
|
57
|
+
adr.create_decision_record(
|
|
58
|
+
title="Adopt Microservices Architecture",
|
|
59
|
+
context="Need to scale teams and deployments independently",
|
|
60
|
+
decision="Implement microservices with event-driven communication",
|
|
61
|
+
consequences=["Increased operational complexity", "Better scalability"]
|
|
62
|
+
)
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
## 📚 Best Practices
|
|
66
|
+
|
|
67
|
+
### Cost-Optimized Architecture (FinOps Integration)
|
|
68
|
+
|
|
69
|
+
1. **Design for Cost Efficiency**
|
|
70
|
+
- Choose serverless vs containers based on usage patterns
|
|
71
|
+
- Implement auto-scaling with appropriate thresholds
|
|
72
|
+
- Use spot instances for fault-tolerant workloads
|
|
73
|
+
- Design for right-sizing from the start
|
|
74
|
+
- Reference: FinOps fo-05, fo-06
|
|
75
|
+
|
|
76
|
+
2. **Cost-Aware Pattern Selection**
|
|
77
|
+
- Evaluate TCO for each architecture pattern
|
|
78
|
+
- Consider operational costs, not just infrastructure
|
|
79
|
+
- Design for observability to enable optimization
|
|
80
|
+
- Track architectural decisions vs cost impact
|
|
81
|
+
- Reference: FinOps fo-01, System Design sd-05
|
|
82
|
+
|
|
83
|
+
### Security by Design (Security Architect Integration)
|
|
84
|
+
|
|
85
|
+
3. **Zero Trust Architecture**
|
|
86
|
+
- Assume breach mentality
|
|
87
|
+
- Implement least privilege access
|
|
88
|
+
- Encrypt all data in transit and at rest
|
|
89
|
+
- Continuous authentication and authorization
|
|
90
|
+
- Reference: Security Architect sa-02 (IAM), sa-04 (Encryption)
|
|
91
|
+
|
|
92
|
+
4. **Defense in Depth**
|
|
93
|
+
- Multiple layers of security controls
|
|
94
|
+
- Network segmentation and isolation
|
|
95
|
+
- API gateway with rate limiting
|
|
96
|
+
- WAF and DDoS protection
|
|
97
|
+
- Reference: Security Architect sa-03 (Network Security)
|
|
98
|
+
|
|
99
|
+
### DevOps-Enabled Architecture
|
|
100
|
+
|
|
101
|
+
5. **Infrastructure as Code**
|
|
102
|
+
- Design for automated provisioning
|
|
103
|
+
- Use immutable infrastructure patterns
|
|
104
|
+
- Implement blue-green deployments
|
|
105
|
+
- Enable infrastructure versioning
|
|
106
|
+
- Reference: DevOps do-04 (IaC), do-05 (GitOps)
|
|
107
|
+
|
|
108
|
+
6. **Observable by Design**
|
|
109
|
+
- Built-in logging, metrics, and tracing
|
|
110
|
+
- Distributed tracing for microservices
|
|
111
|
+
- Health checks and readiness probes
|
|
112
|
+
- Structured logging standards
|
|
113
|
+
- Reference: DevOps do-08 (Monitoring & Observability)
|
|
114
|
+
|
|
115
|
+
### Data Architecture Patterns
|
|
116
|
+
|
|
117
|
+
7. **Scalable Data Architecture**
|
|
118
|
+
- Implement data mesh for large organizations
|
|
119
|
+
- Use CQRS for read-heavy workloads
|
|
120
|
+
- Design for eventual consistency
|
|
121
|
+
- Partition strategies for scale
|
|
122
|
+
- Reference: Data Engineer de-01, de-02
|
|
123
|
+
|
|
124
|
+
8. **Data Governance Integration**
|
|
125
|
+
- Data catalog and lineage tracking
|
|
126
|
+
- Policy enforcement at architecture level
|
|
127
|
+
- Data quality gates
|
|
128
|
+
- Compliance by design
|
|
129
|
+
- Reference: Security Architect sa-06 (Data Governance)
|
|
130
|
+
|
|
131
|
+
### ML/AI Architecture Patterns
|
|
132
|
+
|
|
133
|
+
9. **ML System Architecture**
|
|
134
|
+
- Separate training and serving infrastructure
|
|
135
|
+
- Model registry and versioning
|
|
136
|
+
- Feature store architecture
|
|
137
|
+
- A/B testing infrastructure
|
|
138
|
+
- Reference: ML Engineer ml-01, ml-02
|
|
139
|
+
|
|
140
|
+
10. **AI Application Architecture**
|
|
141
|
+
- LLM gateway pattern for cost control
|
|
142
|
+
- RAG architecture for knowledge systems
|
|
143
|
+
- Agent orchestration patterns
|
|
144
|
+
- Prompt template management
|
|
145
|
+
- Reference: AI Engineer ai-01, ai-02, ai-03
|
|
146
|
+
|
|
147
|
+
## 🏗️ Architecture Decision Records (ADRs)
|
|
148
|
+
|
|
149
|
+
### Cost-Optimized Microservices
|
|
150
|
+
```markdown
|
|
151
|
+
# ADR-001: Adopt Serverless-First for Microservices
|
|
152
|
+
|
|
153
|
+
## Status
|
|
154
|
+
Accepted
|
|
155
|
+
|
|
156
|
+
## Context
|
|
157
|
+
Need to build scalable microservices with minimal operational overhead and cost-efficient scaling.
|
|
158
|
+
|
|
159
|
+
## Decision
|
|
160
|
+
Use Azure Functions (serverless) for event-driven services with variable load.
|
|
161
|
+
Use Azure Container Apps for always-on services requiring more control.
|
|
162
|
+
|
|
163
|
+
## Consequences
|
|
164
|
+
**Positive:**
|
|
165
|
+
- Auto-scaling with pay-per-execution model (70% cost savings on variable workloads)
|
|
166
|
+
- Reduced operational complexity
|
|
167
|
+
- Built-in monitoring and logging
|
|
168
|
+
|
|
169
|
+
**Negative:**
|
|
170
|
+
- Cold start latency for infrequent functions
|
|
171
|
+
- Vendor lock-in to Azure ecosystem
|
|
172
|
+
- Limited customization vs Kubernetes
|
|
173
|
+
|
|
174
|
+
## Cost Impact
|
|
175
|
+
- Estimated 60-70% reduction in compute costs for variable workloads
|
|
176
|
+
- Operational cost savings: ~40% reduction in DevOps overhead
|
|
177
|
+
|
|
178
|
+
## References
|
|
179
|
+
- FinOps fo-06 (Compute Optimization)
|
|
180
|
+
- DevOps do-03 (Containerization)
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
### Security Architecture
|
|
184
|
+
```markdown
|
|
185
|
+
# ADR-002: Implement Zero Trust Network Architecture
|
|
186
|
+
|
|
187
|
+
## Status
|
|
188
|
+
Accepted
|
|
189
|
+
|
|
190
|
+
## Context
|
|
191
|
+
Legacy network perimeter security insufficient for cloud-native applications.
|
|
192
|
+
|
|
193
|
+
## Decision
|
|
194
|
+
Implement zero trust architecture with:
|
|
195
|
+
- Mutual TLS for all service-to-service communication
|
|
196
|
+
- Identity-based access control (not network-based)
|
|
197
|
+
- Continuous verification and least privilege access
|
|
198
|
+
- Azure Managed Identity for all service authentication
|
|
199
|
+
|
|
200
|
+
## Consequences
|
|
201
|
+
**Positive:**
|
|
202
|
+
- Stronger security posture
|
|
203
|
+
- Better compliance with SOC 2, ISO 27001
|
|
204
|
+
- Reduced attack surface
|
|
205
|
+
|
|
206
|
+
**Negative:**
|
|
207
|
+
- Increased complexity in initial setup
|
|
208
|
+
- More stringent certificate management
|
|
209
|
+
- Potential latency from additional auth checks
|
|
210
|
+
|
|
211
|
+
## Implementation
|
|
212
|
+
- Use Azure API Management as central gateway
|
|
213
|
+
- Implement Azure AD for identity management
|
|
214
|
+
- Enable Azure Key Vault for secrets management
|
|
215
|
+
|
|
216
|
+
## References
|
|
217
|
+
- Security Architect sa-02 (IAM)
|
|
218
|
+
- Security Architect sa-04 (Encryption)
|
|
219
|
+
- DevOps do-07 (Secrets Management)
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
## 🔄 Architecture Pattern Library
|
|
223
|
+
|
|
224
|
+
### Pattern: Event-Driven Microservices
|
|
225
|
+
```python
|
|
226
|
+
"""
|
|
227
|
+
Enterprise-grade event-driven architecture with Azure Event Grid
|
|
228
|
+
"""
|
|
229
|
+
from azure.eventgrid import EventGridPublisherClient
|
|
230
|
+
from azure.identity import DefaultAzureCredential
|
|
231
|
+
|
|
232
|
+
class EventDrivenArchitecture:
|
|
233
|
+
def __init__(self, topic_endpoint: str):
|
|
234
|
+
self.client = EventGridPublisherClient(
|
|
235
|
+
topic_endpoint,
|
|
236
|
+
DefaultAzureCredential()
|
|
237
|
+
)
|
|
238
|
+
|
|
239
|
+
def publish_event(self, event_type: str, data: dict):
|
|
240
|
+
event = {
|
|
241
|
+
"eventType": event_type,
|
|
242
|
+
"subject": f"/{event_type}",
|
|
243
|
+
"dataVersion": "1.0",
|
|
244
|
+
"data": data
|
|
245
|
+
}
|
|
246
|
+
self.client.send(event)
|
|
247
|
+
|
|
248
|
+
# Usage with cost tracking
|
|
249
|
+
from finops_tracker import EventCostTracker
|
|
250
|
+
|
|
251
|
+
cost_tracker = EventCostTracker()
|
|
252
|
+
|
|
253
|
+
@cost_tracker.track_event_cost
|
|
254
|
+
def process_order(order_id: str):
|
|
255
|
+
architecture = EventDrivenArchitecture(topic_endpoint)
|
|
256
|
+
architecture.publish_event(
|
|
257
|
+
"order.created",
|
|
258
|
+
{"order_id": order_id, "status": "pending"}
|
|
259
|
+
)
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
### Pattern: CQRS with Event Sourcing
|
|
263
|
+
```python
|
|
264
|
+
"""
|
|
265
|
+
Command Query Responsibility Segregation for scalable reads
|
|
266
|
+
"""
|
|
267
|
+
class CQRSArchitecture:
|
|
268
|
+
def __init__(self):
|
|
269
|
+
self.write_db = CosmosDBClient() # Strong consistency
|
|
270
|
+
self.read_db = AzureSearchClient() # Optimized for queries
|
|
271
|
+
self.event_store = EventGridClient()
|
|
272
|
+
|
|
273
|
+
def execute_command(self, command: Command):
|
|
274
|
+
# Write to command store
|
|
275
|
+
result = self.write_db.execute(command)
|
|
276
|
+
|
|
277
|
+
# Publish event for read model update
|
|
278
|
+
self.event_store.publish({
|
|
279
|
+
"type": "command.executed",
|
|
280
|
+
"aggregate_id": command.aggregate_id,
|
|
281
|
+
"data": result
|
|
282
|
+
})
|
|
283
|
+
|
|
284
|
+
return result
|
|
285
|
+
|
|
286
|
+
def execute_query(self, query: Query):
|
|
287
|
+
# Read from optimized read model
|
|
288
|
+
return self.read_db.search(query)
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
## 📊 Architecture Metrics
|
|
292
|
+
|
|
293
|
+
| Metric | Target | Tool |
|
|
294
|
+
|--------|--------|------|
|
|
295
|
+
| **System Availability** | >99.9% | Azure Monitor |
|
|
296
|
+
| **Mean Time to Recovery (MTTR)** | <30 min | Incident tracking |
|
|
297
|
+
| **Deployment Frequency** | Daily | CI/CD metrics |
|
|
298
|
+
| **Lead Time for Changes** | <1 day | DevOps metrics |
|
|
299
|
+
| **Change Failure Rate** | <5% | Deployment tracking |
|
|
300
|
+
| **Architecture Cost Efficiency** | >60% savings vs baseline | FinOps dashboard |
|
|
301
|
+
| **Security Posture Score** | >90/100 | Security assessment |
|
|
302
|
+
|
|
303
|
+
## 🔄 Integration Patterns
|
|
304
|
+
|
|
305
|
+
### Cross-Role Architecture Workflow
|
|
306
|
+
```
|
|
307
|
+
1. Requirements Gathering (sd-02)
|
|
308
|
+
↓
|
|
309
|
+
2. Architecture Pattern Selection (sd-01)
|
|
310
|
+
↓
|
|
311
|
+
3. Security Architecture Review (sa-02, sa-06)
|
|
312
|
+
↓
|
|
313
|
+
4. Cost Impact Analysis (fo-05, fo-06)
|
|
314
|
+
↓
|
|
315
|
+
5. Infrastructure Design (do-04)
|
|
316
|
+
↓
|
|
317
|
+
6. Data Architecture (de-01, de-02)
|
|
318
|
+
↓
|
|
319
|
+
7. ML System Architecture (ml-01)
|
|
320
|
+
↓
|
|
321
|
+
8. API Design (sd-04)
|
|
322
|
+
↓
|
|
323
|
+
9. ADR Documentation (sd-01)
|
|
324
|
+
↓
|
|
325
|
+
10. Implementation & Deployment (do-01, do-03)
|
|
326
|
+
↓
|
|
327
|
+
11. Monitoring & Optimization (do-08, fo-01)
|
|
328
|
+
```
|
|
329
|
+
|
|
330
|
+
## 🎯 Quick Wins
|
|
331
|
+
|
|
332
|
+
1. **Document architecture decisions** - Enable informed evolution
|
|
333
|
+
2. **Implement ADRs** - Track rationale and consequences
|
|
334
|
+
3. **Design for observability** - Enable optimization
|
|
335
|
+
4. **Security by design** - Prevent costly retrofits
|
|
336
|
+
5. **Cost-aware architecture** - Optimize from day one
|
|
337
|
+
6. **Infrastructure as Code** - Enable automation and consistency
|