archsight 0.3.2 → 0.4.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.
- checksums.yaml +4 -4
- data/README.md +7 -1
- data/docs/archimate.md +21 -1
- data/docs/configuration.md +1 -0
- data/docs/diagram.md +15 -3
- data/docs/docker.md +4 -1
- data/docs/icons.md +32 -0
- data/docs/import.md +178 -55
- data/docs/index.md.erb +31 -8
- data/docs/modeling.md +772 -24
- data/docs/pages.md +44 -13
- data/docs/search.md +21 -1
- data/docs/togaf.md +5 -1
- data/lib/archsight/analysis/result.rb +8 -2
- data/lib/archsight/analysis/sandbox.rb +8 -0
- data/lib/archsight/analysis/typst_renderer.rb +246 -0
- data/lib/archsight/analysis.rb +1 -0
- data/lib/archsight/annotations/annotation.rb +30 -3
- data/lib/archsight/annotations/architecture_annotations.rb +47 -0
- data/lib/archsight/annotations/asset_annotations.rb +34 -0
- data/lib/archsight/annotations/link_annotations.rb +15 -0
- data/lib/archsight/annotations/resource_reference.rb +12 -0
- data/lib/archsight/annotations/risk_annotations.rb +21 -0
- data/lib/archsight/cli.rb +124 -23
- data/lib/archsight/database.rb +40 -0
- data/lib/archsight/diagram/cli.rb +50 -2
- data/lib/archsight/diagram/formatter.rb +112 -0
- data/lib/archsight/diagram/routing/edge_router/orthogonal_path.rb +38 -10
- data/lib/archsight/diagram/routing/edge_router.rb +29 -4
- data/lib/archsight/diagram/routing/edge_routing.rb +61 -5
- data/lib/archsight/diagram/style/theme.rb +7 -2
- data/lib/archsight/documentation.rb +3 -2
- data/lib/archsight/editor/page_source.rb +13 -1
- data/lib/archsight/export/confluence/analysis_output.rb +101 -0
- data/lib/archsight/export/confluence/client.rb +13 -0
- data/lib/archsight/export/confluence/diagram_links.rb +1 -1
- data/lib/archsight/export/confluence/exporter.rb +40 -13
- data/lib/archsight/export/confluence/labels.rb +25 -0
- data/lib/archsight/export/confluence/page_properties.rb +4 -6
- data/lib/archsight/export/confluence/storage.rb +38 -2
- data/lib/archsight/helpers/embeds.rb +18 -7
- data/lib/archsight/helpers/resource_resolver.rb +25 -0
- data/lib/archsight/import/executor.rb +139 -16
- data/lib/archsight/import/handler.rb +55 -6
- data/lib/archsight/import/handler_loader.rb +64 -0
- data/lib/archsight/import/handlers/cache_pruner.rb +30 -7
- data/lib/archsight/import/handlers/command.rb +120 -0
- data/lib/archsight/import/handlers/github.rb +4 -1
- data/lib/archsight/import/handlers/gitlab.rb +4 -1
- data/lib/archsight/import/handlers/go_dep_resolver.rb +10 -2
- data/lib/archsight/import/handlers/go_grapher.rb +102 -5
- data/lib/archsight/import/handlers/go_module_parser.rb +88 -0
- data/lib/archsight/import/handlers/grapher.rb +40 -1
- data/lib/archsight/import/handlers/repository.rb +3 -0
- data/lib/archsight/import/handlers/rest_api_index.rb +3 -0
- data/lib/archsight/import/registry.rb +22 -1
- data/lib/archsight/import.rb +64 -1
- data/lib/archsight/linter/structure.rb +239 -0
- data/lib/archsight/linter.rb +217 -6
- data/lib/archsight/page_loader.rb +12 -1
- data/lib/archsight/query/evaluator.rb +13 -6
- data/lib/archsight/query/parser.rb +73 -6
- data/lib/archsight/query.rb +1 -1
- data/lib/archsight/references.rb +3 -3
- data/lib/archsight/renderer.rb +80 -23
- data/lib/archsight/resources/analysis.rb +3 -2
- data/lib/archsight/resources/application_component.rb +83 -8
- data/lib/archsight/resources/application_event.rb +79 -0
- data/lib/archsight/resources/application_service.rb +18 -2
- data/lib/archsight/resources/base.rb +58 -5
- data/lib/archsight/resources/business_actor.rb +14 -1
- data/lib/archsight/resources/business_contract.rb +72 -0
- data/lib/archsight/resources/business_control.rb +10 -2
- data/lib/archsight/resources/business_event.rb +79 -0
- data/lib/archsight/resources/business_process.rb +8 -1
- data/lib/archsight/resources/business_product.rb +12 -0
- data/lib/archsight/resources/business_role.rb +70 -0
- data/lib/archsight/resources/compliance_evidence.rb +8 -2
- data/lib/archsight/resources/data_object.rb +6 -1
- data/lib/archsight/resources/implementation_deliverable.rb +63 -0
- data/lib/archsight/resources/implementation_event.rb +52 -0
- data/lib/archsight/resources/implementation_gap.rb +49 -0
- data/lib/archsight/resources/implementation_plateau.rb +67 -0
- data/lib/archsight/resources/implementation_work_package.rb +84 -0
- data/lib/archsight/resources/import.rb +37 -11
- data/lib/archsight/resources/location.rb +56 -0
- data/lib/archsight/resources/motivation_assessment.rb +121 -0
- data/lib/archsight/resources/motivation_constraint.rb +7 -1
- data/lib/archsight/resources/motivation_driver.rb +50 -0
- data/lib/archsight/resources/motivation_goal.rb +13 -1
- data/lib/archsight/resources/motivation_principle.rb +75 -0
- data/lib/archsight/resources/motivation_requirement.rb +18 -2
- data/lib/archsight/resources/motivation_stakeholder.rb +21 -0
- data/lib/archsight/resources/page.rb +9 -7
- data/lib/archsight/resources/strategy_capability.rb +9 -0
- data/lib/archsight/resources/technology_artifact.rb +11 -4
- data/lib/archsight/resources/technology_communication_network.rb +89 -0
- data/lib/archsight/resources/technology_device.rb +88 -0
- data/lib/archsight/resources/technology_equipment.rb +75 -0
- data/lib/archsight/resources/technology_event.rb +80 -0
- data/lib/archsight/resources/technology_facility.rb +70 -0
- data/lib/archsight/resources/technology_node.rb +57 -1
- data/lib/archsight/resources/technology_service.rb +33 -0
- data/lib/archsight/resources/technology_system_software.rb +28 -0
- data/lib/archsight/resources.rb +12 -0
- data/lib/archsight/version.rb +1 -1
- data/lib/archsight/web/api/analysis_helpers.rb +55 -0
- data/lib/archsight/web/api/json_helpers.rb +3 -37
- data/lib/archsight/web/api/openapi/spec.yaml +10 -8
- data/lib/archsight/web/api/page_helpers.rb +1 -8
- data/lib/archsight/web/api/routes.rb +7 -2
- data/lib/archsight/web/application.rb +38 -2
- data/lib/archsight/web/editor/routes.rb +2 -1
- data/lib/archsight/web/public/vue/ApiDocsPage-COp4onwn.js +1 -0
- data/lib/archsight/web/public/vue/DocPage-D52OwaKc.js +1 -0
- data/lib/archsight/web/public/vue/EditorPage-3aqL7yVf.js +35 -0
- data/lib/archsight/web/public/vue/ErrorPage--b9XeSYa.js +2 -0
- data/lib/archsight/web/public/vue/GraphView-qh_EtRrQ.js +1 -0
- data/lib/archsight/web/public/vue/HomePage-C2TNh2U-.js +2 -0
- data/lib/archsight/web/public/vue/InstanceRouter-ZaCcjlIX.css +1 -0
- data/lib/archsight/web/public/vue/InstanceRouter-uzb_OMG0.js +1 -0
- data/lib/archsight/web/public/vue/KindList-CyJuP_uq.js +1 -0
- data/lib/archsight/web/public/vue/KindList-yYcRT2BV.css +1 -0
- data/lib/archsight/web/public/vue/PageView-B93woeN3.css +1 -0
- data/lib/archsight/web/public/vue/PageView-FyygrS-b.js +1 -0
- data/lib/archsight/web/public/vue/QueryError-B4Ex_csZ.js +1 -0
- data/lib/archsight/web/public/vue/ResourceList-BY6Z1Kcb.js +2 -0
- data/lib/archsight/web/public/vue/ResourceList-D75O87zG.css +1 -0
- data/lib/archsight/web/public/vue/{SearchResults-CyPUZZSC.css → SearchResults-BV6UHriJ.css} +1 -1
- data/lib/archsight/web/public/vue/SearchResults-CkFpHF8m.js +1 -0
- data/lib/archsight/web/public/vue/WikiPage-BoHNewCX.js +3 -0
- data/lib/archsight/web/public/vue/WikiPage-TpmM1VAF.css +1 -0
- data/lib/archsight/web/public/vue/architecture-7GRP2DOG-BvzKZE4e.js +1 -0
- data/lib/archsight/web/public/vue/cynefin-OW5HDTMX-D-xs_Hxh.js +1 -0
- data/lib/archsight/web/public/vue/eventmodeling-NTZA5JFV-nbjxG01S.js +1 -0
- data/lib/archsight/web/public/vue/gitGraph-4MIJSDKK-CW6mw2ab.js +1 -0
- data/lib/archsight/web/public/vue/index-BGlYCbi7.js +3 -0
- data/lib/archsight/web/public/vue/index-eUHmJ7K2.css +1 -0
- data/lib/archsight/web/public/vue/info-A6RAGUB7-C12sjlHe.js +1 -0
- data/lib/archsight/web/public/vue/{mermaid-BjEi5URd.js → mermaid-DjsXQ_XN.js} +35 -35
- data/lib/archsight/web/public/vue/packet-AYTQ26CC-wMwKwHmA.js +1 -0
- data/lib/archsight/web/public/vue/pie-WAS4IAKB-w1-sAU_K.js +1 -0
- data/lib/archsight/web/public/vue/radar-RG4KPBEZ-DpwqIFoy.js +1 -0
- data/lib/archsight/web/public/vue/railroad-74A4TZTK-Ce5XC24d.js +1 -0
- data/lib/archsight/web/public/vue/railroad-abnf-HS5TGJTU-BSQO2pds.js +1 -0
- data/lib/archsight/web/public/vue/railroad-ebnf-LZEXJU2U-Dq1c2YtD.js +1 -0
- data/lib/archsight/web/public/vue/railroad-peg-WCYAUIDC-DKj6dli0.js +1 -0
- data/lib/archsight/web/public/vue/rolldown-runtime-hePW80VL.js +1 -0
- data/lib/archsight/web/public/vue/treeView-Q6P3EWNA-BmHNTWxU.js +1 -0
- data/lib/archsight/web/public/vue/treemap-WGGIJYW6-DsEI7sSD.js +1 -0
- data/lib/archsight/web/public/vue/{useGraphviz-DweKV7Kg.js → useGraphviz-4evusK9i.js} +13 -1
- data/lib/archsight/web/public/vue/{useHighlight-D5Gf8DLl.js → useHighlight-DPguaxfm.js} +8 -8
- data/lib/archsight/web/public/vue/usePanZoom-seQE1TPk.js +12 -0
- data/lib/archsight/web/public/vue/wardley-WFR3VGLG-CSCW83-M.js +1 -0
- data/lib/archsight/web/public/vue.html +5 -5
- metadata +72 -38
- data/lib/archsight/web/public/vue/ApiDocsPage-DoOxKjG0.js +0 -1
- data/lib/archsight/web/public/vue/DocPage-CfsC3CeQ.js +0 -1
- data/lib/archsight/web/public/vue/EditorPage-CsJA0q8n.js +0 -35
- data/lib/archsight/web/public/vue/ErrorPage-OJpJz9df.js +0 -2
- data/lib/archsight/web/public/vue/GraphView-CBq6oFRV.js +0 -1
- data/lib/archsight/web/public/vue/HomePage-BwgMLgVC.js +0 -2
- data/lib/archsight/web/public/vue/InstanceRouter-DQz-SsQq.js +0 -1
- data/lib/archsight/web/public/vue/InstanceRouter-jeavM6PW.css +0 -1
- data/lib/archsight/web/public/vue/KindList-4q0K9Cll.js +0 -1
- data/lib/archsight/web/public/vue/PageView-DzeGnvoS.js +0 -1
- data/lib/archsight/web/public/vue/QueryError-kg6Yf-pW.js +0 -1
- data/lib/archsight/web/public/vue/ResourceList-B0FLaFR3.css +0 -1
- data/lib/archsight/web/public/vue/ResourceList-Df_0e0qt.js +0 -2
- data/lib/archsight/web/public/vue/SearchResults-CKgY6_wH.js +0 -1
- data/lib/archsight/web/public/vue/WikiPage-DoFJ0dbW.css +0 -1
- data/lib/archsight/web/public/vue/WikiPage-DrvCHwJ7.js +0 -13
- data/lib/archsight/web/public/vue/architecture-7GRP2DOG-BfA1TPxQ.js +0 -1
- data/lib/archsight/web/public/vue/cynefin-OW5HDTMX-BmgdUKVD.js +0 -1
- data/lib/archsight/web/public/vue/eventmodeling-NTZA5JFV-DbXDvAWF.js +0 -1
- data/lib/archsight/web/public/vue/gitGraph-4MIJSDKK-BkVhrKS1.js +0 -1
- data/lib/archsight/web/public/vue/index-D0Q5GZRs.js +0 -3
- data/lib/archsight/web/public/vue/index-oF-iyZvk.css +0 -1
- data/lib/archsight/web/public/vue/info-A6RAGUB7-BIlCVuUY.js +0 -1
- data/lib/archsight/web/public/vue/packet-AYTQ26CC-eoQTjY3j.js +0 -1
- data/lib/archsight/web/public/vue/pie-WAS4IAKB-DEOotGhh.js +0 -1
- data/lib/archsight/web/public/vue/radar-RG4KPBEZ-C2yucuUN.js +0 -1
- data/lib/archsight/web/public/vue/railroad-74A4TZTK-CzONK5VY.js +0 -1
- data/lib/archsight/web/public/vue/railroad-abnf-HS5TGJTU-9zRPsDsx.js +0 -1
- data/lib/archsight/web/public/vue/railroad-ebnf-LZEXJU2U-BJ4dkz9l.js +0 -1
- data/lib/archsight/web/public/vue/railroad-peg-WCYAUIDC-DFy_rqAj.js +0 -1
- data/lib/archsight/web/public/vue/treeView-Q6P3EWNA-2cq5CyD2.js +0 -1
- data/lib/archsight/web/public/vue/treemap-WGGIJYW6-DK-e9Ez4.js +0 -1
- data/lib/archsight/web/public/vue/wardley-WFR3VGLG-BQwqUqfB.js +0 -1
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# TechnologyCommunicationNetwork represents a logical network that connects nodes and system software
|
|
4
|
+
class Archsight::Resources::TechnologyCommunicationNetwork < Archsight::Resources::Base
|
|
5
|
+
include_annotations :git, :architecture
|
|
6
|
+
|
|
7
|
+
description <<~MD
|
|
8
|
+
Represents a logical network: a management network, the public network, an overlay such as BGP-EVPN, a VPN or a
|
|
9
|
+
network that supports a metro region.
|
|
10
|
+
|
|
11
|
+
## ArchiMate Definition
|
|
12
|
+
|
|
13
|
+
**Layer:** Technology
|
|
14
|
+
**Aspect:** Active Structure
|
|
15
|
+
|
|
16
|
+
A communication network is a set of structures and behaviors that connects devices or system software for
|
|
17
|
+
transmission, routing and reception of data.
|
|
18
|
+
|
|
19
|
+
## Usage
|
|
20
|
+
|
|
21
|
+
Use TechnologyCommunicationNetwork to represent:
|
|
22
|
+
|
|
23
|
+
- Underlay networks (the routed fabric) and overlay networks that run on them (BGP-EVPN, VXLAN)
|
|
24
|
+
- Management, storage and public networks
|
|
25
|
+
- VPNs and mesh networks (one network with `network/topology: mesh`, not one element per pair of sites)
|
|
26
|
+
- Networks that support a metro region, made of the networks of its sites
|
|
27
|
+
|
|
28
|
+
Do not model a network per customer or tenant: the overlay is one network, its tenants are instances of it.
|
|
29
|
+
Physical links and fabrics are `TechnologyEquipment`.
|
|
30
|
+
|
|
31
|
+
## Not this kind
|
|
32
|
+
|
|
33
|
+
- Cables, fibre routes and switch fabrics are `TechnologyEquipment`; the network is `realizedBy` them
|
|
34
|
+
- The routing or VPN software is `TechnologySystemSoftware` that realizes the network
|
|
35
|
+
- A network offered as a product to consumers can additionally be a `TechnologyService` realized by it
|
|
36
|
+
- No network per tenant, no element per pair of sites in a mesh
|
|
37
|
+
|
|
38
|
+
Which kind to pick: "Choosing the Kind: Infrastructure" in the modeling guide.
|
|
39
|
+
|
|
40
|
+
## How it connects
|
|
41
|
+
|
|
42
|
+
- A network is `composedOf` other networks (a metro network of its site networks); the target must be a network
|
|
43
|
+
and the chain must not form a cycle
|
|
44
|
+
- A network `specializes` a more general network (the concept "management network" and its implementations)
|
|
45
|
+
- A network is `servedBy` the network it runs over: the underlay serves the overlay, a VPN is served by the
|
|
46
|
+
network it tunnels through
|
|
47
|
+
- A network is `locatedAt` the facilities and locations it spans, many of them for one network
|
|
48
|
+
- A network is `realizedBy` the `TechnologyEquipment` it runs over and the `TechnologySystemSoftware` that implements it
|
|
49
|
+
(the routing stack, the VPN software)
|
|
50
|
+
- An overlay that software builds is `realizedBy` that `ApplicationComponent` or `ApplicationService` (an SDN agent,
|
|
51
|
+
a network operator, a load-balancer controller), also when the software runs on the nodes the network serves
|
|
52
|
+
- A `TechnologyNode` is `servedBy` the networks it is attached to; the network page lists them
|
|
53
|
+
- A network is `realizedBy` the `TechnologyDevice`s that build it (its switches and routers) and `connects` the
|
|
54
|
+
devices attached to it (servers, firewalls, appliances). Both are written on the network, so a switch that is
|
|
55
|
+
also attached to the network it builds closes no cycle
|
|
56
|
+
- A network is `ownedBy` the team (`BusinessActor`) or `BusinessRole` that operates it
|
|
57
|
+
MD
|
|
58
|
+
|
|
59
|
+
icon "network"
|
|
60
|
+
layer "technology"
|
|
61
|
+
|
|
62
|
+
annotation "network/type",
|
|
63
|
+
description: "Role of the network",
|
|
64
|
+
title: "Network Type",
|
|
65
|
+
enum: %w[underlay overlay management public vpn other],
|
|
66
|
+
filter: :word,
|
|
67
|
+
summary: true
|
|
68
|
+
|
|
69
|
+
annotation "network/topology",
|
|
70
|
+
description: "Shape of the network",
|
|
71
|
+
title: "Topology",
|
|
72
|
+
enum: %w[mesh hub-and-spoke point-to-point ring other],
|
|
73
|
+
filter: :word,
|
|
74
|
+
summary: true
|
|
75
|
+
|
|
76
|
+
relation :composedOf, :technologyCommunicationNetworks, :TechnologyCommunicationNetwork
|
|
77
|
+
relation :specializes, :technologyCommunicationNetworks, :TechnologyCommunicationNetwork
|
|
78
|
+
relation :servedBy, :technologyCommunicationNetworks, :TechnologyCommunicationNetwork
|
|
79
|
+
relation :locatedAt, :technologyFacilities, :TechnologyFacility
|
|
80
|
+
relation :locatedAt, :locations, :Location
|
|
81
|
+
relation :realizedBy, :technologyEquipment, :TechnologyEquipment
|
|
82
|
+
relation :realizedBy, :technologyDevices, :TechnologyDevice
|
|
83
|
+
relation :connects, :technologyDevices, :TechnologyDevice
|
|
84
|
+
relation :realizedBy, :technologySystemSoftware, :TechnologySystemSoftware
|
|
85
|
+
relation :realizedBy, :applicationComponents, :ApplicationComponent
|
|
86
|
+
relation :realizedBy, :applicationServices, :ApplicationService
|
|
87
|
+
relation :ownedBy, :businessActors, :BusinessActor
|
|
88
|
+
relation :ownedBy, :businessRoles, :BusinessRole
|
|
89
|
+
end
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# TechnologyDevice represents one physical machine: a server, switch, router, firewall or appliance
|
|
4
|
+
class Archsight::Resources::TechnologyDevice < Archsight::Resources::Base
|
|
5
|
+
include_annotations :git, :architecture, :asset, :risk
|
|
6
|
+
|
|
7
|
+
description <<~MD
|
|
8
|
+
Represents one physical machine: a server, a switch, a router, a firewall, a terminal server or an appliance.
|
|
9
|
+
|
|
10
|
+
## ArchiMate Definition
|
|
11
|
+
|
|
12
|
+
**Layer:** Technology
|
|
13
|
+
**Aspect:** Active Structure
|
|
14
|
+
|
|
15
|
+
A device is a physical IT resource upon which system software and artifacts may be stored or deployed for
|
|
16
|
+
execution. It is a specialization of a node.
|
|
17
|
+
|
|
18
|
+
## Usage
|
|
19
|
+
|
|
20
|
+
Use TechnologyDevice when the individual machine matters: which room it stands in, which switch it is cabled to,
|
|
21
|
+
which machines a failure domain loses.
|
|
22
|
+
|
|
23
|
+
- One element per physical machine (name it after the host: "Device:Frankfurt:Server01")
|
|
24
|
+
- A group of machines with one role ("the hypervisors of the platform") stays a logical `TechnologyNode` that is
|
|
25
|
+
`realizedBy` its devices
|
|
26
|
+
- A virtual chassis, a stack or a cluster pair is a device `composedOf` its member devices
|
|
27
|
+
|
|
28
|
+
## Not this kind
|
|
29
|
+
|
|
30
|
+
- A VM, a Kubernetes node or a host role is a `TechnologyNode`
|
|
31
|
+
- A rack, a fabric or a link between sites is `TechnologyEquipment` (a rack is `composedOf` its devices)
|
|
32
|
+
- The network a switch builds is a `TechnologyCommunicationNetwork` `realizedBy` the switch
|
|
33
|
+
|
|
34
|
+
Which kind to pick: "Choosing the Kind: Infrastructure" in the modeling guide.
|
|
35
|
+
|
|
36
|
+
## How it connects
|
|
37
|
+
|
|
38
|
+
- A device is `locatedAt` the `TechnologyFacility` it stands in, usually a room (`facility/type: room`)
|
|
39
|
+
- A device is `connectedTo` the devices it is cabled to (ArchiMate association). The cable is declared once, on
|
|
40
|
+
one of the two devices; the other shows it as incoming. Cabling is cyclic by nature and stays out of the
|
|
41
|
+
cycle check
|
|
42
|
+
- A device is `composedOf` its members (virtual chassis, stack)
|
|
43
|
+
- A `TechnologyNode` is `realizedBy` the devices it consists of
|
|
44
|
+
- A `TechnologyCommunicationNetwork` is `realizedBy` its switches and routers and `connects` the devices attached
|
|
45
|
+
to it
|
|
46
|
+
- `TechnologyEquipment` (a rack, a delivered hardware block) is `composedOf` its devices
|
|
47
|
+
- A device is `ownedBy` the team (`BusinessActor`) or `BusinessRole` responsible for operating it and `servedBy`
|
|
48
|
+
the team it is dedicated to (ArchiMate serving: a test server held by one team); `device/purpose` says what for
|
|
49
|
+
|
|
50
|
+
A device points to nothing above it: nodes, networks and equipment point down to the device, and the teams it
|
|
51
|
+
points to point to nothing further, so the relations stay free of cycles.
|
|
52
|
+
MD
|
|
53
|
+
|
|
54
|
+
icon "server"
|
|
55
|
+
layer "technology"
|
|
56
|
+
|
|
57
|
+
annotation "device/type",
|
|
58
|
+
description: "Kind of device",
|
|
59
|
+
title: "Device Type",
|
|
60
|
+
enum: %w[server switch router firewall terminal-server appliance other],
|
|
61
|
+
filter: :word,
|
|
62
|
+
summary: true
|
|
63
|
+
annotation "device/role",
|
|
64
|
+
description: "What the device does, e.g. hypervisor, storage, leaf, spine, core, management",
|
|
65
|
+
title: "Role",
|
|
66
|
+
filter: :word,
|
|
67
|
+
summary: true
|
|
68
|
+
annotation "device/model",
|
|
69
|
+
description: "Vendor and model",
|
|
70
|
+
title: "Model"
|
|
71
|
+
annotation "device/serial",
|
|
72
|
+
description: "Serial number",
|
|
73
|
+
title: "Serial"
|
|
74
|
+
annotation "device/rack",
|
|
75
|
+
description: "Rack and height units, e.g. B12 U20-21",
|
|
76
|
+
title: "Rack"
|
|
77
|
+
annotation "device/purpose",
|
|
78
|
+
description: "What the device is dedicated to, e.g. kernel regression tests",
|
|
79
|
+
title: "Purpose",
|
|
80
|
+
filter: :word
|
|
81
|
+
|
|
82
|
+
relation :locatedAt, :technologyFacilities, :TechnologyFacility
|
|
83
|
+
relation :connectedTo, :technologyDevices, :TechnologyDevice
|
|
84
|
+
relation :composedOf, :technologyDevices, :TechnologyDevice
|
|
85
|
+
relation :ownedBy, :businessActors, :BusinessActor
|
|
86
|
+
relation :ownedBy, :businessRoles, :BusinessRole
|
|
87
|
+
relation :servedBy, :businessActors, :BusinessActor
|
|
88
|
+
end
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# TechnologyEquipment represents racks, fabrics and physical clusters inside a facility
|
|
4
|
+
class Archsight::Resources::TechnologyEquipment < Archsight::Resources::Base
|
|
5
|
+
include_annotations :git, :architecture
|
|
6
|
+
|
|
7
|
+
description <<~MD
|
|
8
|
+
Represents physical equipment inside a facility: racks, network fabrics, physical clusters.
|
|
9
|
+
|
|
10
|
+
## ArchiMate Definition
|
|
11
|
+
|
|
12
|
+
**Layer:** Technology (physical element)
|
|
13
|
+
**Aspect:** Active Structure
|
|
14
|
+
|
|
15
|
+
TechnologyEquipment is one or more physical machines, tools or instruments that can create, use, store, move or transform
|
|
16
|
+
materials.
|
|
17
|
+
|
|
18
|
+
## Usage
|
|
19
|
+
|
|
20
|
+
Use TechnologyEquipment to represent:
|
|
21
|
+
|
|
22
|
+
- Racks and rack rows
|
|
23
|
+
- Network fabrics and switch stacks
|
|
24
|
+
- Physical clusters (storage arrays, hardware pools) that technology nodes run on
|
|
25
|
+
- Links between facilities (fibre routes, carrier circuits, `equipment/type: link`) and backbones made of them
|
|
26
|
+
|
|
27
|
+
Model individual physical machines as `TechnologyDevice` and VMs as `TechnologyNode`; use TechnologyEquipment only
|
|
28
|
+
when the physical grouping matters.
|
|
29
|
+
|
|
30
|
+
## Not this kind
|
|
31
|
+
|
|
32
|
+
- A single physical machine (server, switch, router, appliance) is a `TechnologyDevice`; a VM or host role is a
|
|
33
|
+
`TechnologyNode`
|
|
34
|
+
- The network that runs over the links is a `TechnologyCommunicationNetwork` `realizedBy` the equipment
|
|
35
|
+
- A link is one element `locatedAt` its two facilities, not a `TechnologyService`
|
|
36
|
+
|
|
37
|
+
Which kind to pick: "Choosing the Kind: Infrastructure" in the modeling guide.
|
|
38
|
+
|
|
39
|
+
## How it connects
|
|
40
|
+
|
|
41
|
+
- TechnologyEquipment is `locatedAt` the facilities it stands in. A link between facilities is one TechnologyEquipment that is
|
|
42
|
+
`locatedAt` both end facilities
|
|
43
|
+
- TechnologyEquipment is `composedOf` other TechnologyEquipment (a backbone of its links; the chain must not form a
|
|
44
|
+
cycle) and of the `TechnologyDevice`s it holds (a rack, a delivered hardware block)
|
|
45
|
+
- A technology service or node is `realizedBy` the TechnologyEquipment it runs on or over (a network service by the link)
|
|
46
|
+
- TechnologyEquipment is optional: nodes and services can be `locatedAt` a facility directly
|
|
47
|
+
- TechnologyEquipment is `ownedBy` the team (`BusinessActor`) or `BusinessRole` responsible for operating it and
|
|
48
|
+
`servedBy` the team it is dedicated to (a partition of a shared test cluster); `equipment/purpose` says what for.
|
|
49
|
+
The devices of a partition are normally served by the same team; `archsight lint` warns when one is not
|
|
50
|
+
- A `BusinessContract` `covers` the equipment it obliges the provider to deliver, and the `ImplementationWorkPackage` that
|
|
51
|
+
installs or changes it `affects` it
|
|
52
|
+
MD
|
|
53
|
+
|
|
54
|
+
icon "cpu"
|
|
55
|
+
layer "technology"
|
|
56
|
+
|
|
57
|
+
annotation "equipment/type",
|
|
58
|
+
description: "Kind of equipment",
|
|
59
|
+
title: "TechnologyEquipment Type",
|
|
60
|
+
enum: %w[rack network-fabric link cluster storage power cooling other],
|
|
61
|
+
filter: :word,
|
|
62
|
+
summary: true
|
|
63
|
+
|
|
64
|
+
annotation "equipment/purpose",
|
|
65
|
+
description: "What the equipment is dedicated to, e.g. hypervisor regression tests",
|
|
66
|
+
title: "Purpose",
|
|
67
|
+
filter: :word
|
|
68
|
+
|
|
69
|
+
relation :locatedAt, :technologyFacilities, :TechnologyFacility
|
|
70
|
+
relation :composedOf, :technologyEquipment, :TechnologyEquipment
|
|
71
|
+
relation :composedOf, :technologyDevices, :TechnologyDevice
|
|
72
|
+
relation :ownedBy, :businessActors, :BusinessActor
|
|
73
|
+
relation :ownedBy, :businessRoles, :BusinessRole
|
|
74
|
+
relation :servedBy, :businessActors, :BusinessActor
|
|
75
|
+
end
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# TechnologyEvent represents a technology event: something that happens in the infrastructure and triggers or interrupts technology behavior
|
|
4
|
+
class Archsight::Resources::TechnologyEvent < Archsight::Resources::Base
|
|
5
|
+
include_annotations :git, :architecture, :risk
|
|
6
|
+
|
|
7
|
+
description <<~MD
|
|
8
|
+
Represents a technology event: something that happens in the infrastructure and triggers or interrupts technology behavior.
|
|
9
|
+
|
|
10
|
+
## ArchiMate Definition
|
|
11
|
+
|
|
12
|
+
**Layer:** Technology
|
|
13
|
+
**Aspect:** Behavior
|
|
14
|
+
|
|
15
|
+
An event is something that happens and influences behavior. It does not last: it triggers or interrupts
|
|
16
|
+
processes and services. In the risk and security overlay of the Open Group paper (*Modeling Enterprise Risk
|
|
17
|
+
Management and Security with the ArchiMate Language*) a threat event and a loss event are events that carry a
|
|
18
|
+
type; set `event/type` to say which.
|
|
19
|
+
|
|
20
|
+
## Usage
|
|
21
|
+
|
|
22
|
+
Use TechnologyEvent for events on the technology level:
|
|
23
|
+
|
|
24
|
+
- Threat events and loss events of the infrastructure (a host compromise, an outage, a failed disk)
|
|
25
|
+
- Findings of a scan or a penetration test on a host or network
|
|
26
|
+
- Infrastructure alerts and changes
|
|
27
|
+
|
|
28
|
+
## Event types
|
|
29
|
+
|
|
30
|
+
- `threat-event`: an event with the potential to harm an asset; it can trigger a loss event
|
|
31
|
+
- `attack`: a threat event caused by intentional malicious activity
|
|
32
|
+
- `loss-event`: an event that harms an asset (a hazard materialises, a vulnerability is exploited)
|
|
33
|
+
- `incident`: a loss event that has happened
|
|
34
|
+
- `opportunity-event`: an event that can add value
|
|
35
|
+
- `audit`, `scan`, `change`: events that produce assessments or alter the architecture
|
|
36
|
+
- `other`
|
|
37
|
+
|
|
38
|
+
Filter, group and query by `event/type`, `risk/domain` and `risk/category` to see, for example, every loss
|
|
39
|
+
event of a risk domain.
|
|
40
|
+
|
|
41
|
+
## How it connects
|
|
42
|
+
|
|
43
|
+
- A threat event `triggers` a loss event or a process or service; threat and loss events may sit on different
|
|
44
|
+
layers (a technology event triggers an application or business event)
|
|
45
|
+
- `causedBy` the threat agent (an actor, component or node)
|
|
46
|
+
- `affects` the assets it harms
|
|
47
|
+
- A `MotivationDriver` (the threat) `triggers` it; a vulnerability `MotivationAssessment` `influences` it
|
|
48
|
+
MD
|
|
49
|
+
|
|
50
|
+
icon "warning-triangle"
|
|
51
|
+
layer "technology"
|
|
52
|
+
|
|
53
|
+
annotation "event/type",
|
|
54
|
+
description: "What kind of event this is (specialization of the event, see the risk and security overlay)",
|
|
55
|
+
enum: %w[threat-event attack loss-event incident opportunity-event audit scan change other],
|
|
56
|
+
filter: :word,
|
|
57
|
+
summary: true
|
|
58
|
+
|
|
59
|
+
annotation "event/severity",
|
|
60
|
+
description: "Severity of the event",
|
|
61
|
+
enum: %w[info low medium high critical],
|
|
62
|
+
filter: :word,
|
|
63
|
+
summary: true
|
|
64
|
+
|
|
65
|
+
annotation "event/occurred",
|
|
66
|
+
description: "When the event happened or is expected (ISO 8601 date or time)",
|
|
67
|
+
title: "Occurred",
|
|
68
|
+
validator: ->(value) { Archsight::Resources::Page.timestamp_error(value) }
|
|
69
|
+
|
|
70
|
+
relation :triggers, :technologyServices, :TechnologyService
|
|
71
|
+
relation :triggers, :technologyEvents, :TechnologyEvent
|
|
72
|
+
relation :triggers, :applicationEvents, :ApplicationEvent
|
|
73
|
+
relation :triggers, :businessEvents, :BusinessEvent
|
|
74
|
+
relation :causedBy, :businessActors, :BusinessActor
|
|
75
|
+
relation :causedBy, :applicationComponents, :ApplicationComponent
|
|
76
|
+
relation :causedBy, :technologyNodes, :TechnologyNode
|
|
77
|
+
relation :affects, :technologyNodes, :TechnologyNode
|
|
78
|
+
relation :affects, :technologyServices, :TechnologyService
|
|
79
|
+
relation :affects, :technologySystemSoftwares, :TechnologySystemSoftware
|
|
80
|
+
end
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
# TechnologyFacility represents a building, data center or site
|
|
4
|
+
class Archsight::Resources::TechnologyFacility < Archsight::Resources::Base
|
|
5
|
+
include_annotations :git, :architecture
|
|
6
|
+
|
|
7
|
+
description <<~MD
|
|
8
|
+
Represents a physical structure where technology runs: a building, data center or other site.
|
|
9
|
+
|
|
10
|
+
## ArchiMate Definition
|
|
11
|
+
|
|
12
|
+
**Layer:** Technology (physical element)
|
|
13
|
+
**Aspect:** Active Structure
|
|
14
|
+
|
|
15
|
+
A facility is a physical structure or environment. Technology nodes, services and system software are located
|
|
16
|
+
at facilities, and facilities themselves are located at a place.
|
|
17
|
+
|
|
18
|
+
## Usage
|
|
19
|
+
|
|
20
|
+
Use TechnologyFacility to represent:
|
|
21
|
+
|
|
22
|
+
- Data centers and colocation sites
|
|
23
|
+
- Offices
|
|
24
|
+
- Edge sites
|
|
25
|
+
- Parts of a site (campus, building, hall), nested with `composedOf`
|
|
26
|
+
- Rooms: a server room or fire compartment (`facility/type: room`) the data center is `composedOf`; devices stand
|
|
27
|
+
in it, which makes it a failure domain
|
|
28
|
+
|
|
29
|
+
## Not this kind
|
|
30
|
+
|
|
31
|
+
- A country, metro or region is a `Location`
|
|
32
|
+
- A rack, cage or fabric inside the site is `TechnologyEquipment`; a server is a `TechnologyDevice` (or a logical
|
|
33
|
+
`TechnologyNode`) `locatedAt` the facility
|
|
34
|
+
- A data center is never a `TechnologyNode` and never an annotation on other elements
|
|
35
|
+
|
|
36
|
+
Which kind to pick: "Choosing the Kind: Infrastructure" in the modeling guide.
|
|
37
|
+
|
|
38
|
+
## How it connects
|
|
39
|
+
|
|
40
|
+
- Things that run at a facility point to it with `locatedAt`: `TechnologyNode`, `TechnologyService`,
|
|
41
|
+
`TechnologySystemSoftware`, `TechnologyEquipment` and `TechnologyDevice`. One element can be located at many
|
|
42
|
+
facilities (one cluster that runs in three data centers is one element with three relations, not three copies)
|
|
43
|
+
- A facility is `locatedAt` a `Location` and `composedOf` other facilities (campus, hall, room)
|
|
44
|
+
- A facility is `servedBy` the `BusinessActor` that operates it
|
|
45
|
+
- The facility page lists what is located there (incoming `locatedAt`), grouped by kind
|
|
46
|
+
|
|
47
|
+
A service that runs on different platforms in different facilities is not given a qualifier: the nodes of the
|
|
48
|
+
platform are `locatedAt` the same facilities, so the pair is derivable.
|
|
49
|
+
MD
|
|
50
|
+
|
|
51
|
+
icon "building"
|
|
52
|
+
layer "technology"
|
|
53
|
+
|
|
54
|
+
annotation "facility/type",
|
|
55
|
+
description: "Kind of site",
|
|
56
|
+
title: "TechnologyFacility Type",
|
|
57
|
+
enum: %w[data-center colocation office edge room],
|
|
58
|
+
filter: :word,
|
|
59
|
+
summary: true
|
|
60
|
+
|
|
61
|
+
annotation "facility/stage",
|
|
62
|
+
description: "Free text stage of the facility (planned, in build, productive, phase-out, ...)",
|
|
63
|
+
title: "Stage",
|
|
64
|
+
filter: :word,
|
|
65
|
+
summary: true
|
|
66
|
+
|
|
67
|
+
relation :locatedAt, :locations, :Location
|
|
68
|
+
relation :composedOf, :technologyFacilities, :TechnologyFacility
|
|
69
|
+
relation :servedBy, :businessActors, :BusinessActor
|
|
70
|
+
end
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
# TechnologyNode represents physical infrastructure (VMs, servers, Kubernetes nodes)
|
|
4
4
|
class Archsight::Resources::TechnologyNode < Archsight::Resources::Base
|
|
5
|
-
include_annotations :git, :architecture
|
|
5
|
+
include_annotations :git, :architecture, :asset, :risk
|
|
6
6
|
|
|
7
7
|
description <<~MD
|
|
8
8
|
Represents physical infrastructure hosting application components.
|
|
@@ -25,6 +25,53 @@ class Archsight::Resources::TechnologyNode < Archsight::Resources::Base
|
|
|
25
25
|
- Kubernetes nodes
|
|
26
26
|
- Network appliances
|
|
27
27
|
- Storage arrays
|
|
28
|
+
|
|
29
|
+
## Not this kind
|
|
30
|
+
|
|
31
|
+
- A building or data center is a `TechnologyFacility`; a rack or fabric is `TechnologyEquipment`
|
|
32
|
+
- Software running on the node (database, routing stack) is `TechnologySystemSoftware`
|
|
33
|
+
- One node per host role is often enough; many identical hosts are one node `locatedAt` several facilities
|
|
34
|
+
- A single physical machine whose room or cabling matters is a `TechnologyDevice`; the node is `realizedBy` it
|
|
35
|
+
|
|
36
|
+
Which kind to pick: "Choosing the Kind: Infrastructure" in the modeling guide.
|
|
37
|
+
|
|
38
|
+
## Location
|
|
39
|
+
|
|
40
|
+
A node is `locatedAt` the `TechnologyFacility` (or facilities) it stands in; see `TechnologyFacility`.
|
|
41
|
+
|
|
42
|
+
## Networks
|
|
43
|
+
|
|
44
|
+
A node is `servedBy` the `TechnologyCommunicationNetwork`s it is attached to (management, public, an overlay).
|
|
45
|
+
|
|
46
|
+
## Teams
|
|
47
|
+
|
|
48
|
+
A node is `ownedBy` the team (`BusinessActor`) or `BusinessRole` that operates it and `servedBy` the team it is
|
|
49
|
+
dedicated to (a test cluster held by one team).
|
|
50
|
+
|
|
51
|
+
## Physical realization
|
|
52
|
+
|
|
53
|
+
A node is `realizedBy` the `TechnologyEquipment` it consists of or stands on (a router on its rack); see `TechnologyEquipment`.
|
|
54
|
+
A logical node (a host role, "the hypervisors of the platform") is `realizedBy` the `TechnologyDevice`s, the
|
|
55
|
+
physical machines, that make it up.
|
|
56
|
+
|
|
57
|
+
## Concept and implementation
|
|
58
|
+
|
|
59
|
+
A node can `specialize` another node (ArchiMate specialization): the general node is the concept (a regional
|
|
60
|
+
cluster), the specific nodes are its implementations. The concept's page lists them as incoming "specializes".
|
|
61
|
+
A node made of other nodes (a cluster of hosts) is `composedOf` them (ArchiMate composition). Both only point at
|
|
62
|
+
nodes, and neither may form a cycle.
|
|
63
|
+
|
|
64
|
+
## Deployment
|
|
65
|
+
|
|
66
|
+
A node `assignedTo` the artifacts that are deployed on it (ArchiMate assignment): the image it boots, the
|
|
67
|
+
packages installed on it. The relation is written on the node, which owns the deployment; the artifact's page
|
|
68
|
+
shows the nodes as incoming "deployed on".
|
|
69
|
+
|
|
70
|
+
## Security and risk modelling
|
|
71
|
+
|
|
72
|
+
A node is the typical asset of a vulnerability assessment: a scan result is a `MotivationAssessment` of type
|
|
73
|
+
`vulnerability` that `assesses` the nodes it was found on (one vulnerability, many nodes) and `influences` the
|
|
74
|
+
loss events it makes possible. Set the `asset/*` profile and `risk/domain` to group nodes by context.
|
|
28
75
|
MD
|
|
29
76
|
|
|
30
77
|
icon "server-connection"
|
|
@@ -38,5 +85,14 @@ class Archsight::Resources::TechnologyNode < Archsight::Resources::Base
|
|
|
38
85
|
|
|
39
86
|
relation :realizes, :motivationConstraints, :MotivationConstraint
|
|
40
87
|
relation :servedBy, :technologyServices, :TechnologyService
|
|
88
|
+
relation :servedBy, :technologyCommunicationNetworks, :TechnologyCommunicationNetwork
|
|
41
89
|
relation :servedBy, :businessActors, :BusinessActor
|
|
90
|
+
relation :ownedBy, :businessActors, :BusinessActor
|
|
91
|
+
relation :ownedBy, :businessRoles, :BusinessRole
|
|
92
|
+
relation :locatedAt, :technologyFacilities, :TechnologyFacility
|
|
93
|
+
relation :realizedBy, :technologyEquipment, :TechnologyEquipment
|
|
94
|
+
relation :realizedBy, :technologyDevices, :TechnologyDevice
|
|
95
|
+
relation :specializes, :technologyNodes, :TechnologyNode
|
|
96
|
+
relation :composedOf, :technologyNodes, :TechnologyNode
|
|
97
|
+
relation :assignedTo, :technologyArtifacts, :TechnologyArtifact
|
|
42
98
|
end
|
|
@@ -25,6 +25,36 @@ class Archsight::Resources::TechnologyService < Archsight::Resources::Base
|
|
|
25
25
|
- Managed database services
|
|
26
26
|
- CI/CD pipeline services
|
|
27
27
|
- Monitoring and logging platforms
|
|
28
|
+
|
|
29
|
+
## Not this kind
|
|
30
|
+
|
|
31
|
+
- The software that provides it is `TechnologySystemSoftware`, the machines are `TechnologyNode`s
|
|
32
|
+
- A network is a `TechnologyCommunicationNetwork`; a physical link is `TechnologyEquipment`
|
|
33
|
+
- One service for all sites, `locatedAt` each `TechnologyFacility`, not a copy per site
|
|
34
|
+
|
|
35
|
+
Which kind to pick: "Choosing the Kind: Infrastructure" in the modeling guide.
|
|
36
|
+
|
|
37
|
+
## Location
|
|
38
|
+
|
|
39
|
+
A service that runs in several data centers is one service that is `locatedAt` each `TechnologyFacility`, not one service
|
|
40
|
+
per site.
|
|
41
|
+
|
|
42
|
+
## Physical realization
|
|
43
|
+
|
|
44
|
+
A service is `realizedBy` the `TechnologyEquipment` it runs over: a backbone network service is realized by the links
|
|
45
|
+
between the facilities (`equipment/type: link`).
|
|
46
|
+
|
|
47
|
+
## Deployed components
|
|
48
|
+
|
|
49
|
+
Application components deployed on the service point to it with `servedBy`; they are listed as incoming
|
|
50
|
+
"servedBy" from ApplicationComponent on its page. An ApplicationService that is `servedBy` the service uses it as a
|
|
51
|
+
whole; list a cluster there only when the service's own components run in it.
|
|
52
|
+
|
|
53
|
+
## Concept and implementation
|
|
54
|
+
|
|
55
|
+
A service can `specialize` another service (ArchiMate specialization): the general service is the concept, the
|
|
56
|
+
specific ones are its implementations, listed as incoming "specializes" on the concept's page. The target must be
|
|
57
|
+
a TechnologyService and the chain must not form a cycle.
|
|
28
58
|
MD
|
|
29
59
|
|
|
30
60
|
icon "cloud"
|
|
@@ -36,7 +66,10 @@ class Archsight::Resources::TechnologyService < Archsight::Resources::Base
|
|
|
36
66
|
format: :markdown
|
|
37
67
|
|
|
38
68
|
relation :suppliedBy, :technologyComponents, :TechnologySystemSoftware
|
|
69
|
+
relation :specializes, :technologyServices, :TechnologyService
|
|
39
70
|
relation :servedBy, :businessActors, :BusinessActor
|
|
71
|
+
relation :locatedAt, :technologyFacilities, :TechnologyFacility
|
|
72
|
+
relation :realizedBy, :technologyEquipment, :TechnologyEquipment
|
|
40
73
|
relation :realizes, :motivationRequirements, :MotivationRequirement
|
|
41
74
|
relation :partiallyRealizes, :motivationRequirements, :MotivationRequirement
|
|
42
75
|
relation :plans, :motivationRequirements, :MotivationRequirement
|
|
@@ -25,12 +25,39 @@ class Archsight::Resources::TechnologySystemSoftware < Archsight::Resources::Bas
|
|
|
25
25
|
- Cache clusters
|
|
26
26
|
- Load balancers
|
|
27
27
|
- Service meshes
|
|
28
|
+
|
|
29
|
+
## Not this kind
|
|
30
|
+
|
|
31
|
+
- The machine it runs on is a `TechnologyNode`
|
|
32
|
+
- What consumers use from it is a `TechnologyService`
|
|
33
|
+
- A routing stack that implements a network realizes a `TechnologyCommunicationNetwork`
|
|
34
|
+
|
|
35
|
+
Which kind to pick: "Choosing the Kind: Infrastructure" in the modeling guide.
|
|
36
|
+
|
|
37
|
+
## Location
|
|
38
|
+
|
|
39
|
+
System software is `locatedAt` the `TechnologyFacility` (or facilities) it runs in.
|
|
40
|
+
|
|
41
|
+
## Deployment
|
|
42
|
+
|
|
43
|
+
System software `assignedTo` the artifacts it executes (ArchiMate assignment), written on the system software.
|
|
44
|
+
The artifact's page shows it as incoming "deployed on".
|
|
45
|
+
|
|
46
|
+
## Concept and implementation
|
|
47
|
+
|
|
48
|
+
System software can `specialize` other system software (ArchiMate specialization): the general one is the
|
|
49
|
+
concept, the specific ones are its implementations, listed as incoming "specializes" on the concept's page.
|
|
50
|
+
A platform that bundles components is `composedOf` them (ArchiMate composition). Both only point at system
|
|
51
|
+
software, and neither may form a cycle.
|
|
28
52
|
MD
|
|
29
53
|
|
|
30
54
|
icon "terminal-tag"
|
|
31
55
|
layer "technology"
|
|
32
56
|
|
|
33
57
|
relation :realizedBy, :technologyComponents, :TechnologyNode
|
|
58
|
+
relation :specializes, :technologySystemSoftware, :TechnologySystemSoftware
|
|
59
|
+
relation :composedOf, :technologySystemSoftware, :TechnologySystemSoftware
|
|
60
|
+
relation :assignedTo, :technologyArtifacts, :TechnologyArtifact
|
|
34
61
|
relation :realizedThrough, :technologyArtifacts, :TechnologyArtifact
|
|
35
62
|
relation :exposes, :applicationInterfaces, :ApplicationInterface
|
|
36
63
|
relation :dependsOn, :applicationInterfaces, :ApplicationInterface
|
|
@@ -38,4 +65,5 @@ class Archsight::Resources::TechnologySystemSoftware < Archsight::Resources::Bas
|
|
|
38
65
|
relation :partiallyRealizes, :motivationRequirements, :MotivationRequirement
|
|
39
66
|
relation :plans, :motivationRequirements, :MotivationRequirement
|
|
40
67
|
relation :evidencedBy, :complianceEvidences, :ComplianceEvidence
|
|
68
|
+
relation :locatedAt, :technologyFacilities, :TechnologyFacility
|
|
41
69
|
end
|
data/lib/archsight/resources.rb
CHANGED
|
@@ -14,6 +14,12 @@ module Archsight
|
|
|
14
14
|
"BusinessConstraint" => "MotivationConstraint"
|
|
15
15
|
}.freeze
|
|
16
16
|
|
|
17
|
+
# Annotations that were renamed: the old key is rewritten to the new one when a document is loaded (see
|
|
18
|
+
# Database#accept_old_names) and reported as deprecated by `archsight lint`.
|
|
19
|
+
ANNOTATION_ALIASES = {
|
|
20
|
+
"page/confluence" => "link/confluence"
|
|
21
|
+
}.freeze
|
|
22
|
+
|
|
17
23
|
# Relation keys (the plural kind names under `spec.<verb>`) that were renamed together with their kind
|
|
18
24
|
RELATION_KEY_ALIASES = {
|
|
19
25
|
"businessRequirements" => "motivationRequirements",
|
|
@@ -28,6 +34,12 @@ module Archsight
|
|
|
28
34
|
DERIVED_VERBS = %i[mentions depicts].freeze
|
|
29
35
|
DERIVED_KEY = :resources
|
|
30
36
|
|
|
37
|
+
# The layers a kind belongs to (Base.layer), top to bottom: why (motivation), what we want to become (strategy),
|
|
38
|
+
# how the change happens (implementation and migration), then the architecture it changes (business, application,
|
|
39
|
+
# technology). `other` holds the tool's own kinds (pages, views, imports, ...) and stays last. Everything that
|
|
40
|
+
# lists or orders layers uses this; the frontend repeats it in frontend/src/composables/useLayers.js.
|
|
41
|
+
LAYERS = %w[motivation strategy implementation business application technology other].freeze
|
|
42
|
+
|
|
31
43
|
# The derived relations of every class, next to the ones it declares: [verb, key, kind]
|
|
32
44
|
DERIVED_RELATIONS = DERIVED_VERBS.map { |verb| [verb, DERIVED_KEY, "Resource"] }.freeze
|
|
33
45
|
|
data/lib/archsight/version.rb
CHANGED
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Archsight; end
|
|
4
|
+
module Archsight::Web; end
|
|
5
|
+
module Archsight::Web::API; end
|
|
6
|
+
|
|
7
|
+
# JSON of `POST /api/v1/kinds/Analysis/instances/:name/execute`: the result and its sections
|
|
8
|
+
module Archsight::Web::API::AnalysisHelpers
|
|
9
|
+
def build_analysis_result(result)
|
|
10
|
+
data = {
|
|
11
|
+
name: result.name,
|
|
12
|
+
success: result.success?,
|
|
13
|
+
has_findings: result.has_findings?,
|
|
14
|
+
duration: result.duration,
|
|
15
|
+
sections: result.sections.map { |s| serialize_analysis_section(s) }
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
if result.failed?
|
|
19
|
+
data[:error] = result.error
|
|
20
|
+
data[:error_backtrace] = result.error_backtrace if result.error_backtrace&.any?
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
data
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def serialize_analysis_section(section)
|
|
27
|
+
case section[:type]
|
|
28
|
+
when :heading
|
|
29
|
+
{ type: "heading", level: section[:level], text: section[:text] }
|
|
30
|
+
when :text
|
|
31
|
+
{ type: "text", content: markdown(section[:content]) }
|
|
32
|
+
# the *_html fields: the values as inline markdown with [[Kind/Name]] links, next to the raw values
|
|
33
|
+
when :message
|
|
34
|
+
{ type: "message", level: section[:level].to_s, message: section[:message],
|
|
35
|
+
message_html: analysis_html(section[:message]) }
|
|
36
|
+
when :table
|
|
37
|
+
{ type: "table", headers: section[:headers], rows: section[:rows],
|
|
38
|
+
rows_html: section[:rows].map { |row| row.map { |cell| analysis_html(cell) } } }
|
|
39
|
+
when :list
|
|
40
|
+
{ type: "list", items: section[:items], items_html: section[:items].map { |item| analysis_html(item) } }
|
|
41
|
+
when :code
|
|
42
|
+
{ type: "code", lang: section[:lang], content: section[:content] }
|
|
43
|
+
else
|
|
44
|
+
{ type: section[:type].to_s }
|
|
45
|
+
end
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# A value of a table cell, list item or message as html: HTML in it stays text (escaped first) except a line
|
|
49
|
+
# break (`<br>` or a newline, the usual way to break a line in a table cell), markdown and [[Kind/Name]] links are
|
|
50
|
+
# rendered; a value without markup is only escaped, so large tables stay cheap
|
|
51
|
+
def analysis_html(value)
|
|
52
|
+
escaped = Rack::Utils.escape_html(value.to_s).gsub(%r{<br\s*/?>}i, "<br>").gsub(/\r?\n/, "<br>")
|
|
53
|
+
escaped.match?(/[*_`\[{]|https?:/) ? inline_markdown(escaped) : escaped
|
|
54
|
+
end
|
|
55
|
+
end
|