@documentation-robotics/cli 0.1.0 → 0.1.7
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 +466 -693
- package/dist/analysis/data-model-analyzer.js +189 -0
- package/dist/analysis/data-model-analyzer.js.map +7 -0
- package/dist/analysis/index.js +3 -0
- package/dist/analysis/index.js.map +7 -0
- package/dist/analysis/relationship-classifier.js +181 -0
- package/dist/analysis/relationship-classifier.js.map +7 -0
- package/dist/analyzers/base-analyzer.js +1 -0
- package/dist/analyzers/base-analyzer.js.map +7 -0
- package/dist/analyzers/call-graph-utils.js +39 -0
- package/dist/analyzers/call-graph-utils.js.map +7 -0
- package/dist/analyzers/cbm-analyzer.js +1205 -0
- package/dist/analyzers/cbm-analyzer.js.map +7 -0
- package/dist/analyzers/heuristic-utils.js +55 -0
- package/dist/analyzers/heuristic-utils.js.map +7 -0
- package/dist/analyzers/mapping-loader.js +146 -0
- package/dist/analyzers/mapping-loader.js.map +7 -0
- package/dist/analyzers/registry.js +124 -0
- package/dist/analyzers/registry.js.map +7 -0
- package/dist/analyzers/session-state.js +176 -0
- package/dist/analyzers/session-state.js.map +7 -0
- package/dist/analyzers/stdio-client.js +208 -0
- package/dist/analyzers/stdio-client.js.map +7 -0
- package/dist/analyzers/types.js +15 -0
- package/dist/analyzers/types.js.map +7 -0
- package/dist/analyzers/verify-engine.js +209 -0
- package/dist/analyzers/verify-engine.js.map +7 -0
- package/dist/analyzers/verify-ignore.js +130 -0
- package/dist/analyzers/verify-ignore.js.map +7 -0
- package/dist/analyzers/version.js +8 -0
- package/dist/analyzers/version.js.map +7 -0
- package/dist/audit/ai/runner.js +41 -0
- package/dist/audit/ai/runner.js.map +7 -0
- package/dist/audit/differential-analyzer.js +183 -0
- package/dist/audit/differential-analyzer.js.map +7 -0
- package/dist/audit/index.js +32 -0
- package/dist/audit/index.js.map +7 -0
- package/dist/audit/nodes/ai/evaluator.js +49 -0
- package/dist/audit/nodes/ai/evaluator.js.map +7 -0
- package/dist/audit/nodes/ai/parser.js +55 -0
- package/dist/audit/nodes/ai/parser.js.map +7 -0
- package/dist/audit/nodes/ai/prompts.js +103 -0
- package/dist/audit/nodes/ai/prompts.js.map +7 -0
- package/dist/audit/nodes/analysis/node-completeness-checker.js +32 -0
- package/dist/audit/nodes/analysis/node-completeness-checker.js.map +7 -0
- package/dist/audit/nodes/analysis/node-definition-analyzer.js +47 -0
- package/dist/audit/nodes/analysis/node-definition-analyzer.js.map +7 -0
- package/dist/audit/nodes/analysis/node-overlap-detector.js +79 -0
- package/dist/audit/nodes/analysis/node-overlap-detector.js.map +7 -0
- package/dist/audit/nodes/model/orchestrator.js +82 -0
- package/dist/audit/nodes/model/orchestrator.js.map +7 -0
- package/dist/audit/nodes/spec/loader.js +116 -0
- package/dist/audit/nodes/spec/loader.js.map +7 -0
- package/dist/audit/nodes/spec/orchestrator.js +68 -0
- package/dist/audit/nodes/spec/orchestrator.js.map +7 -0
- package/dist/audit/nodes/types.js +1 -0
- package/dist/audit/nodes/types.js.map +7 -0
- package/dist/audit/pipeline/index.js +5 -0
- package/dist/audit/pipeline/index.js.map +7 -0
- package/dist/audit/pipeline/pipeline-orchestrator.js +218 -0
- package/dist/audit/pipeline/pipeline-orchestrator.js.map +7 -0
- package/dist/audit/relationships/ai/evaluator.js +235 -0
- package/dist/audit/relationships/ai/evaluator.js.map +7 -0
- package/dist/audit/relationships/ai/parser.js +197 -0
- package/dist/audit/relationships/ai/parser.js.map +7 -0
- package/dist/audit/relationships/ai/prompts.js +274 -0
- package/dist/audit/relationships/ai/prompts.js.map +7 -0
- package/dist/audit/relationships/analysis/balance-assessor.js +115 -0
- package/dist/audit/relationships/analysis/balance-assessor.js.map +7 -0
- package/dist/audit/relationships/analysis/coverage-analyzer.js +99 -0
- package/dist/audit/relationships/analysis/coverage-analyzer.js.map +7 -0
- package/dist/audit/relationships/analysis/duplicate-detector.js +95 -0
- package/dist/audit/relationships/analysis/duplicate-detector.js.map +7 -0
- package/dist/audit/relationships/analysis/gap-analyzer.js +99 -0
- package/dist/audit/relationships/analysis/gap-analyzer.js.map +7 -0
- package/dist/audit/relationships/analysis/layer-templates.js +294 -0
- package/dist/audit/relationships/analysis/layer-templates.js.map +7 -0
- package/dist/audit/relationships/graph/connectivity.js +129 -0
- package/dist/audit/relationships/graph/connectivity.js.map +7 -0
- package/dist/audit/relationships/graph/relationship-graph.js +179 -0
- package/dist/audit/relationships/graph/relationship-graph.js.map +7 -0
- package/dist/audit/relationships/model/balance-assessor.js +49 -0
- package/dist/audit/relationships/model/balance-assessor.js.map +7 -0
- package/dist/audit/relationships/model/coverage-analyzer.js +34 -0
- package/dist/audit/relationships/model/coverage-analyzer.js.map +7 -0
- package/dist/audit/relationships/model/duplicate-detector.js +68 -0
- package/dist/audit/relationships/model/duplicate-detector.js.map +7 -0
- package/dist/audit/relationships/model/gap-analyzer.js +41 -0
- package/dist/audit/relationships/model/gap-analyzer.js.map +7 -0
- package/dist/audit/relationships/model/orchestrator.js +126 -0
- package/dist/audit/relationships/model/orchestrator.js.map +7 -0
- package/dist/audit/relationships/spec/orchestrator.js +157 -0
- package/dist/audit/relationships/spec/orchestrator.js.map +7 -0
- package/dist/audit/reports/index.js +5 -0
- package/dist/audit/reports/index.js.map +7 -0
- package/dist/audit/reports/report-generator.js +118 -0
- package/dist/audit/reports/report-generator.js.map +7 -0
- package/dist/audit/snapshot-storage.js +163 -0
- package/dist/audit/snapshot-storage.js.map +7 -0
- package/dist/audit/types.js +21 -0
- package/dist/audit/types.js.map +7 -0
- package/dist/cli.js +223 -92
- package/dist/cli.js.map +3 -3
- package/dist/coding-agents/agents/claude-code.js +147 -0
- package/dist/coding-agents/agents/claude-code.js.map +7 -0
- package/dist/coding-agents/agents/index.js +5 -0
- package/dist/coding-agents/agents/index.js.map +7 -0
- package/dist/coding-agents/agents/types.js +1 -0
- package/dist/coding-agents/agents/types.js.map +7 -0
- package/dist/coding-agents/base-chat-client.js +45 -0
- package/dist/coding-agents/base-chat-client.js.map +7 -0
- package/dist/coding-agents/chat-utils.js +23 -0
- package/dist/coding-agents/chat-utils.js.map +7 -0
- package/dist/coding-agents/claude-code-client.js +246 -0
- package/dist/coding-agents/claude-code-client.js.map +7 -0
- package/dist/coding-agents/copilot-client.js +209 -0
- package/dist/coding-agents/copilot-client.js.map +7 -0
- package/dist/commands/add.js +95 -33
- package/dist/commands/add.js.map +2 -2
- package/dist/commands/analyzer.js +511 -0
- package/dist/commands/analyzer.js.map +7 -0
- package/dist/commands/audit-diff.js +49 -0
- package/dist/commands/audit-diff.js.map +7 -0
- package/dist/commands/audit-snapshots.js +62 -0
- package/dist/commands/audit-snapshots.js.map +7 -0
- package/dist/commands/audit.js +81 -0
- package/dist/commands/audit.js.map +7 -0
- package/dist/commands/catalog.js +248 -0
- package/dist/commands/catalog.js.map +7 -0
- package/dist/commands/changeset.js +577 -66
- package/dist/commands/changeset.js.map +2 -2
- package/dist/commands/chat.js +106 -83
- package/dist/commands/chat.js.map +2 -2
- package/dist/commands/claude.js +74 -0
- package/dist/commands/claude.js.map +7 -0
- package/dist/commands/conformance.js +71 -68
- package/dist/commands/conformance.js.map +2 -2
- package/dist/commands/copilot.js +75 -0
- package/dist/commands/copilot.js.map +7 -0
- package/dist/commands/delete.js +125 -11
- package/dist/commands/delete.js.map +3 -3
- package/dist/commands/discover-logic.js +44 -0
- package/dist/commands/discover-logic.js.map +7 -0
- package/dist/commands/docs.js +87 -0
- package/dist/commands/docs.js.map +7 -0
- package/dist/commands/element.js +14 -20
- package/dist/commands/element.js.map +2 -2
- package/dist/commands/export.js +13 -3
- package/dist/commands/export.js.map +2 -2
- package/dist/commands/import.js +51 -0
- package/dist/commands/import.js.map +7 -0
- package/dist/commands/info.js +30 -24
- package/dist/commands/info.js.map +2 -2
- package/dist/commands/init.js +27 -11
- package/dist/commands/init.js.map +2 -2
- package/dist/commands/list.js +63 -13
- package/dist/commands/list.js.map +3 -3
- package/dist/commands/relationship.js +225 -37
- package/dist/commands/relationship.js.map +2 -2
- package/dist/commands/report.js +54 -0
- package/dist/commands/report.js.map +7 -0
- package/dist/commands/reports.js +45 -0
- package/dist/commands/reports.js.map +7 -0
- package/dist/commands/schema.js +135 -0
- package/dist/commands/schema.js.map +7 -0
- package/dist/commands/search.js +40 -12
- package/dist/commands/search.js.map +2 -2
- package/dist/commands/show.js +58 -27
- package/dist/commands/show.js.map +2 -2
- package/dist/commands/stats.js +35 -0
- package/dist/commands/stats.js.map +7 -0
- package/dist/commands/trace.js +39 -16
- package/dist/commands/trace.js.map +2 -2
- package/dist/commands/update.js +141 -14
- package/dist/commands/update.js.map +2 -2
- package/dist/commands/upgrade.js +210 -46
- package/dist/commands/upgrade.js.map +3 -3
- package/dist/commands/validate.js +142 -23
- package/dist/commands/validate.js.map +3 -3
- package/dist/commands/version.js +8 -12
- package/dist/commands/version.js.map +2 -2
- package/dist/commands/visualize.js +162 -25
- package/dist/commands/visualize.js.map +2 -2
- package/dist/core/base-snapshot-manager.js +84 -0
- package/dist/core/base-snapshot-manager.js.map +7 -0
- package/dist/core/changeset-exporter.js +305 -0
- package/dist/core/changeset-exporter.js.map +7 -0
- package/dist/core/changeset-validator.js +41 -0
- package/dist/core/changeset-validator.js.map +7 -0
- package/dist/core/changeset.js +88 -173
- package/dist/core/changeset.js.map +2 -2
- package/dist/core/dependency-tracker.js +4 -2
- package/dist/core/dependency-tracker.js.map +2 -2
- package/dist/core/element.js +98 -27
- package/dist/core/element.js.map +2 -2
- package/dist/core/golden-copy-cache.js +290 -0
- package/dist/core/golden-copy-cache.js.map +7 -0
- package/dist/core/graph-model.js +266 -0
- package/dist/core/graph-model.js.map +7 -0
- package/dist/core/layer.js +159 -16
- package/dist/core/layer.js.map +2 -2
- package/dist/core/layers.js +32 -0
- package/dist/core/layers.js.map +7 -0
- package/dist/core/manifest.js +32 -11
- package/dist/core/manifest.js.map +2 -2
- package/dist/core/migration-registry.js +56 -1
- package/dist/core/migration-registry.js.map +2 -2
- package/dist/core/model.js +424 -217
- package/dist/core/model.js.map +3 -3
- package/dist/core/mutation-handler.js +179 -0
- package/dist/core/mutation-handler.js.map +7 -0
- package/dist/core/reference-registry.js +29 -21
- package/dist/core/reference-registry.js.map +2 -2
- package/dist/core/relationship-catalog.js +189 -0
- package/dist/core/relationship-catalog.js.map +7 -0
- package/dist/core/relationship-registry.js.map +2 -2
- package/dist/core/relationships.js.map +1 -1
- package/dist/core/report-data-model.js +285 -0
- package/dist/core/report-data-model.js.map +7 -0
- package/dist/core/spec-data-service.js +185 -0
- package/dist/core/spec-data-service.js.map +7 -0
- package/dist/core/spec-loader-types.js +1 -0
- package/dist/core/spec-loader-types.js.map +7 -0
- package/dist/core/spec-loader.js +234 -0
- package/dist/core/spec-loader.js.map +7 -0
- package/dist/core/staged-changeset-storage.js +282 -0
- package/dist/core/staged-changeset-storage.js.map +7 -0
- package/dist/core/staging-area.js +1002 -0
- package/dist/core/staging-area.js.map +7 -0
- package/dist/core/stats-collector.js +169 -0
- package/dist/core/stats-collector.js.map +7 -0
- package/dist/core/virtual-projection.js +443 -0
- package/dist/core/virtual-projection.js.map +7 -0
- package/dist/export/archimate-exporter.js +99 -60
- package/dist/export/archimate-exporter.js.map +2 -2
- package/dist/export/audit-formatters.js +479 -0
- package/dist/export/audit-formatters.js.map +7 -0
- package/dist/export/diff-formatters.js +99 -0
- package/dist/export/diff-formatters.js.map +7 -0
- package/dist/export/export-manager.js.map +2 -2
- package/dist/export/graphml-exporter.js +44 -27
- package/dist/export/graphml-exporter.js.map +2 -2
- package/dist/export/index.js +4 -0
- package/dist/export/index.js.map +2 -2
- package/dist/export/json-schema-exporter.js +55 -42
- package/dist/export/json-schema-exporter.js.map +2 -2
- package/dist/export/markdown-exporter.js +92 -70
- package/dist/export/markdown-exporter.js.map +2 -2
- package/dist/export/markdown-generator.js +248 -0
- package/dist/export/markdown-generator.js.map +7 -0
- package/dist/export/markdown-utils.js +30 -0
- package/dist/export/markdown-utils.js.map +7 -0
- package/dist/export/mermaid-markdown-exporter.js +37 -0
- package/dist/export/mermaid-markdown-exporter.js.map +7 -0
- package/dist/export/openapi-exporter.js +119 -71
- package/dist/export/openapi-exporter.js.map +2 -2
- package/dist/export/plantuml-exporter.js +104 -39
- package/dist/export/plantuml-exporter.js.map +2 -2
- package/dist/export/report-formatters.js +111 -0
- package/dist/export/report-formatters.js.map +7 -0
- package/dist/export/stats-formatters.js +98 -0
- package/dist/export/stats-formatters.js.map +7 -0
- package/dist/export/types.js +2 -14
- package/dist/export/types.js.map +2 -2
- package/dist/export/verify-formatters.js +153 -0
- package/dist/export/verify-formatters.js.map +7 -0
- package/dist/generated/compiled-validators.js +17 -0
- package/dist/generated/compiled-validators.js.map +7 -0
- package/dist/generated/index.js +31 -0
- package/dist/generated/index.js.map +7 -0
- package/dist/generated/layer-registry.js +190 -0
- package/dist/generated/layer-registry.js.map +7 -0
- package/dist/generated/layer-types.js +7 -0
- package/dist/generated/layer-types.js.map +7 -0
- package/dist/generated/node-types.js +1719 -0
- package/dist/generated/node-types.js.map +7 -0
- package/dist/generated/relationship-index.js +14552 -0
- package/dist/generated/relationship-index.js.map +7 -0
- package/dist/import/archimate-importer.js +166 -0
- package/dist/import/archimate-importer.js.map +7 -0
- package/dist/import/index.js +47 -0
- package/dist/import/index.js.map +7 -0
- package/dist/import/openapi-importer.js +143 -0
- package/dist/import/openapi-importer.js.map +7 -0
- package/dist/import/types.js +1 -0
- package/dist/import/types.js.map +7 -0
- package/dist/integrations/base-manager.js +311 -0
- package/dist/integrations/base-manager.js.map +7 -0
- package/dist/integrations/claude-manager.js +360 -0
- package/dist/integrations/claude-manager.js.map +7 -0
- package/dist/integrations/claude_code/agents/dr-advisor.md +253 -0
- package/dist/integrations/claude_code/agents/dr-architect.md +278 -0
- package/dist/integrations/claude_code/agents/dr-extractor.md +286 -0
- package/dist/integrations/claude_code/commands/dr-changeset.md +657 -0
- package/dist/integrations/claude_code/commands/dr-design.md +373 -0
- package/dist/integrations/claude_code/commands/dr-info.md +132 -0
- package/dist/integrations/claude_code/commands/dr-init.md +251 -0
- package/dist/integrations/claude_code/commands/dr-map.md +936 -0
- package/dist/integrations/claude_code/commands/dr-model.md +493 -0
- package/dist/integrations/claude_code/commands/dr-relate.md +814 -0
- package/dist/integrations/claude_code/commands/dr-sync.md +279 -0
- package/dist/integrations/claude_code/commands/dr-validate.md +654 -0
- package/dist/integrations/claude_code/commands/dr-verify.md +559 -0
- package/dist/integrations/claude_code/docs/END_TO_END_WALKTHROUGH.md +903 -0
- package/dist/integrations/claude_code/docs/QUICK_START.md +271 -0
- package/dist/integrations/claude_code/docs/README.md +347 -0
- package/dist/integrations/claude_code/skills/dr_01_motivation_layer/SKILL.md +550 -0
- package/dist/integrations/claude_code/skills/dr_02_business_layer/SKILL.md +620 -0
- package/dist/integrations/claude_code/skills/dr_03_security_layer/SKILL.md +642 -0
- package/dist/integrations/claude_code/skills/dr_04_application_layer/SKILL.md +911 -0
- package/dist/integrations/claude_code/skills/dr_05_technology_layer/SKILL.md +836 -0
- package/dist/integrations/claude_code/skills/dr_06_api_layer/SKILL.md +933 -0
- package/dist/integrations/claude_code/skills/dr_07_data_model_layer/SKILL.md +210 -0
- package/dist/integrations/claude_code/skills/dr_08_dataset_layer/SKILL.md +319 -0
- package/dist/integrations/claude_code/skills/dr_09_ux_layer/SKILL.md +319 -0
- package/dist/integrations/claude_code/skills/dr_10_navigation_layer/SKILL.md +318 -0
- package/dist/integrations/claude_code/skills/dr_11_apm_layer/SKILL.md +273 -0
- package/dist/integrations/claude_code/skills/dr_12_testing_layer/SKILL.md +273 -0
- package/dist/integrations/claude_code/skills/dr_changeset_reviewer/SKILL.md +187 -0
- package/dist/integrations/claude_code/skills/dr_codebase_memory/SKILL.md +590 -0
- package/dist/integrations/claude_code/skills/dr_engineering_guide/SKILL.md +295 -0
- package/dist/integrations/copilot-manager.js +328 -0
- package/dist/integrations/copilot-manager.js.map +7 -0
- package/dist/integrations/github_copilot/agents/dr-advisor.md +243 -0
- package/dist/integrations/github_copilot/agents/dr-architect.md +1567 -0
- package/dist/integrations/github_copilot/skills/dr_01_motivation_layer/SKILL.md +491 -0
- package/dist/integrations/github_copilot/skills/dr_02_business_layer/SKILL.md +539 -0
- package/dist/integrations/github_copilot/skills/dr_03_security_layer/SKILL.md +667 -0
- package/dist/integrations/github_copilot/skills/dr_04_application_layer/SKILL.md +670 -0
- package/dist/integrations/github_copilot/skills/dr_05_technology_layer/SKILL.md +660 -0
- package/dist/integrations/github_copilot/skills/dr_06_api_layer/SKILL.md +855 -0
- package/dist/integrations/github_copilot/skills/dr_07_data_model_layer/SKILL.md +171 -0
- package/dist/integrations/github_copilot/skills/dr_08_dataset_layer/SKILL.md +216 -0
- package/dist/integrations/github_copilot/skills/dr_09_ux_layer/SKILL.md +230 -0
- package/dist/integrations/github_copilot/skills/dr_10_navigation_layer/SKILL.md +228 -0
- package/dist/integrations/github_copilot/skills/dr_11_apm_layer/SKILL.md +234 -0
- package/dist/integrations/github_copilot/skills/dr_12_testing_layer/SKILL.md +230 -0
- package/dist/integrations/github_copilot/skills/dr_changeset_reviewer/SKILL.md +187 -0
- package/dist/integrations/hash-utils.js +51 -0
- package/dist/integrations/hash-utils.js.map +7 -0
- package/dist/integrations/types.js +16 -0
- package/dist/integrations/types.js.map +7 -0
- package/dist/reports/model-layer-report-generator.js +278 -0
- package/dist/reports/model-layer-report-generator.js.map +7 -0
- package/dist/reports/model-report-data.js +57 -0
- package/dist/reports/model-report-data.js.map +7 -0
- package/dist/reports/model-report-orchestrator.js +103 -0
- package/dist/reports/model-report-orchestrator.js.map +7 -0
- package/dist/schemas/bundled/analyzers/cbm.json +595 -0
- package/dist/schemas/bundled/analyzers/manifest.json +9 -0
- package/dist/schemas/bundled/api.json +3411 -0
- package/dist/schemas/bundled/apm.json +2371 -0
- package/dist/schemas/bundled/application.json +1253 -0
- package/dist/schemas/bundled/base.json +1622 -0
- package/dist/schemas/bundled/business.json +1279 -0
- package/dist/schemas/bundled/data-model.json +1298 -0
- package/dist/schemas/bundled/data-store.json +2025 -0
- package/dist/schemas/bundled/manifest.json +93 -0
- package/dist/schemas/bundled/motivation.json +1360 -0
- package/dist/schemas/bundled/navigation.json +1874 -0
- package/dist/schemas/bundled/security.json +3488 -0
- package/dist/schemas/bundled/technology.json +2067 -0
- package/dist/schemas/bundled/testing.json +3120 -0
- package/dist/schemas/bundled/ux.json +3592 -0
- package/dist/server/schemas.js +202 -0
- package/dist/server/schemas.js.map +7 -0
- package/dist/server/server.js +1336 -252
- package/dist/server/server.js.map +3 -3
- package/dist/server/telemetry-middleware.js +22 -15
- package/dist/server/telemetry-middleware.js.map +2 -2
- package/dist/server-entry.js +65 -0
- package/dist/server-entry.js.map +7 -0
- package/dist/telemetry/config.js +89 -0
- package/dist/telemetry/config.js.map +7 -0
- package/dist/telemetry/console-interceptor.js.map +1 -1
- package/dist/telemetry/detect.js +24 -0
- package/dist/telemetry/detect.js.map +7 -0
- package/dist/telemetry/fetch-otlp-exporter.js +112 -0
- package/dist/telemetry/fetch-otlp-exporter.js.map +7 -0
- package/dist/telemetry/index.js +153 -3
- package/dist/telemetry/index.js.map +2 -2
- package/dist/telemetry/resilient-exporter.js +22 -8
- package/dist/telemetry/resilient-exporter.js.map +2 -2
- package/dist/telemetry/resilient-log-exporter.js +17 -8
- package/dist/telemetry/resilient-log-exporter.js.map +2 -2
- package/dist/telemetry/test-instrumentation.js.map +2 -2
- package/dist/types/index.js +84 -0
- package/dist/types/index.js.map +3 -3
- package/dist/types/source-reference.js +1 -0
- package/dist/types/source-reference.js.map +7 -0
- package/dist/utils/chat-logger.js +292 -0
- package/dist/utils/chat-logger.js.map +7 -0
- package/dist/utils/claude-stream.js +8 -0
- package/dist/utils/claude-stream.js.map +7 -0
- package/dist/utils/date-utils.js +7 -0
- package/dist/utils/date-utils.js.map +7 -0
- package/dist/utils/element-utils.js.map +1 -1
- package/dist/utils/errors.js +88 -15
- package/dist/utils/errors.js.map +3 -3
- package/dist/utils/export-python-annotations.js +82 -0
- package/dist/utils/export-python-annotations.js.map +7 -0
- package/dist/utils/file-io.js +7 -2
- package/dist/utils/file-io.js.map +2 -2
- package/dist/utils/file-lock.js +156 -0
- package/dist/utils/file-lock.js.map +7 -0
- package/dist/utils/id-generator.js +18 -0
- package/dist/utils/id-generator.js.map +7 -0
- package/dist/utils/layer-name-formatter.js +16 -0
- package/dist/utils/layer-name-formatter.js.map +7 -0
- package/dist/utils/markdown-anchor.js +7 -0
- package/dist/utils/markdown-anchor.js.map +7 -0
- package/dist/utils/markdown-link.js +12 -0
- package/dist/utils/markdown-link.js.map +7 -0
- package/dist/utils/markdown-table.js +17 -0
- package/dist/utils/markdown-table.js.map +7 -0
- package/dist/utils/mermaid-utils.js +11 -0
- package/dist/utils/mermaid-utils.js.map +7 -0
- package/dist/utils/project-paths.js.map +2 -2
- package/dist/utils/source-reference.js +52 -0
- package/dist/utils/source-reference.js.map +7 -0
- package/dist/utils/spec-installer.js +40 -53
- package/dist/utils/spec-installer.js.map +2 -2
- package/dist/utils/spec-version.js +5 -1
- package/dist/utils/spec-version.js.map +2 -2
- package/dist/utils/string-utils.js +12 -0
- package/dist/utils/string-utils.js.map +7 -0
- package/dist/utils/table-formatting.js +19 -0
- package/dist/utils/table-formatting.js.map +7 -0
- package/dist/validators/index.js +4 -0
- package/dist/validators/index.js.map +2 -2
- package/dist/validators/naming-validator.js +20 -23
- package/dist/validators/naming-validator.js.map +2 -2
- package/dist/validators/reference-validator.js +23 -38
- package/dist/validators/reference-validator.js.map +2 -2
- package/dist/validators/relationship-schema-validator.js +243 -0
- package/dist/validators/relationship-schema-validator.js.map +7 -0
- package/dist/validators/schema-validator.js +168 -68
- package/dist/validators/schema-validator.js.map +2 -2
- package/dist/validators/semantic-validator.js +36 -60
- package/dist/validators/semantic-validator.js.map +2 -2
- package/dist/validators/types.js.map +2 -2
- package/dist/validators/validation-formatter.js +159 -0
- package/dist/validators/validation-formatter.js.map +7 -0
- package/dist/validators/validator.js +24 -38
- package/dist/validators/validator.js.map +2 -2
- package/dist/viewer/README.md +139 -0
- package/dist/viewer/assets/main-CY0Xufuj.css +1 -0
- package/dist/viewer/assets/main-DtgErnwF.js +81 -0
- package/dist/viewer/assets/vendor-CxKvDp2x.js +17 -0
- package/dist/viewer/favicon.svg +11 -0
- package/dist/viewer/fonts/inter/Inter-Black.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Bold.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-ExtraBold.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Light.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Medium.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Regular.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-SemiBold.woff2 +0 -0
- package/dist/viewer/fonts/jetbrains-mono/JetBrainsMono-Medium.woff2 +0 -0
- package/dist/viewer/fonts/jetbrains-mono/JetBrainsMono-Regular.woff2 +0 -0
- package/dist/viewer/fonts/jetbrains-mono/JetBrainsMono-SemiBold.woff2 +0 -0
- package/dist/viewer/index.html +15 -0
- package/dist/viewer/manifest.json +99 -0
- package/dist/viewer/version.json +1 -0
- package/package.json +42 -16
- package/PYTHON_CLI_PARITY.md +0 -265
- package/PYTHON_CLI_STRUCTURE_UPDATE.md +0 -246
- package/biome.json +0 -42
- package/bunfig.toml +0 -3
- package/dist/ai/claude-client.js +0 -71
- package/dist/ai/claude-client.js.map +0 -7
- package/dist/ai/context-provider.js +0 -129
- package/dist/ai/context-provider.js.map +0 -7
- package/dist/ai/tools.js +0 -231
- package/dist/ai/tools.js.map +0 -7
- package/dist/commands/migrate.js +0 -36
- package/dist/commands/migrate.js.map +0 -7
- package/dist/commands/project.js +0 -74
- package/dist/commands/project.js.map +0 -7
- package/dist/core/active-changeset.js +0 -52
- package/dist/core/active-changeset.js.map +0 -7
- package/dist/core/projection-engine.js +0 -288
- package/dist/core/projection-engine.js.map +0 -7
- package/dist/schemas/bundled/01-motivation-layer.schema.json +0 -942
- package/dist/schemas/bundled/02-business-layer.schema.json +0 -1293
- package/dist/schemas/bundled/03-security-layer.schema.json +0 -2177
- package/dist/schemas/bundled/04-application-layer.schema.json +0 -1328
- package/dist/schemas/bundled/05-technology-layer.schema.json +0 -1465
- package/dist/schemas/bundled/06-api-layer.schema.json +0 -1743
- package/dist/schemas/bundled/07-data-model-layer.schema.json +0 -1253
- package/dist/schemas/bundled/08-datastore-layer.schema.json +0 -892
- package/dist/schemas/bundled/09-ux-layer.schema.json +0 -1506
- package/dist/schemas/bundled/10-navigation-layer.schema.json +0 -843
- package/dist/schemas/bundled/11-apm-observability-layer.schema.json +0 -1430
- package/dist/schemas/bundled/12-testing-layer.schema.json +0 -1091
- package/dist/schemas/bundled/common/layer-extensions.schema.json +0 -266
- package/dist/schemas/bundled/common/predicates.schema.json +0 -493
- package/dist/schemas/bundled/common/relationships.schema.json +0 -791
- package/dist/schemas/bundled/common/source-references.schema.json +0 -71
- package/dist/schemas/bundled/link-registry.json +0 -1839
- package/dist/schemas/bundled/link-registry.schema.json +0 -339
- package/dist/schemas/bundled/relationship-catalog.json +0 -1302
- package/dist/schemas/bundled/relationship-type.schema.json +0 -221
- package/dist/utils/model-path.js +0 -22
- package/dist/utils/model-path.js.map +0 -7
- package/docs/TEST-INSTRUMENTATION.md +0 -405
- package/docs/telemetry.md +0 -427
- package/test-debug.js +0 -33
- package/test-special.mjs +0 -46
- package/test_runner.ts +0 -7
|
@@ -0,0 +1,660 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: LAYER_05_TECH
|
|
3
|
+
description: Expert knowledge for Technology Layer modeling in Documentation Robotics
|
|
4
|
+
triggers:
|
|
5
|
+
[
|
|
6
|
+
"infrastructure",
|
|
7
|
+
"node",
|
|
8
|
+
"kubernetes",
|
|
9
|
+
"docker",
|
|
10
|
+
"server",
|
|
11
|
+
"database",
|
|
12
|
+
"technology service",
|
|
13
|
+
"network",
|
|
14
|
+
"cloud",
|
|
15
|
+
"terraform",
|
|
16
|
+
"archimate technology"
|
|
17
|
+
]
|
|
18
|
+
version: 0.8.1
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
# Technology Layer Skill
|
|
22
|
+
|
|
23
|
+
**Layer Number:** 05
|
|
24
|
+
**Specification:** Metadata Model Spec v0.8.1
|
|
25
|
+
**Purpose:** Describes the technology infrastructure including hardware, software, networks, and facilities that support applications.
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
## Layer Overview
|
|
30
|
+
|
|
31
|
+
The Technology Layer captures **infrastructure and platform**:
|
|
32
|
+
|
|
33
|
+
- **COMPUTE** - Nodes, devices, system software
|
|
34
|
+
- **NETWORK** - Communication networks, paths, interfaces
|
|
35
|
+
- **STORAGE** - Artifacts (databases, files, configurations)
|
|
36
|
+
- **SERVICES** - Technology services (IaaS, PaaS)
|
|
37
|
+
- **AUTOMATION** - Infrastructure as Code (Terraform, Ansible, K8s)
|
|
38
|
+
|
|
39
|
+
This layer uses **ArchiMate 3.2 Technology Layer** standard with optional properties for Infrastructure as Code references, cloud provider specifics, and operational characteristics.
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## Entity Types
|
|
44
|
+
|
|
45
|
+
> **CLI Introspection:** Run `dr schema types technology` for the authoritative, always-current list of node types.
|
|
46
|
+
> Run `dr schema node <type-id>` for full attribute details on any type.
|
|
47
|
+
|
|
48
|
+
| Entity Type | Description | Key Attributes |
|
|
49
|
+
| --------------------------- | ------------------------------------------------------- | -------------------------------------------------------------------------------------------- |
|
|
50
|
+
| **Node** | Computational or physical resource that hosts artifacts | Types: server, container, vm, kubernetes-cluster, serverless-function, database-cluster |
|
|
51
|
+
| **Device** | Physical IT resource with processing capability | Types: server, workstation, mobile, iot-device, network-device, storage-appliance |
|
|
52
|
+
| **SystemSoftware** | Software that provides platform for applications | Types: operating-system, database, middleware, container-runtime, web-server, message-broker |
|
|
53
|
+
| **TechnologyCollaboration** | Aggregate of nodes working together | Examples: HA Cluster, CDN Network, Service Mesh |
|
|
54
|
+
| **TechnologyInterface** | Point of access where technology services are available | Protocols: HTTP, HTTPS, TCP, UDP, WebSocket, AMQP, MQTT, SQL, gRPC |
|
|
55
|
+
| **Path** | Link between nodes through which they exchange | Types: network, vpn, direct-connect, internet, peering |
|
|
56
|
+
| **CommunicationNetwork** | Set of structures that connects nodes | Types: lan, wan, vpn, internet, cdn, service-mesh, zero-trust-network |
|
|
57
|
+
| **TechnologyFunction** | Collection of technology behavior | Examples: Load Balancing, Data Replication, Auto-scaling, Monitoring |
|
|
58
|
+
| **TechnologyProcess** | Sequence of technology behaviors (CI/CD, provisioning) | Automation: ansible, terraform, kubernetes, cloudformation, pulumi |
|
|
59
|
+
| **TechnologyInteraction** | Unit of collective technology behavior | Examples: Database Replication, Cache Synchronization, Failover |
|
|
60
|
+
| **TechnologyEvent** | Technology state change | Types: startup, shutdown, failure, scaling, maintenance, alert |
|
|
61
|
+
| **TechnologyService** | Externally visible unit of technology functionality | Types: infrastructure, platform, storage, compute, network, database, messaging |
|
|
62
|
+
| **Artifact** | Physical piece of data used or produced | Types: database, file, configuration, binary, log, backup, docker-image, helm-chart |
|
|
63
|
+
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
## Intra-Layer Relationships
|
|
67
|
+
|
|
68
|
+
### Structural Relationships
|
|
69
|
+
|
|
70
|
+
| Source Type | Predicate | Target Type | Example |
|
|
71
|
+
| ----------------------- | --------------- | --------------------- | ------------------------------------------------- |
|
|
72
|
+
| Device | composes | Node | "Physical Server" composes "Virtual Machine" |
|
|
73
|
+
| Node | composes | TechnologyInterface | "API Server" composes "HTTPS Endpoint" |
|
|
74
|
+
| SystemSoftware | composes | TechnologyInterface | "PostgreSQL" composes "SQL Interface" |
|
|
75
|
+
| Node | aggregates | Device | Cluster aggregates multiple physical servers |
|
|
76
|
+
| TechnologyCollaboration | aggregates | Node | "K8s Cluster" aggregates "Worker Nodes" |
|
|
77
|
+
| Artifact | specializes | Artifact | "CustomerDatabase" specializes "Database" |
|
|
78
|
+
| Path | realizes | CommunicationNetwork | "VPN Tunnel" realizes "Secure Network" |
|
|
79
|
+
| TechnologyFunction | realizes | TechnologyService | "Load Balancing" realizes "Load Balancer Service" |
|
|
80
|
+
| TechnologyProcess | realizes | TechnologyService | "CI/CD Pipeline" realizes "Deployment Service" |
|
|
81
|
+
| SystemSoftware | realizes | TechnologyService | "PostgreSQL" realizes "Database Service" |
|
|
82
|
+
| Node | assigned-to | TechnologyFunction | "Edge Server" assigned to "CDN Caching" |
|
|
83
|
+
| TechnologyCollaboration | assigned-to | TechnologyInteraction | Cluster performs replication |
|
|
84
|
+
| Path | associated-with | Node | Network path connects nodes |
|
|
85
|
+
| Device | associated-with | CommunicationNetwork | Device connected to network |
|
|
86
|
+
| TechnologyInterface | serves | TechnologyService | Interface provides service access |
|
|
87
|
+
|
|
88
|
+
### Behavioral Relationships
|
|
89
|
+
|
|
90
|
+
| Source Type | Predicate | Target Type | Example |
|
|
91
|
+
| --------------------- | --------- | ------------------ | --------------------------------------------------- |
|
|
92
|
+
| TechnologyEvent | triggers | TechnologyProcess | "Node Failure" triggers "Failover Process" |
|
|
93
|
+
| TechnologyEvent | triggers | TechnologyFunction | "CPU Threshold" triggers "Auto-scaling Function" |
|
|
94
|
+
| TechnologyProcess | triggers | TechnologyEvent | "Deployment Complete" triggers "Health Check Event" |
|
|
95
|
+
| TechnologyProcess | flows-to | TechnologyProcess | "Build" flows to "Deploy" |
|
|
96
|
+
| TechnologyService | flows-to | TechnologyService | Service dependency chain |
|
|
97
|
+
| SystemSoftware | accesses | Artifact | "Database" accesses "Data Files" |
|
|
98
|
+
| TechnologyFunction | accesses | Artifact | "Backup Function" accesses "Backup Files" |
|
|
99
|
+
| TechnologyProcess | accesses | Artifact | "Deployment" accesses "Docker Images" |
|
|
100
|
+
| TechnologyInteraction | accesses | Artifact | "Replication" accesses "Database Replica" |
|
|
101
|
+
|
|
102
|
+
---
|
|
103
|
+
|
|
104
|
+
## Cross-Layer References
|
|
105
|
+
|
|
106
|
+
### Outgoing References (Technology → Other Layers)
|
|
107
|
+
|
|
108
|
+
| Target Layer | Reference Type | Example |
|
|
109
|
+
| ------------------------- | -------------------------------------------------- | -------------------------------------- |
|
|
110
|
+
| **Layer 1 (Motivation)** | TechnologyService supports **Goal** | Infrastructure supports business goals |
|
|
111
|
+
| **Layer 1 (Motivation)** | TechnologyService governed by **Principle** | Cloud-native principle |
|
|
112
|
+
| **Layer 1 (Motivation)** | Node governed by **Principle** | Infrastructure principles |
|
|
113
|
+
| **Layer 1 (Motivation)** | Node constrained by **Constraint** | Budget, region, compliance constraints |
|
|
114
|
+
| **Layer 1 (Motivation)** | Node fulfills **Requirement** | Performance, availability requirements |
|
|
115
|
+
| **Layer 1 (Motivation)** | SystemSoftware governed by **Principle** | Open-source principle |
|
|
116
|
+
| **Layer 1 (Motivation)** | SystemSoftware constrained by **Constraint** | Licensing, version constraints |
|
|
117
|
+
| **Layer 1 (Motivation)** | SystemSoftware fulfills **Requirement** | Technical requirements |
|
|
118
|
+
| **Layer 1 (Motivation)** | CommunicationNetwork governed by **Principle** | Zero-trust principle |
|
|
119
|
+
| **Layer 1 (Motivation)** | CommunicationNetwork constrained by **Constraint** | Network segmentation |
|
|
120
|
+
| **Layer 1 (Motivation)** | Artifact constrained by **Constraint** | Data residency, retention |
|
|
121
|
+
| **Layer 4 (Application)** | Node hosts **ApplicationComponent** | K8s pod hosts service |
|
|
122
|
+
| **Layer 4 (Application)** | TechnologyService serves **ApplicationService** | Database serves application |
|
|
123
|
+
| **Layer 4 (Application)** | Artifact stores **DataObject** | Database stores application data |
|
|
124
|
+
| **Layer 3 (Security)** | Artifact has **encryption** property | Data-at-rest encryption |
|
|
125
|
+
| **Layer 3 (Security)** | Artifact has **classification** property | Data classification level |
|
|
126
|
+
| **Layer 3 (Security)** | Artifact has **pii** property | Contains PII |
|
|
127
|
+
| **Layer 3 (Security)** | CommunicationNetwork has **security-policy** | Network security rules |
|
|
128
|
+
| **Layer 11 (APM)** | TechnologyService has **sla-target** | Availability, latency targets |
|
|
129
|
+
| **Layer 11 (APM)** | TechnologyService has **health-check** | Health monitoring endpoint |
|
|
130
|
+
| **Layer 11 (APM)** | Node has **monitoring-agent** | APM agent installation |
|
|
131
|
+
|
|
132
|
+
### Incoming References (Lower Layers → Technology)
|
|
133
|
+
|
|
134
|
+
Lower layers reference Technology layer to show:
|
|
135
|
+
|
|
136
|
+
- Applications depend on infrastructure
|
|
137
|
+
- APIs run on technology platforms
|
|
138
|
+
- Data stored in technology artifacts
|
|
139
|
+
|
|
140
|
+
---
|
|
141
|
+
|
|
142
|
+
## Codebase Detection Patterns
|
|
143
|
+
|
|
144
|
+
### Pattern 1: Kubernetes Deployment
|
|
145
|
+
|
|
146
|
+
```yaml
|
|
147
|
+
# Kubernetes deployment manifest
|
|
148
|
+
apiVersion: apps/v1
|
|
149
|
+
kind: Deployment
|
|
150
|
+
metadata:
|
|
151
|
+
name: user-service
|
|
152
|
+
namespace: production
|
|
153
|
+
spec:
|
|
154
|
+
replicas: 3
|
|
155
|
+
selector:
|
|
156
|
+
matchLabels:
|
|
157
|
+
app: user-service
|
|
158
|
+
template:
|
|
159
|
+
metadata:
|
|
160
|
+
labels:
|
|
161
|
+
app: user-service
|
|
162
|
+
spec:
|
|
163
|
+
containers:
|
|
164
|
+
- name: user-service
|
|
165
|
+
image: myregistry/user-service:1.0.0
|
|
166
|
+
ports:
|
|
167
|
+
- containerPort: 8080
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
**Maps to:**
|
|
171
|
+
|
|
172
|
+
- Node: "K8s Cluster Production" (type: kubernetes-cluster)
|
|
173
|
+
- Node: "User Service Pod" (type: container)
|
|
174
|
+
- Artifact: "myregistry/user-service:1.0.0" (type: docker-image)
|
|
175
|
+
- TechnologyInterface: "Port 8080" (protocol: HTTP)
|
|
176
|
+
|
|
177
|
+
### Pattern 2: Terraform Infrastructure
|
|
178
|
+
|
|
179
|
+
```hcl
|
|
180
|
+
# Terraform AWS infrastructure
|
|
181
|
+
resource "aws_instance" "web_server" {
|
|
182
|
+
ami = "ami-0c55b159cbfafe1f0"
|
|
183
|
+
instance_type = "t3.medium"
|
|
184
|
+
availability_zone = "us-east-1a"
|
|
185
|
+
|
|
186
|
+
tags = {
|
|
187
|
+
Name = "Web Server"
|
|
188
|
+
Environment = "production"
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
resource "aws_db_instance" "postgres" {
|
|
193
|
+
engine = "postgres"
|
|
194
|
+
engine_version = "14.7"
|
|
195
|
+
instance_class = "db.t3.medium"
|
|
196
|
+
storage_type = "gp3"
|
|
197
|
+
}
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
**Maps to:**
|
|
201
|
+
|
|
202
|
+
- Node: "Web Server EC2" (type: server, provider: aws, instance-type: t3.medium, region: us-east-1, az: us-east-1a)
|
|
203
|
+
- Node: "PostgreSQL RDS" (type: database-cluster, provider: aws)
|
|
204
|
+
- SystemSoftware: "PostgreSQL 14.7" (type: database, version: 14.7)
|
|
205
|
+
- Properties: iac-tool=terraform, iac-file=main.tf
|
|
206
|
+
|
|
207
|
+
### Pattern 3: Docker Compose
|
|
208
|
+
|
|
209
|
+
```yaml
|
|
210
|
+
# docker-compose.yml
|
|
211
|
+
version: "3.8"
|
|
212
|
+
services:
|
|
213
|
+
api:
|
|
214
|
+
image: myapp/api:latest
|
|
215
|
+
ports:
|
|
216
|
+
- "8080:8080"
|
|
217
|
+
depends_on:
|
|
218
|
+
- postgres
|
|
219
|
+
- redis
|
|
220
|
+
|
|
221
|
+
postgres:
|
|
222
|
+
image: postgres:14
|
|
223
|
+
environment:
|
|
224
|
+
POSTGRES_DB: myapp
|
|
225
|
+
POSTGRES_USER: admin
|
|
226
|
+
volumes:
|
|
227
|
+
- postgres-data:/var/lib/postgresql/data
|
|
228
|
+
|
|
229
|
+
redis:
|
|
230
|
+
image: redis:7-alpine
|
|
231
|
+
ports:
|
|
232
|
+
- "6379:6379"
|
|
233
|
+
|
|
234
|
+
volumes:
|
|
235
|
+
postgres-data:
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
**Maps to:**
|
|
239
|
+
|
|
240
|
+
- TechnologyCollaboration: "Docker Compose Stack"
|
|
241
|
+
- Node: "API Container" (type: container)
|
|
242
|
+
- SystemSoftware: "PostgreSQL 14" (type: database)
|
|
243
|
+
- SystemSoftware: "Redis 7" (type: middleware, subtype: cache)
|
|
244
|
+
- Artifact: "postgres-data" (type: volume)
|
|
245
|
+
- TechnologyInterface: "Redis Port 6379" (protocol: TCP)
|
|
246
|
+
|
|
247
|
+
### Pattern 4: Database Configuration
|
|
248
|
+
|
|
249
|
+
```python
|
|
250
|
+
# Database connection configuration
|
|
251
|
+
DATABASE_CONFIG = {
|
|
252
|
+
"host": "prod-db.example.com",
|
|
253
|
+
"port": 5432,
|
|
254
|
+
"database": "customer_db",
|
|
255
|
+
"user": "app_user",
|
|
256
|
+
"password": "${DB_PASSWORD}",
|
|
257
|
+
"pool_size": 20,
|
|
258
|
+
"max_overflow": 10,
|
|
259
|
+
"pool_timeout": 30
|
|
260
|
+
}
|
|
261
|
+
```
|
|
262
|
+
|
|
263
|
+
**Maps to:**
|
|
264
|
+
|
|
265
|
+
- Node: "Production Database" (type: database-cluster, host: prod-db.example.com)
|
|
266
|
+
- SystemSoftware: "PostgreSQL" (type: database, port: 5432)
|
|
267
|
+
- Artifact: "customer_db" (type: database)
|
|
268
|
+
- TechnologyInterface: "PostgreSQL Interface" (protocol: SQL, port: 5432)
|
|
269
|
+
- Properties: pool-size=20, max-overflow=10
|
|
270
|
+
|
|
271
|
+
### Pattern 5: CI/CD Pipeline
|
|
272
|
+
|
|
273
|
+
```yaml
|
|
274
|
+
# GitHub Actions CI/CD
|
|
275
|
+
name: Deploy to Production
|
|
276
|
+
on:
|
|
277
|
+
push:
|
|
278
|
+
branches: [main]
|
|
279
|
+
|
|
280
|
+
jobs:
|
|
281
|
+
build:
|
|
282
|
+
runs-on: ubuntu-latest
|
|
283
|
+
steps:
|
|
284
|
+
- uses: actions/checkout@v3
|
|
285
|
+
- name: Build Docker image
|
|
286
|
+
run: docker build -t myapp:${{ github.sha }} .
|
|
287
|
+
- name: Push to registry
|
|
288
|
+
run: docker push myregistry/myapp:${{ github.sha }}
|
|
289
|
+
|
|
290
|
+
deploy:
|
|
291
|
+
needs: build
|
|
292
|
+
runs-on: ubuntu-latest
|
|
293
|
+
steps:
|
|
294
|
+
- name: Deploy to Kubernetes
|
|
295
|
+
run: kubectl apply -f k8s/deployment.yaml
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
**Maps to:**
|
|
299
|
+
|
|
300
|
+
- TechnologyProcess: "CI/CD Pipeline" (pattern: ci-cd, automation: github-actions)
|
|
301
|
+
- Sub-processes: "Build", "Deploy"
|
|
302
|
+
- TechnologyFunction: "Docker Build", "Kubernetes Deploy"
|
|
303
|
+
- Artifact: "Docker Image" (type: docker-image)
|
|
304
|
+
|
|
305
|
+
### Pattern 6: Load Balancer Configuration
|
|
306
|
+
|
|
307
|
+
```nginx
|
|
308
|
+
# NGINX load balancer
|
|
309
|
+
upstream backend {
|
|
310
|
+
least_conn;
|
|
311
|
+
server app1.example.com:8080 weight=1;
|
|
312
|
+
server app2.example.com:8080 weight=1;
|
|
313
|
+
server app3.example.com:8080 weight=1;
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
server {
|
|
317
|
+
listen 443 ssl;
|
|
318
|
+
server_name api.example.com;
|
|
319
|
+
|
|
320
|
+
ssl_certificate /etc/nginx/ssl/cert.pem;
|
|
321
|
+
ssl_certificate_key /etc/nginx/ssl/key.pem;
|
|
322
|
+
|
|
323
|
+
location / {
|
|
324
|
+
proxy_pass http://backend;
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
```
|
|
328
|
+
|
|
329
|
+
**Maps to:**
|
|
330
|
+
|
|
331
|
+
- Node: "NGINX Load Balancer" (type: server)
|
|
332
|
+
- SystemSoftware: "NGINX" (type: web-server, subtype: load-balancer)
|
|
333
|
+
- TechnologyFunction: "Load Balancing" (strategy: least-conn)
|
|
334
|
+
- TechnologyInterface: "HTTPS Endpoint" (protocol: HTTPS, port: 443)
|
|
335
|
+
- TechnologyCollaboration: "Backend Pool" (aggregates app1, app2, app3)
|
|
336
|
+
|
|
337
|
+
---
|
|
338
|
+
|
|
339
|
+
## Modeling Workflow
|
|
340
|
+
|
|
341
|
+
### Step 1: Identify Infrastructure Nodes
|
|
342
|
+
|
|
343
|
+
```bash
|
|
344
|
+
# Kubernetes cluster
|
|
345
|
+
dr add technology node "k8s-cluster-prod" \
|
|
346
|
+
--properties type=kubernetes-cluster,provider=aws,region=us-east-1,version=1.28 \
|
|
347
|
+
--description "Production Kubernetes cluster"
|
|
348
|
+
|
|
349
|
+
# Virtual machines
|
|
350
|
+
dr add technology node "web-server-01" \
|
|
351
|
+
--properties type=vm,provider=aws,instance-type=t3.large,az=us-east-1a \
|
|
352
|
+
--description "Web application server VM"
|
|
353
|
+
|
|
354
|
+
# Serverless function
|
|
355
|
+
dr add technology node "order-processor-lambda" \
|
|
356
|
+
--properties type=serverless-function,provider=aws,runtime=node.11,memory=512 \
|
|
357
|
+
--description "Lambda function for order processing"
|
|
358
|
+
|
|
359
|
+
# Database cluster
|
|
360
|
+
dr add technology node "postgres-cluster" \
|
|
361
|
+
--properties type=database-cluster,provider=aws,instance-class=db.r5.xlarge \
|
|
362
|
+
--description "PostgreSQL RDS cluster"
|
|
363
|
+
```
|
|
364
|
+
|
|
365
|
+
### Step 2: Define System Software
|
|
366
|
+
|
|
367
|
+
```bash
|
|
368
|
+
# Database system
|
|
369
|
+
dr add technology system-software "postgresql-14" \
|
|
370
|
+
--properties type=database,version=14.7,license=open-source \
|
|
371
|
+
--description "PostgreSQL relational database"
|
|
372
|
+
|
|
373
|
+
# Container runtime
|
|
374
|
+
dr add technology system-software "docker" \
|
|
375
|
+
--properties type=container-runtime,version=24.0.5 \
|
|
376
|
+
--description "Docker container runtime"
|
|
377
|
+
|
|
378
|
+
# Web server
|
|
379
|
+
dr add technology system-software "nginx" \
|
|
380
|
+
--properties type=web-server,version=1.24.0,subtype=load-balancer \
|
|
381
|
+
--description "NGINX web server and load balancer"
|
|
382
|
+
|
|
383
|
+
# Message broker
|
|
384
|
+
dr add technology system-software "rabbitmq" \
|
|
385
|
+
--properties type=message-broker,version=3.12.0,protocol=AMQP \
|
|
386
|
+
--description "RabbitMQ message broker"
|
|
387
|
+
```
|
|
388
|
+
|
|
389
|
+
### Step 3: Model Technology Services
|
|
390
|
+
|
|
391
|
+
```bash
|
|
392
|
+
# Infrastructure service
|
|
393
|
+
dr add technology service "kubernetes-orchestration" \
|
|
394
|
+
--properties type=platform,sla-availability=99.95% \
|
|
395
|
+
--description "Container orchestration platform"
|
|
396
|
+
|
|
397
|
+
# Database service
|
|
398
|
+
dr add technology service "postgres-database" \
|
|
399
|
+
--properties type=database,sla-availability=99.9%,sla-latency=10ms \
|
|
400
|
+
--description "PostgreSQL database service"
|
|
401
|
+
|
|
402
|
+
# Storage service
|
|
403
|
+
dr add technology service "s3-object-storage" \
|
|
404
|
+
--properties type=storage,provider=aws,storage-class=standard \
|
|
405
|
+
--description "S3 object storage for files and backups"
|
|
406
|
+
|
|
407
|
+
# Link software to service
|
|
408
|
+
dr relationship add "technology/system-software/postgresql-14" \
|
|
409
|
+
realizes "technology/service/postgres-database"
|
|
410
|
+
```
|
|
411
|
+
|
|
412
|
+
### Step 4: Define Communication Networks
|
|
413
|
+
|
|
414
|
+
```bash
|
|
415
|
+
# VPC network
|
|
416
|
+
dr add technology network "production-vpc" \
|
|
417
|
+
--properties type=lan,provider=aws,cidr=10.0.0.0/16,region=us-east-1 \
|
|
418
|
+
--description "Production VPC network"
|
|
419
|
+
|
|
420
|
+
# Subnet
|
|
421
|
+
dr add technology network "private-subnet-1a" \
|
|
422
|
+
--properties type=lan,cidr=10.0.1.0/24,az=us-east-1a,visibility=private \
|
|
423
|
+
--description "Private subnet in AZ 1a"
|
|
424
|
+
|
|
425
|
+
# VPN
|
|
426
|
+
dr add technology network "site-to-site-vpn" \
|
|
427
|
+
--properties type=vpn,encryption=ipsec,bandwidth=1gbps \
|
|
428
|
+
--description "Site-to-site VPN to on-premise datacenter"
|
|
429
|
+
```
|
|
430
|
+
|
|
431
|
+
### Step 5: Model Artifacts
|
|
432
|
+
|
|
433
|
+
```bash
|
|
434
|
+
# Database artifact
|
|
435
|
+
dr add technology artifact "customer-database" \
|
|
436
|
+
--properties type=database,size=500GB,encryption=aes-256,classification=confidential \
|
|
437
|
+
--description "Customer data database"
|
|
438
|
+
|
|
439
|
+
# Docker image
|
|
440
|
+
dr add technology artifact "user-service-image" \
|
|
441
|
+
--properties type=docker-image,registry=ecr.aws,tag=v1.2.3 \
|
|
442
|
+
--description "User service Docker image"
|
|
443
|
+
|
|
444
|
+
# Configuration file
|
|
445
|
+
dr add technology artifact "app-config" \
|
|
446
|
+
--properties type=configuration,format=yaml,version-controlled=true \
|
|
447
|
+
--description "Application configuration file"
|
|
448
|
+
|
|
449
|
+
# Log files
|
|
450
|
+
dr add technology artifact "application-logs" \
|
|
451
|
+
--properties type=log,retention-period=90d,compression=gzip \
|
|
452
|
+
--description "Application log files"
|
|
453
|
+
|
|
454
|
+
# Link artifact to node
|
|
455
|
+
dr relationship add "technology/node/postgres-cluster" \
|
|
456
|
+
stores "technology/artifact/customer-database"
|
|
457
|
+
```
|
|
458
|
+
|
|
459
|
+
### Step 6: Model Infrastructure as Code
|
|
460
|
+
|
|
461
|
+
```bash
|
|
462
|
+
# Terraform process
|
|
463
|
+
dr add technology process "provision-infrastructure" \
|
|
464
|
+
--properties pattern=infrastructure-as-code,automation=terraform,repo=github.com/org/infra \
|
|
465
|
+
--description "Terraform infrastructure provisioning"
|
|
466
|
+
|
|
467
|
+
# Ansible process
|
|
468
|
+
dr add technology process "configure-servers" \
|
|
469
|
+
--properties pattern=configuration-management,automation=ansible,playbook=server-config.yml \
|
|
470
|
+
--description "Ansible server configuration"
|
|
471
|
+
|
|
472
|
+
# Kubernetes deployment process
|
|
473
|
+
dr add technology process "deploy-to-k8s" \
|
|
474
|
+
--properties pattern=continuous-deployment,automation=kubectl,manifest=k8s/deploy.yaml \
|
|
475
|
+
--description "Deploy application to Kubernetes"
|
|
476
|
+
```
|
|
477
|
+
|
|
478
|
+
### Step 7: Define Technology Functions
|
|
479
|
+
|
|
480
|
+
```bash
|
|
481
|
+
# Load balancing
|
|
482
|
+
dr add technology function "load-balancing" \
|
|
483
|
+
--properties strategy=least-conn,health-check-interval=10s \
|
|
484
|
+
--description "Distribute traffic across backend servers"
|
|
485
|
+
|
|
486
|
+
# Auto-scaling
|
|
487
|
+
dr add technology function "auto-scaling" \
|
|
488
|
+
--properties min-replicas=2,max-replicas=10,cpu-threshold=70% \
|
|
489
|
+
--description "Automatically scale based on CPU utilization"
|
|
490
|
+
|
|
491
|
+
# Backup
|
|
492
|
+
dr add technology function "database-backup" \
|
|
493
|
+
--properties frequency=daily,retention=30d,type=incremental \
|
|
494
|
+
--description "Automated database backup"
|
|
495
|
+
|
|
496
|
+
# Assign function to node
|
|
497
|
+
dr relationship add "technology/node/k8s-cluster-prod" \
|
|
498
|
+
assigned-to "technology/function/auto-scaling"
|
|
499
|
+
```
|
|
500
|
+
|
|
501
|
+
### Step 8: Cross-Layer Integration
|
|
502
|
+
|
|
503
|
+
```bash
|
|
504
|
+
# Link to application layer
|
|
505
|
+
dr relationship add "technology/node/k8s-cluster-prod" \
|
|
506
|
+
hosts "application/component/user-service"
|
|
507
|
+
|
|
508
|
+
# Link to motivation layer
|
|
509
|
+
dr relationship add "technology/service/kubernetes-orchestration" \
|
|
510
|
+
supports "motivation/goal/improve-deployment-frequency"
|
|
511
|
+
|
|
512
|
+
dr relationship add "technology/node/k8s-cluster-prod" \
|
|
513
|
+
governed-by "motivation/principle/cloud-native-architecture"
|
|
514
|
+
|
|
515
|
+
# Link to APM layer
|
|
516
|
+
dr relationship add "technology/service/postgres-database" \
|
|
517
|
+
monitored-by "apm/metric/database-query-latency"
|
|
518
|
+
```
|
|
519
|
+
|
|
520
|
+
### Step 9: Validate
|
|
521
|
+
|
|
522
|
+
```bash
|
|
523
|
+
dr validate --layer technology
|
|
524
|
+
dr validate --validate-relationships
|
|
525
|
+
```
|
|
526
|
+
|
|
527
|
+
---
|
|
528
|
+
|
|
529
|
+
## Cloud Provider Patterns
|
|
530
|
+
|
|
531
|
+
### AWS Pattern
|
|
532
|
+
|
|
533
|
+
```
|
|
534
|
+
TechnologyCollaboration: "AWS Production Environment"
|
|
535
|
+
├── contains → Node: "EKS Cluster" (provider: aws, region: us-east-1)
|
|
536
|
+
│ ├── hosts → ApplicationComponent: "Microservices"
|
|
537
|
+
│ └── uses → TechnologyService: "EKS Orchestration"
|
|
538
|
+
├── contains → Node: "RDS PostgreSQL" (provider: aws, multi-az: true)
|
|
539
|
+
│ └── realizes → TechnologyService: "Database Service"
|
|
540
|
+
├── contains → Artifact: "S3 Bucket" (provider: aws, storage-class: standard)
|
|
541
|
+
└── contains → CommunicationNetwork: "VPC" (cidr: 10.0.0.0/16)
|
|
542
|
+
├── contains → Subnet: "Public Subnet" (cidr: 10.0.1.0/24)
|
|
543
|
+
└── contains → Subnet: "Private Subnet" (cidr: 10.0.2.0/24)
|
|
544
|
+
```
|
|
545
|
+
|
|
546
|
+
### Kubernetes Pattern
|
|
547
|
+
|
|
548
|
+
```
|
|
549
|
+
Node: "Kubernetes Cluster"
|
|
550
|
+
├── type: kubernetes-cluster
|
|
551
|
+
├── hosts → Node: "Namespace: production"
|
|
552
|
+
│ ├── hosts → Node: "Deployment: user-service"
|
|
553
|
+
│ │ ├── replicas: 3
|
|
554
|
+
│ │ └── hosts → Node: "Pod: user-service-xyz"
|
|
555
|
+
│ │ └── hosts → ApplicationComponent: "UserService"
|
|
556
|
+
│ └── uses → Artifact: "ConfigMap: app-config"
|
|
557
|
+
└── uses → TechnologyFunction: "Auto-scaling" (HPA)
|
|
558
|
+
```
|
|
559
|
+
|
|
560
|
+
### Hybrid Cloud Pattern
|
|
561
|
+
|
|
562
|
+
```
|
|
563
|
+
TechnologyCollaboration: "Hybrid Cloud Architecture"
|
|
564
|
+
├── contains → Node: "AWS EKS Cluster" (provider: aws)
|
|
565
|
+
├── contains → Node: "On-Premise K8s" (provider: onprem)
|
|
566
|
+
├── connected-by → Path: "Direct Connect" (type: direct-connect)
|
|
567
|
+
└── secured-by → CommunicationNetwork: "Zero-Trust Network"
|
|
568
|
+
```
|
|
569
|
+
|
|
570
|
+
---
|
|
571
|
+
|
|
572
|
+
## Best Practices
|
|
573
|
+
|
|
574
|
+
1. **Node Types Matter** - server vs container vs serverless have different operational characteristics
|
|
575
|
+
2. **Track IaC References** - Link to Terraform, Ansible, Kubernetes manifests
|
|
576
|
+
3. **Model HA Clusters** - Use TechnologyCollaboration for high-availability setups
|
|
577
|
+
4. **Network Segmentation** - Model VPCs, subnets, security zones explicitly
|
|
578
|
+
5. **Artifact Encryption** - Mark encryption status (at-rest, in-transit, both)
|
|
579
|
+
6. **Version Everything** - Track software versions, image tags, schema versions
|
|
580
|
+
7. **Link to Motivation** - Infrastructure choices trace to principles and constraints
|
|
581
|
+
8. **Monitor SLAs** - Technology services have availability and latency targets
|
|
582
|
+
9. **Document Automation** - Reference IaC tools and CI/CD pipelines
|
|
583
|
+
10. **Cloud-Agnostic When Possible** - Use ArchiMate types rather than provider-specific terms
|
|
584
|
+
|
|
585
|
+
---
|
|
586
|
+
|
|
587
|
+
## Infrastructure as Code Integration
|
|
588
|
+
|
|
589
|
+
When infrastructure is managed as code:
|
|
590
|
+
|
|
591
|
+
```yaml
|
|
592
|
+
technology-node:
|
|
593
|
+
id: "k8s-cluster-prod"
|
|
594
|
+
type: "kubernetes-cluster"
|
|
595
|
+
properties:
|
|
596
|
+
iac-tool: "terraform"
|
|
597
|
+
iac-file: "infrastructure/eks-cluster.tf"
|
|
598
|
+
iac-module: "eks-cluster"
|
|
599
|
+
iac-version: "4.0.0"
|
|
600
|
+
provider: "aws"
|
|
601
|
+
region: "us-east-1"
|
|
602
|
+
```
|
|
603
|
+
|
|
604
|
+
**IaC Tools Supported:**
|
|
605
|
+
|
|
606
|
+
- **Terraform** - Declarative infrastructure
|
|
607
|
+
- **Ansible** - Configuration management
|
|
608
|
+
- **Kubernetes** - Container orchestration manifests
|
|
609
|
+
- **CloudFormation** - AWS-specific IaC
|
|
610
|
+
- **Pulumi** - Programming language IaC
|
|
611
|
+
- **Helm** - Kubernetes package manager
|
|
612
|
+
|
|
613
|
+
---
|
|
614
|
+
|
|
615
|
+
## Validation Tips
|
|
616
|
+
|
|
617
|
+
| Issue | Cause | Fix |
|
|
618
|
+
| ---------------------- | --------------------------------------------------- | -------------------------------------- |
|
|
619
|
+
| Orphaned Node | Node not hosting applications or realizing services | Link to application layer or remove |
|
|
620
|
+
| Unhosted Application | ApplicationComponent not deployed to any node | Add deployment link to technology node |
|
|
621
|
+
| Missing Networks | Nodes exist but no network connectivity | Model CommunicationNetwork and Paths |
|
|
622
|
+
| Untracked Artifacts | Databases, images, configs not modeled | Add Artifact entities |
|
|
623
|
+
| No IaC Reference | Infrastructure lacks automation reference | Add iac-tool and iac-file properties |
|
|
624
|
+
| Missing SLA Targets | Services lack availability/latency targets | Add SLA properties for monitoring |
|
|
625
|
+
| No Security Properties | Artifacts lack encryption/classification | Add security properties |
|
|
626
|
+
|
|
627
|
+
---
|
|
628
|
+
|
|
629
|
+
## Quick Reference
|
|
630
|
+
|
|
631
|
+
**Add Commands:**
|
|
632
|
+
|
|
633
|
+
```bash
|
|
634
|
+
dr add technology node <name> --properties type=<type>,provider=<provider>
|
|
635
|
+
dr add technology system-software <name> --properties type=<type>,version=<version>
|
|
636
|
+
dr add technology service <name> --properties type=<type>,sla-availability=<value>
|
|
637
|
+
dr add technology network <name> --properties type=<type>,cidr=<cidr>
|
|
638
|
+
dr add technology artifact <name> --properties type=<type>,encryption=<encryption>
|
|
639
|
+
dr add technology function <name> --properties strategy=<strategy>
|
|
640
|
+
dr add technology process <name> --properties automation=<tool>
|
|
641
|
+
```
|
|
642
|
+
|
|
643
|
+
**Relationship Commands:**
|
|
644
|
+
|
|
645
|
+
```bash
|
|
646
|
+
dr relationship add <node> hosts <application-component>
|
|
647
|
+
dr relationship add <system-software> realizes <service>
|
|
648
|
+
dr relationship add <node> assigned-to <function>
|
|
649
|
+
dr relationship add <node> stores <artifact>
|
|
650
|
+
dr relationship add <network> connects <node>
|
|
651
|
+
```
|
|
652
|
+
|
|
653
|
+
**Cross-Layer Commands:**
|
|
654
|
+
|
|
655
|
+
```bash
|
|
656
|
+
dr relationship add technology/<node> hosts application/<component>
|
|
657
|
+
dr relationship add technology/<service> supports motivation/<goal>
|
|
658
|
+
dr relationship add technology/<node> governed-by motivation/<principle>
|
|
659
|
+
dr relationship add technology/<service> monitored-by apm/<metric>
|
|
660
|
+
```
|