refactor(P57): contract surface redesign + rename + .yml repo-wide
Contract surface redesign: - New top-level fields: id (3-6 char acronym → stack.name), name (full → stack.title), infrastructure (map keyed by module name, replaces module:) - Drop uses: field (dead reference; version pin lives in CI workflow uses: line) - Drop top-level module/inputs (now nested under infrastructure map) - Per-module optional version (defaults to latest published from registry) - Multi-module contracts: one file deploys N modules in one pipeline run, resource IDs namespaced with module name to avoid collisions - stack.schema.json: add optional title field for display name Rename: - pipelines/deploy.yaml → pipelines/contract.yml (declarative spec, not a pipeline) - pipelines/ci.yaml → pipelines/ci.yml - All 44 .yaml files → .yml repo-wide (contracts, module examples, kyverno policies) - .acdl/contract.yaml → .acdl/contract.yml Resolver (core/contract_resolver.py): - Rewrite resolve() to loop infrastructure map, default version to latest, merge module fragments into one stack with namespaced resource IDs - _latest_version() picks highest non-deprecated from registry - _namespace_resources() prefixes IDs + rewrites ref: expressions for multi-module - Single-module path: unprefixed IDs (backward compatible) Verification: - 494 tests pass (0 contract-shape failures) - Local E2E passes (contract → resolver → adapter → local ECS HTTP 200 → outbox) ---ci--- project: acdl phase: 57 milestone: v1.10.2 status: execute ---/ci---
This commit is contained in:
@@ -1,38 +0,0 @@
|
||||
uses: acdl/pipelines/deploy.yaml@v1.8
|
||||
module: uptime
|
||||
environment: dev
|
||||
inputs:
|
||||
region: us-east-1
|
||||
feature_flag_enabled: true
|
||||
cpu: 512
|
||||
memory: 1024
|
||||
monitored_endpoints:
|
||||
- name: "api-health"
|
||||
url: "https://api.example.com/health"
|
||||
type: "http"
|
||||
interval_seconds: 30
|
||||
timeout_seconds: 10
|
||||
- name: "dns-check"
|
||||
url: "example.com"
|
||||
type: "dns"
|
||||
interval_seconds: 60
|
||||
timeout_seconds: 10
|
||||
- name: "tcp-check"
|
||||
url: "db.example.com:5432"
|
||||
type: "tcp"
|
||||
interval_seconds: 60
|
||||
timeout_seconds: 10
|
||||
static_checks:
|
||||
- name: "google"
|
||||
url: "https://google.com"
|
||||
type: "http"
|
||||
interval_seconds: 60
|
||||
timeout_seconds: 10
|
||||
alert_channels:
|
||||
teams_webhook: "https://hooks.example.com/teams/webhook"
|
||||
email_addresses:
|
||||
- "oncall@example.com"
|
||||
- "sre@example.com"
|
||||
sms_numbers:
|
||||
- "+1234567890"
|
||||
github_issue_repo: "acdl/acdl"
|
||||
@@ -0,0 +1,41 @@
|
||||
environment: dev
|
||||
id: up1
|
||||
infrastructure:
|
||||
uptime:
|
||||
inputs:
|
||||
alert_channels:
|
||||
email_addresses:
|
||||
- oncall@example.com
|
||||
- sre@example.com
|
||||
github_issue_repo: acdl/acdl
|
||||
sms_numbers:
|
||||
- '+1234567890'
|
||||
teams_webhook: https://hooks.example.com/teams/webhook
|
||||
cpu: 512
|
||||
feature_flag_enabled: true
|
||||
memory: 1024
|
||||
monitored_endpoints:
|
||||
- interval_seconds: 30
|
||||
name: api-health
|
||||
timeout_seconds: 10
|
||||
type: http
|
||||
url: https://api.example.com/health
|
||||
- interval_seconds: 60
|
||||
name: dns-check
|
||||
timeout_seconds: 10
|
||||
type: dns
|
||||
url: example.com
|
||||
- interval_seconds: 60
|
||||
name: tcp-check
|
||||
timeout_seconds: 10
|
||||
type: tcp
|
||||
url: db.example.com:5432
|
||||
region: us-east-1
|
||||
static_checks:
|
||||
- interval_seconds: 60
|
||||
name: google
|
||||
timeout_seconds: 10
|
||||
type: http
|
||||
url: https://google.com
|
||||
version: 1.0.0
|
||||
name: uptime-monitor
|
||||
@@ -1,6 +0,0 @@
|
||||
uses: acdl/pipelines/deploy.yaml@v1.8
|
||||
module: uptime
|
||||
environment: dev
|
||||
inputs:
|
||||
region: us-east-1
|
||||
feature_flag_enabled: true
|
||||
@@ -0,0 +1,9 @@
|
||||
environment: dev
|
||||
id: up1
|
||||
infrastructure:
|
||||
uptime:
|
||||
inputs:
|
||||
feature_flag_enabled: true
|
||||
region: us-east-1
|
||||
version: 1.0.0
|
||||
name: uptime-monitor
|
||||
Reference in New Issue
Block a user