Skip to content

Usecase Overview

  • Business Goal: Enforce uniform compatibility checks before plugin installs or upgrades, block mismatches with host/dependency/runtime, and provide exception approvals with full risk traceability.
  • Success Measures: Compatibility accuracy ≥98%; exception approval SLA ≤24 hours; 100% of block events logged with conflict details; ≥95% of approved exceptions attach the required monitoring strategy.
  • Scenario Alignment: Supports main scenario Stage 3 and works with detection/upgrade flows to surface risks before release.

The compatibility guard stops high-risk deployments before they reach production, while the exception workflow keeps controlled execution auditable.

Context & Assumptions

  • Prerequisites
    • Feature flags plugin-compat-guard and plugin-compat-exception are enabled.
    • Compatibility matrices and plugin manifests are current in the governance service and refreshed via CI/CD.
    • The approval system supports MFA, approval IDs, and notification channels.
    • Security teams define risk levels, approval templates, and mandatory monitoring add-ons.
  • Inputs / Outputs
    • Inputs: Install/upgrade request, plugin manifest, host version, dependency list, approval context.
    • Outputs: Compatibility report, block feedback, exception decision, audit record, required monitoring profile.
  • Boundaries
    • Upgrade execution/rollback is handled by the grey rollout use case.
    • Excludes offline import, cross-tenant policy governance, and Marketplace review.

Solution Blueprint

Architecture Layers

LayerKey ModuleResponsibilityEntry Point
Compatibility engineinternal/version/compat/engine.goLoad matrices, merge policies, compute risk scoreservices/version/compat
Validation & blockinginternal/version/compat/validator.goValidate manifests, detect conflicts, return feedbackservices/version/compat
Exception workflowinternal/version/compat/exception_workflow.goApproval steps, MFA enforcement, execution authorisationservices/version/compat
Audit & complianceinternal/audit/version/compat_log_writer.goPersist block/exception events, risk labels, reportsservices/audit/version
CLI / Consolepackages/cli/src/commands/plugin/install.tsDeliver prompts, capture exception requests, sync approval resultspackages/cli

Flow & Sequence

  1. Step 1 – Request intake: Admins trigger install/upgrade via CLI or console; the system loads plugin and host metadata.
  2. Step 2 – Compatibility check: Engine loads matrices, evaluates host, dependency, runtime, and migration scripts, and computes risk score.
  3. Step 3 – Block & feedback: Conflicts trigger an immediate block with detailed report, remediation advice, and exception entry point.
  4. Step 4 – Exception approval & controlled run: Approved exceptions install under enforced monitoring with full audit logging; rejected requests remain blocked with notifications.

Contracts & Interfaces

  • Inbound
    • POST /internal/version/compat/check — Validate plugin version against host and dependency list.
    • POST /internal/version/compat/exception — Submit exception request with risk explanation.
  • Outbound
    • POST /internal/security/scan/context — Retrieve security policies and sensitive component data.
    • POST /internal/notify/publish — Notify admins/approvers of block or approval results.
    • POST /internal/audit/version — Persist block, approval, and execution outcomes.
  • Configs & Scripts
    • config/version/compat_matrix.yaml — Matrix content, weighting, expiry.
    • config/version/exception_workflow.yaml — Approval chain, SLA, monitoring add-ons.
    • docs/standards/powerx-plugin/release/Compatibility_Checklist.md — Validation coverage & exception prerequisites.

Implementation Checklist

ItemDescriptionStatusOwner
Matrix synchronisationIntegrate vendor repos & CI/CD to keep matrices current[ ]Leo Wang
Validation engineSupport host, dependency, runtime, and data migration checks[ ]Matrix Ops
Exception workflowIntegrate approval system, MFA, approval ID tracking[ ]Grace Lin
Audit reportingProduce block/exception reports, risk labels, query endpoints[ ]Grace Lin
CLI / Console UXImprove conflict messaging, exception entry, help links[ ]Leo Wang

Testing Strategy

  • Unit: Validation rules, matrix parsing, exception state machine, audit writers.
  • Integration: Simulate install requests covering pass/block/exception paths; integrate approval and audit services.
  • E2E: Reproduce scenario cases C-1/C-2 to verify block reports, exception execution, monitoring add-ons.
  • Non-functional: Large-scale matrix performance, approval latency, log search load.

Observability & Ops

  • Metrics: version.compat.check_total, version.compat.block_total, version.compat.exception_request_total, version.compat.exception_approved_total, version.compat.matrix_staleness_hours.
  • Logs: Capture plugin version, host, dependencies, risk level, approval ID, operator; mask sensitive data; retain ≥365 days.
  • Alerts: Matrix expiry, sudden spikes in block rate, approval SLA breach, missing monitoring on exceptions.
  • Dashboards: Compatibility Guard Dashboard, Exception Workflow Monitor, workflow-metrics.mjs.

Rollback & Failure Handling

  • Rollback: Keep previous version active, cancel pending installs, restore approval queue and monitoring plan.
  • Remediation: Provide conflict report download, allow manual re-check, permit manual approval with risk acknowledgement.
  • Data Repair: Run scripts/workflows/version-compat-reconcile.mjs to reconcile block records, approval states, and audits.

Follow-ups & Risks

Risk / ItemImpactMitigationOwnerETA
Missing runtime compatibility statementsValidation accuracyEnforce templates with vendor and CI checksLeo Wang2025-12-05
Exception approvals lack granular IAM controlsComplianceIntegrate IAM roles & least-privilege approvalsGrace Lin2025-12-18
Block reports hard to interpretOps efficiencyImprove conflict grouping, link remediation guidesMatrix Ops2025-12-12

References & Links

  • Scenario: docs/scenarios/plugin-lifecycle/SCN-DEV-PLUGIN-VERSION-COMPAT-BLOCK-001.md
  • Main scenario: docs/scenarios/plugin-lifecycle/SCN-DEV-PLUGIN-VERSION-COMPAT-001.md
  • Standards: docs/standards/powerx-plugin/release/Compatibility_Checklist.md
  • Config: config/version/compat_matrix.yaml, config/version/exception_workflow.yaml

Released under the Apache 2.0 License.