Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 0 additions & 38 deletions docs/analysis/additional-nodes/hybrid-extension.md

This file was deleted.

17 changes: 17 additions & 0 deletions docs/analysis/additional-nodes/hybrid-run-command-parameter.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# HybridRunCommandParameter

Represents a parameter for a hybrid machine run command.

**Labels:** `:HybridRunCommandParameter`

**Properties:**

- `name` - Parameter name (composite key with `commandId`)
- `commandId` - Parent run command ID (composite key)
- `value` - Parameter value

## Relationships

### Incoming

- **HybridRunCommand** → `HAS_PARAMETER` → **HybridRunCommandParameter** - Parent run command
34 changes: 34 additions & 0 deletions docs/analysis/additional-nodes/hybrid-run-command.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# HybridRunCommand

Represents a run command resource associated with an Azure Arc-enabled hybrid machine.

**Labels:** `:ArmResource:HybridRunCommand`

**Properties:**

- `id` - Run command resource ID (primary key)
- `asyncExecution` - Whether execution is asynchronous
- `runAsUser` - User context used to run the command
- `timeoutInSeconds` - Command timeout in seconds
- `treatFailureAsDeploymentFailure` - Failure handling behavior
- `script` - Script body
- `output` - Command output from the last execution

## Relationships

### Incoming

- **HybridMachine** → `HAS_RUN_COMMAND` → **HybridRunCommand** - Parent hybrid machine

### Outgoing

- **HybridRunCommand** → `HAS_PARAMETER` → **HybridRunCommandParameter** - Parameters bound to the run command

## Examples

```cypher
// Find hybrid run commands and their parameters
MATCH (hm:HybridMachine)-[:HAS_RUN_COMMAND]->(cmd:HybridRunCommand)
OPTIONAL MATCH (cmd)-[:HAS_PARAMETER]->(p:HybridRunCommandParameter)
RETURN hm.displayName, cmd.id, collect(p.name) AS parameterNames
```
2 changes: 1 addition & 1 deletion docs/analysis/additional-nodes/vm-extension.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Represents an extension attached to an Azure virtual machine.

**Labels:** `:VMExtension`
**Labels:** `:ArmResource:VMExtension`

**Properties:**

Expand Down
3 changes: 2 additions & 1 deletion docs/analysis/additional-nodes/vm-run-command-parameter.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ Represents a parameter for a virtual machine run command.

**Properties:**

- `name` - Parameter name (primary key)
- `name` - Parameter name (composite key with `commandId`)
- `commandId` - Parent run command ID (composite key)
- `value` - Parameter value

## Relationships
Expand Down
37 changes: 29 additions & 8 deletions docs/analysis/arm-nodes/hybridcompute/hybrid-extension.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,41 @@
# HybridExtension

Represents extensions installed on hybrid machines (not an ARM resource itself).
Represents extensions installed on Azure Arc-enabled hybrid machines.

**Labels:** `:HybridExtension`
**Labels:** `:ArmResource:HybridExtension`

**Properties:**

- `id` - Extension ID (primary key)
- `id` - Extension resource ID (primary key)
- `name` - Extension name
- `type` - Extension type
- `location` - Extension location
- `type` - Resource type (`microsoft.hybridcompute/machines/extensions`)
- `location` - Resource location
- `extType` - Extension type (e.g. `CustomScriptExtension`)
- `typeHandlerVersion` - Type handler version
- `autoUpgradeMinorVersion` - Auto upgrade minor version
- `enableAutomaticUpgrade` - Enable automatic upgrade
- `statusMessage` - Status message
- `statusMessage` - Extension status message
- `provisioningState` - Provisioning state
- `publisher` - Extension publisher
- `settings` - Serialized extension settings (JSON)

**Relationships:**
- `HAS_EXTENSION` ← HybridMachine
## Relationships

### Incoming

- **HybridMachine** → `HAS_EXTENSION` → **HybridExtension** - Parent hybrid machine

## Examples

```cypher
// Find all hybrid machine extensions
MATCH (hm:HybridMachine)-[:HAS_EXTENSION]->(ext:HybridExtension)
RETURN hm.displayName, ext.name, ext.extType, ext.provisioningState
```

```cypher
// Find extensions with auto upgrade enabled
MATCH (ext:HybridExtension)
WHERE ext.enableAutomaticUpgrade = true
RETURN ext.name, ext.extType, ext.typeHandlerVersion
```
23 changes: 23 additions & 0 deletions docs/analysis/arm-nodes/hybridcompute/hybrid-gateway.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# HybridGateway

Represents an Azure Arc gateway resource used to connect hybrid machines to Azure through a managed endpoint.

**Labels:** `:ArmResource:HybridGateway`

**Properties:**

- `id` - Gateway resource ID (primary key)
- `allowedFeatures` - Features allowed through the gateway
- `gatewayEndpoint` - Gateway endpoint URL
- `gatewayId` - Unique gateway identifier
- `gatewayType` - Type of gateway
- `lastUpdateTime` - Last update timestamp
- `provisioningState` - Provisioning state

## Examples

```cypher
// Find all hybrid gateways
MATCH (gw:HybridGateway)
RETURN gw.id, gw.gatewayType, gw.gatewayEndpoint, gw.provisioningState
```
21 changes: 21 additions & 0 deletions docs/analysis/arm-nodes/hybridcompute/hybrid-private-link-scope.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# HybridPrivateLinkScope

Represents an Azure Arc private link scope resource used to connect hybrid machines over private endpoints.

**Labels:** `:ArmResource:HybridPrivateLinkScope`

**Properties:**

- `id` - Private link scope resource ID (primary key)
- `privateLinkScopeId` - Unique private link scope identifier
- `provisioningState` - Provisioning state
- `publicNetworkAccess` - Public network access setting

## Examples

```cypher
// Find private link scopes with public access enabled
MATCH (pls:HybridPrivateLinkScope)
WHERE pls.publicNetworkAccess = "Enabled"
RETURN pls.id, pls.privateLinkScopeId
```
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ properties:
- "/properties"
cypher: |
UNWIND $batch AS row
MERGE (obj:{{ LABELS.VMExtension }} {id: toLower(row.id)})
MERGE (obj:{{ LABELS.ArmResource }} {id: toLower(row.id)})
SET obj:{{ LABELS.VMExtension }}

SET obj += {
autoUpgradeMinorVersion: row.properties.autoUpgradeMinorVersion,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ resource_type: "microsoft.compute/virtualmachines/runcommands"
properties:
- "/id"
- "/properties"
index_properties:
- "{{ LABELS.VMRunCommandParameter }}:name+commandId"
cypher: |
UNWIND $batch AS row
MERGE (obj:{{ LABELS.ArmResource }} {id: toLower(row.id)})
Expand All @@ -27,7 +29,7 @@ cypher: |
CALL {
WITH obj, row
UNWIND coalesce(row.properties.parameters, []) AS param
MERGE (p:{{ LABELS.VMRunCommandParameter }} {name: param.name})
MERGE (p:{{ LABELS.VMRunCommandParameter }} {name: param.name, commandId: toLower(obj.id)})
SET p.value = param.value

MERGE (obj)-[:{{ REL.HAS_PARAMETER }}]->(p)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ cypher: |
WITH obj, row
UNWIND coalesce(row.resources, []) AS resource
WITH obj, resource WHERE toLower(resource.type) = "microsoft.compute/virtualmachines/extensions"
MERGE (e:{{ LABELS.VMExtension }} {id: toLower(resource.id)})
MERGE (e:{{ LABELS.ArmResource }} {id: toLower(resource.id)})
SET e:{{ LABELS.VMExtension }}
SET e += {
name: resource.name,
type: toLower(resource.type),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,13 @@ cypher: |
WITH obj, row
UNWIND coalesce(row.resources, []) AS resource
WITH obj, resource WHERE toLower(resource.type) = "microsoft.hybridcompute/machines/extensions"
MERGE (e:{{ LABELS.HybridExtension }} {id: toLower(resource.id)})
MERGE (e:{{ LABELS.ArmResource }} {id: toLower(resource.id)})
SET e:{{ LABELS.HybridExtension }}
SET e += {
name: resource.name,
type: resource.type,
location: resource.location,
extType: resource.properties.type,
typeHandlerVersion: resource.properties.typeHandlerVersion,
autoUpgradeMinorVersion: resource.properties.autoUpgradeMinorVersion,
enableAutomaticUpgrade: resource.properties.enableAutomaticUpgrade,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: "Hybrid Machine Extensions"
label: "{{ LABELS.HybridExtension }}"
table_name: "resources"
resource_type: "microsoft.hybridcompute/machines/extensions"
properties:
- "/id"
- "/properties"
cypher: |
UNWIND $batch AS row
MERGE (obj:{{ LABELS.ArmResource }} {id: toLower(row.id)})
SET obj:{{ LABELS.HybridExtension }}

SET obj += {
extType: row.properties.type,
autoUpgradeMinorVersion: row.properties.autoUpgradeMinorVersion,
enableAutomaticUpgrade: row.properties.enableAutomaticUpgrade,
statusMessage: row.properties.instanceView.status.message,
provisioningState: row.properties.provisioningState,
publisher: row.properties.publisher,
settings: apoc.convert.toJson(row.properties.settings)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: "Hybrid Machine Gateways"
label: "{{ LABELS.HybridGateway }}"
table_name: "resources"
resource_type: "microsoft.hybridcompute/gateways"
properties:
- "/id"
- "/properties"
cypher: |
UNWIND $batch AS row
MERGE (obj:{{ LABELS.ArmResource }} {id: toLower(row.id)})
SET obj:{{ LABELS.HybridGateway }}

SET obj += {
allowedFeatures: row.properties.allowedFeatures,
gatewayEndpoint: row.properties.gatewayEndpoint,
gatewayId: row.properties.gatewayId,
gatewayType: row.properties.gatewayType,
lastUpdateTime: row.properties.lastUpdateTime,
provisioningState: row.properties.provisioningState
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: "Hybrid Machine Run Commands"
label: "{{ LABELS.HybridRunCommand }}"
table_name: "resources"
resource_type: "microsoft.compute/virtualmachines/runcommands"
properties:
- "/id"
- "/properties"
index_properties:
- "{{ LABELS.HybridRunCommandParameter }}:name+commandId"
cypher: |
UNWIND $batch AS row
MERGE (obj:{{ LABELS.ArmResource }} {id: toLower(row.id)})
SET obj:{{ LABELS.HybridRunCommand }}

SET obj += {
asyncExecution: row.properties.asyncExecution,
runAsUser: row.properties.runAsUser,
timeoutInSeconds: row.properties.timeoutInSeconds,
treatFailureAsDeploymentFailure: row.properties.treatFailureAsDeploymentFailure,
script: row.properties.source.script,
output: row.properties.instanceView.output
}

WITH obj, row, split(toLower(obj.id), '/runcommands/')[0] AS vmId
MERGE (vm:{{ LABELS.ArmResource }} {id: toLower(vmId)})
SET vm:{{ LABELS.HybridMachine }}
MERGE (vm)-[:{{ REL.HAS_RUN_COMMAND }}]->(obj)

WITH obj, row
CALL {
WITH obj, row
UNWIND coalesce(row.properties.parameters, []) AS param
MERGE (p:{{ LABELS.HybridRunCommandParameter }} {name: param.name, commandId: toLower(obj.id)})
SET p.value = param.value

MERGE (obj)-[:{{ REL.HAS_PARAMETER }}]->(p)
RETURN count(*) AS _
}
RETURN count(*) AS _
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: "Hybrid Private Link Scopes"
label: "{{ LABELS.HybridPrivateLinkScope }}"
table_name: "resources"
resource_type: "microsoft.hybridcompute/privatelinkscopes"
properties:
- "/id"
- "/properties"
cypher: |
UNWIND $batch AS row
MERGE (obj:{{ LABELS.ArmResource }} {id: toLower(row.id)})
SET obj:{{ LABELS.HybridPrivateLinkScope }}

SET obj += {
privateLinkScopeId: row.properties.privateLinkScopeId,
provisioningState: row.properties.provisioningState,
publicNetworkAccess: row.properties.publicNetworkAccess
}
6 changes: 5 additions & 1 deletion src/graph/config/constants.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,10 @@ LABELS:
GalleryImageVersion: "GalleryImageVersion"
GithubNetworkSettings: "GithubNetworkSettings"
GrafanaDashboard: "GrafanaDashboard"
HybridGateway: "HybridGateway"
HybridMachine: "HybridMachine"
HybridExtension: "HybridExtension"
HybridPrivateLinkScope: "HybridPrivateLinkScope"
KeyVault: "KeyVault"
KeyVaultSecret: "KeyVaultSecret"
KeyVaultSecretValue: "KeyVaultSecretValue"
Expand Down Expand Up @@ -203,8 +206,9 @@ LABELS:
ExpressRouteCircuitPeering: "ExpressRouteCircuitPeering"
FederatedIdentityCredential: "FederatedIdentityCredential"
GraphAppRole: "GraphAppRole"
HybridExtension: "HybridExtension"
HybridIPAddress: "HybridIPAddress"
HybridRunCommand: "HybridRunCommand"
HybridRunCommandParameter: "HybridRunCommandParameter"
IPConfiguration: "IPConfiguration"
NetAppAccountADDomain: "NetAppAccountADDomain"
NetAppVolumeMount: "NetAppVolumeMount"
Expand Down
Loading
Loading