Add queue hardening by modifying DeploymentJobTargets, DeploymentJobSteps, and DeploymentJobs tables

- Drop existing indexes on DeploymentJobTargets and DeploymentJobSteps
- Alter Status column to nvarchar(450) in DeploymentJobTargets, DeploymentJobSteps, and DeploymentJobs
- Add new columns: Finished, OutputMetadataJson, Started to DeploymentJobTargets; ErrorMessage, Finished, OutputMetadataJson, Started to DeploymentJobSteps; CorrelationId, HeartbeatAt, Priority, RowVersion, ScheduledAt, WorkerName to DeploymentJobs
- Create new indexes for improved query performance
- Add constraints to ensure OutputMetadataJson is valid JSON
- Record migration in __EFMigrationsHistory
This commit is contained in:
Torsten Brendgen
2026-07-09 08:50:09 +02:00
parent 97238c28c9
commit 01c2a5df2e
45 changed files with 8198 additions and 75 deletions

60
.gitignore vendored Normal file
View File

@@ -0,0 +1,60 @@
# Build output
bin/
obj/
out/
publish/
artifacts/
# Visual Studio / Rider / VS Code
.vs/
.idea/
.vscode/.ropeproject
*.user
*.suo
*.rsuser
*.sln.docstates
*.csproj.user
*.csproj.lscache
# .NET / test artifacts
TestResults/
coverage/
coverage.xml
coverage.cobertura.xml
*.trx
*.coverage
*.coveragexml
# Logs / temp
*.log
*.tmp
*.temp
*.cache
*.bak
*.orig
# Local configuration / secrets
appsettings.Local.json
appsettings.*.local.json
appsettings.*.Local.json
*.secrets.json
secrets.json
# EF / local tooling noise
.ef/
# OS files
.DS_Store
Thumbs.db
desktop.ini
# Node/Web artifacts if frontend files ever land here
node_modules/
dist/
.env
.env.local
.env.*.local
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*

View File

@@ -0,0 +1,421 @@
param(
[string]$ApiBaseUrl = 'http://localhost:5286/api',
[string]$BgwRoot = ('F:\Kunden Auftr' + [char]0x00E4 + 'ge\BGW'),
[string]$DeploymentBatchId = '80000000-0000-0000-0000-000000000101',
[string]$MergeModulePath = 'F:\Projekte\Coding\PowerShell\Merge-DSCConfigurationData\Merge-DSCConfigurationData.psd1',
[string]$ResolveModulePath = 'F:\Projekte\Coding\PowerShell\Resolve-DSCConfigurationData\Resolve-DSCConfigurationData.psd1',
[int]$ApiTimeoutSec = 30,
[bool]$UseDefaultCredentials = $true
)
$ErrorActionPreference = 'Stop'
function Invoke-TestBgwMergeApiJson {
param(
[ValidateSet('GET', 'POST', 'PUT', 'DELETE')]
[string]$Method,
[string]$Path
)
$uri = ('{0}/{1}' -f $ApiBaseUrl.TrimEnd('/'), $Path.TrimStart('/'))
$parameters = @{
Method = $Method
Uri = $uri
TimeoutSec = $ApiTimeoutSec
ErrorAction = 'Stop'
}
if ($UseDefaultCredentials) {
$parameters.UseDefaultCredentials = $true
}
try {
Invoke-RestMethod @parameters
}
catch {
$responseBody = '<empty response body>'
if ($_.Exception.Response) {
try {
$stream = $_.Exception.Response.GetResponseStream()
if ($stream) {
$reader = [System.IO.StreamReader]::new($stream)
$text = $reader.ReadToEnd()
if (-not [string]::IsNullOrWhiteSpace($text)) {
$responseBody = $text
}
}
}
catch {
$responseBody = '<could not read response body>'
}
}
throw "API request failed. Method=[$Method], Uri=[$uri], Response=[$responseBody]. $($_.Exception.Message)"
}
}
function ConvertTo-TestBgwMergeConfigurationValue {
param([object]$Value)
if ($null -eq $Value) {
return $null
}
if ($Value -is [string] -or $Value -is [bool] -or $Value -is [int] -or $Value -is [long] -or $Value -is [double] -or $Value -is [decimal]) {
return $Value
}
if ($Value -is [System.Collections.IDictionary]) {
$result = [ordered]@{}
foreach ($key in $Value.Keys) {
$result[[string]$key] = ConvertTo-TestBgwMergeConfigurationValue -Value $Value[$key]
}
Write-Output -NoEnumerate $result
return
}
if ($Value -is [pscustomobject]) {
$result = [ordered]@{}
foreach ($property in $Value.PSObject.Properties) {
$result[$property.Name] = ConvertTo-TestBgwMergeConfigurationValue -Value $property.Value
}
Write-Output -NoEnumerate $result
return
}
if ($Value -is [System.Collections.IEnumerable] -and $Value -isnot [string]) {
$items = New-Object System.Collections.Generic.List[object]
foreach ($item in $Value) {
$items.Add((ConvertTo-TestBgwMergeConfigurationValue -Value $item))
}
Write-Output -NoEnumerate $items.ToArray()
return
}
return $Value
}
function ConvertFrom-TestBgwMergeTemplateJson {
param([string]$JsonData)
$document = $JsonData | ConvertFrom-Json
$metadata = ConvertTo-TestBgwMergeConfigurationValue -Value $document.metadata
if ($null -eq $metadata) {
$metadata = [ordered]@{}
}
if (-not $metadata.Contains('TemplateType')) {
$metadata['TemplateType'] = $document.templateType
}
[ordered]@{
Metadata = $metadata
Parameters = ConvertTo-TestBgwMergeConfigurationValue -Value $document.parameters
Variables = ConvertTo-TestBgwMergeConfigurationValue -Value $document.variables
Resources = ConvertTo-TestBgwMergeConfigurationValue -Value $document.resources
}
}
function ConvertFrom-TestBgwMergeTargetAssignments {
param([object[]]$TargetAssignments)
@($TargetAssignments | Sort-Object sortOrder | ForEach-Object {
$nodeData = ConvertTo-TestBgwMergeConfigurationValue -Value ($_.nodeDataJson | ConvertFrom-Json)
$node = @{}
foreach ($key in $nodeData.Keys) {
if ($key -eq 'nodeName') {
$node.NodeName = $nodeData[$key]
}
else {
$node[$key] = $nodeData[$key]
}
}
$node
})
}
function ConvertTo-TestBgwMergeStableValue {
param([object]$Value)
if ($null -eq $Value) {
return $null
}
if ($Value -is [string] -or $Value -is [bool] -or $Value -is [int] -or $Value -is [long] -or $Value -is [double] -or $Value -is [decimal]) {
return $Value
}
if ($Value -is [System.Collections.IDictionary]) {
$result = [ordered]@{}
foreach ($key in @($Value.Keys | Sort-Object)) {
$result[[string]$key] = ConvertTo-TestBgwMergeStableValue -Value $Value[$key]
}
Write-Output -NoEnumerate $result
return
}
if ($Value -is [pscustomobject]) {
$result = [ordered]@{}
foreach ($property in @($Value.PSObject.Properties | Sort-Object Name)) {
$result[$property.Name] = ConvertTo-TestBgwMergeStableValue -Value $property.Value
}
Write-Output -NoEnumerate $result
return
}
if ($Value -is [System.Collections.IEnumerable] -and $Value -isnot [string]) {
$items = New-Object System.Collections.Generic.List[object]
foreach ($item in $Value) {
$items.Add((ConvertTo-TestBgwMergeStableValue -Value $item))
}
Write-Output -NoEnumerate $items.ToArray()
return
}
return $Value
}
function ConvertTo-TestBgwMergeStableJson {
param([object]$Value)
(ConvertTo-TestBgwMergeStableValue -Value $Value) | ConvertTo-Json -Depth 100 -Compress
}
function Invoke-TestBgwMergeSnapshotScript {
param([string]$Script)
$encodedCommand = [Convert]::ToBase64String([System.Text.Encoding]::Unicode.GetBytes($Script))
$output = & powershell.exe -NoProfile -ExecutionPolicy Bypass -EncodedCommand $encodedCommand
if ($LASTEXITCODE -ne 0) {
throw "Snapshot PowerShell process failed with exit code [$LASTEXITCODE]. Output: $($output -join [Environment]::NewLine)"
}
$json = ($output | Where-Object { -not [string]::IsNullOrWhiteSpace($_) }) -join [Environment]::NewLine
if ([string]::IsNullOrWhiteSpace($json)) {
throw 'Snapshot PowerShell process returned no JSON output.'
}
$json | ConvertFrom-Json
}
function New-TestBgwMergeSnapshotScript {
param(
[string]$ConfigurationDataPath,
[switch]$BuildLocalBaseline
)
$escapedBgwRoot = $BgwRoot.Replace("'", "''")
$escapedMergeModulePath = $MergeModulePath.Replace("'", "''")
$escapedResolveModulePath = $ResolveModulePath.Replace("'", "''")
$escapedConfigurationDataPath = if ($ConfigurationDataPath) { $ConfigurationDataPath.Replace("'", "''") } else { '' }
$buildLocalBaselineText = if ($BuildLocalBaseline) { 'True' } else { 'False' }
@"
`$ErrorActionPreference = 'Stop'
`$ProgressPreference = 'SilentlyContinue'
Import-Module '$escapedMergeModulePath' -Force
Import-Module '$escapedResolveModulePath' -Force
function ConvertTo-SnapshotStableValue {
param([object]`$Value)
if (`$null -eq `$Value) { return `$null }
if (`$Value -is [string] -or `$Value -is [bool] -or `$Value -is [int] -or `$Value -is [long] -or `$Value -is [double] -or `$Value -is [decimal]) { return `$Value }
if (`$Value -is [System.Collections.IDictionary]) {
`$result = [ordered]@{}
foreach (`$key in @(`$Value.Keys | Sort-Object)) {
`$result[[string]`$key] = ConvertTo-SnapshotStableValue -Value `$Value[`$key]
}
Write-Output -NoEnumerate `$result
return
}
if (`$Value -is [pscustomobject]) {
`$result = [ordered]@{}
foreach (`$property in @(`$Value.PSObject.Properties | Sort-Object Name)) {
`$result[`$property.Name] = ConvertTo-SnapshotStableValue -Value `$property.Value
}
Write-Output -NoEnumerate `$result
return
}
if (`$Value -is [System.Collections.IEnumerable] -and `$Value -isnot [string]) {
`$items = New-Object System.Collections.Generic.List[object]
foreach (`$item in `$Value) {
`$items.Add((ConvertTo-SnapshotStableValue -Value `$item))
}
Write-Output -NoEnumerate `$items.ToArray()
return
}
return `$Value
}
function ConvertTo-SnapshotStableJson {
param([object]`$Value)
(ConvertTo-SnapshotStableValue -Value `$Value) | ConvertTo-Json -Depth 100 -Compress
}
if ('$buildLocalBaselineText' -eq 'True') {
`$root = '$escapedBgwRoot'
`$sourceTemplates = @(
(Join-Path -Path `$root -ChildPath 'Environment\Test.psd1')
(Join-Path -Path `$root -ChildPath 'Domain\Contoso.psd1')
(Join-Path -Path `$root -ChildPath 'Service\SharePoint\Contoso.psd1')
(Join-Path -Path `$root -ChildPath 'Stage\Install.psd1')
)
`$allNodes = @(
@{ NodeName = 'CLD-SHP-01'; RunCentralAdministration = `$true }
@{ NodeName = 'CLD-SHP-02'; RunCentralAdministration = `$false }
@{ NodeName = 'CLD-SHP-03'; RunCentralAdministration = `$false }
)
`$configurationData = New-DSCConfigurationDataDeployment -Name 'Contoso-Test-SharePoint' -DeploymentId '8f6c2c1a' -SourceTemplatePath `$sourceTemplates -AllNodes `$allNodes
}
else {
`$configurationData = Import-PowerShellDataFile -LiteralPath '$escapedConfigurationDataPath'
}
`$resolved = Resolve-DSCConfigurationData -ConfigurationData `$configurationData -SkipSecrets
`$snapshot = [ordered]@{
ParametersJson = ConvertTo-SnapshotStableJson -Value `$configurationData.Parameters
VariablesJson = ConvertTo-SnapshotStableJson -Value `$configurationData.Variables
ResourcesJson = ConvertTo-SnapshotStableJson -Value `$configurationData.Resources
DatabasePrefix = `$resolved.Variables.DatabasePrefix
ServiceDbPrefix = `$resolved.Variables.ServiceDbPrefix
ConfigDbName = `$resolved.Variables.ConfigDbName
LcmConfigurationMode = `$resolved.Resources.NonNodeData.LocalConfigurationManager.ConfigurationMode
AllNodes = @(`$resolved.Resources.AllNodes | Sort-Object NodeName | ForEach-Object {
[ordered]@{
NodeName = `$_.NodeName
RunCentralAdministration = `$_.RunCentralAdministration
}
})
}
`$snapshot | ConvertTo-Json -Depth 100 -Compress
"@
}
function New-TestBgwMergeLocalSnapshot {
Invoke-TestBgwMergeSnapshotScript -Script (New-TestBgwMergeSnapshotScript -BuildLocalBaseline)
}
function New-TestBgwMergeSnapshotFromConfigurationData {
param([hashtable]$ConfigurationData)
Import-Module $MergeModulePath -Force
$tempPath = Join-Path -Path ([System.IO.Path]::GetTempPath()) -ChildPath ("BgwMergeApiSnapshot-{0}.psd1" -f ([guid]::NewGuid().ToString('N')))
try {
Export-PowerShellDataFile -InputObject $ConfigurationData -Path $tempPath -Force
Invoke-TestBgwMergeSnapshotScript -Script (New-TestBgwMergeSnapshotScript -ConfigurationDataPath $tempPath)
}
finally {
if (Test-Path -LiteralPath $tempPath) {
Remove-Item -LiteralPath $tempPath -Force
}
}
}
function New-TestBgwMergeApiConfigurationData {
param([object]$Composition)
Import-Module $MergeModulePath -Force
$mergedTemplateData = @{}
foreach ($selection in @($Composition.templateSelections | Sort-Object sortOrder)) {
$templateData = ConvertFrom-TestBgwMergeTemplateJson -JsonData $selection.templateVersion.jsonData
$mergedTemplateData = Merge-DSCConfigurationData -Template $mergedTemplateData -Deployment $templateData
}
$deploymentData = @{
Resources = @{
AllNodes = ConvertFrom-TestBgwMergeTargetAssignments -TargetAssignments @($Composition.targetAssignments)
}
}
Merge-DSCConfigurationData -Template $mergedTemplateData -Deployment $deploymentData
}
Describe 'BGW Test.Merge.ps1 API DemoData composition' {
BeforeAll {
$script:expectedTemplateAliases = @(
'Environment-Test'
'Domain-Contoso'
'Service-SharePoint-Contoso'
'Stage-Install'
)
$script:expectedTemplateRoles = @(
'Environment'
'Domain'
'Service'
'Stage'
)
$script:localSnapshot = New-TestBgwMergeLocalSnapshot
$script:apiComposition = Invoke-TestBgwMergeApiJson -Method GET -Path "deployment-batches/$DeploymentBatchId/composition"
$script:apiConfigurationData = New-TestBgwMergeApiConfigurationData -Composition $script:apiComposition
$script:apiSnapshot = New-TestBgwMergeSnapshotFromConfigurationData -ConfigurationData $script:apiConfigurationData
}
It 'loads the seeded deployment composition from the API' {
$script:apiComposition.deploymentBatchId | Should Be $DeploymentBatchId
@($script:apiComposition.templateSelections).Count | Should Be 4
@($script:apiComposition.targetAssignments).Count | Should Be 3
}
It 'keeps the template selection order from Test.Merge.ps1' {
$aliases = @($script:apiComposition.templateSelections | Sort-Object sortOrder | ForEach-Object { $_.alias })
$roles = @($script:apiComposition.templateSelections | Sort-Object sortOrder | ForEach-Object { $_.templateRole })
($aliases -join '|') | Should Be ($script:expectedTemplateAliases -join '|')
($roles -join '|') | Should Be ($script:expectedTemplateRoles -join '|')
}
It 'keeps the AllNodes data from Test.Merge.ps1' {
$nodes = @($script:apiSnapshot.AllNodes | Sort-Object NodeName)
$nodes.Count | Should Be 3
$nodes[0].NodeName | Should Be 'CLD-SHP-01'
$nodes[0].RunCentralAdministration | Should Be $true
$nodes[1].NodeName | Should Be 'CLD-SHP-02'
$nodes[1].RunCentralAdministration | Should Be $false
$nodes[2].NodeName | Should Be 'CLD-SHP-03'
$nodes[2].RunCentralAdministration | Should Be $false
}
It 'resolves the same core values as the local Test.Merge.ps1 baseline' {
$script:apiSnapshot.DatabasePrefix | Should Be $script:localSnapshot.DatabasePrefix
$script:apiSnapshot.ServiceDbPrefix | Should Be $script:localSnapshot.ServiceDbPrefix
$script:apiSnapshot.ConfigDbName | Should Be $script:localSnapshot.ConfigDbName
$script:apiSnapshot.LcmConfigurationMode | Should Be $script:localSnapshot.LcmConfigurationMode
}
It 'matches merged Parameters, Variables and Resources' {
$script:apiSnapshot.ParametersJson | Should Be $script:localSnapshot.ParametersJson
$script:apiSnapshot.VariablesJson | Should Be $script:localSnapshot.VariablesJson
$script:apiSnapshot.ResourcesJson | Should Be $script:localSnapshot.ResourcesJson
}
}

View File

@@ -0,0 +1,42 @@
[CmdletBinding()]
param(
[string]$ApiBaseUrl = 'http://localhost:5286/api',
[string]$BgwRoot = ('F:\Kunden Auftr' + [char]0x00E4 + 'ge\BGW'),
[string]$DeploymentBatchId = '80000000-0000-0000-0000-000000000101',
[string]$MergeModulePath = 'F:\Projekte\Coding\PowerShell\Merge-DSCConfigurationData\Merge-DSCConfigurationData.psd1',
[string]$ResolveModulePath = 'F:\Projekte\Coding\PowerShell\Resolve-DSCConfigurationData\Resolve-DSCConfigurationData.psd1',
[int]$ApiTimeoutSec = 30,
[switch]$UseDefaultCredentials = $true
)
$ErrorActionPreference = 'Stop'
$testPath = Join-Path -Path $PSScriptRoot -ChildPath 'BgwMerge.Api.Tests.ps1'
if (-not (Test-Path -LiteralPath $testPath -PathType Leaf)) {
throw "Pester test file [$testPath] was not found."
}
if (-not (Get-Command Invoke-Pester -ErrorAction SilentlyContinue)) {
throw 'Pester is required. Install-Module Pester or run this on a machine where Pester is available.'
}
$parameters = @{
ApiBaseUrl = $ApiBaseUrl
BgwRoot = $BgwRoot
DeploymentBatchId = $DeploymentBatchId
MergeModulePath = $MergeModulePath
ResolveModulePath = $ResolveModulePath
ApiTimeoutSec = $ApiTimeoutSec
UseDefaultCredentials = [bool]$UseDefaultCredentials
}
$result = Invoke-Pester -Script @{ Path = $testPath; Parameters = $parameters } -PassThru
if ($result.FailedCount -gt 0) {
throw "Pester test run failed. Passed=[$($result.PassedCount)] Failed=[$($result.FailedCount)] Skipped=[$($result.SkippedCount)]."
}

View File

@@ -93,6 +93,21 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
modelBuilder.Entity<QueueJobModel>()
.ToTable("DeploymentJobs");
modelBuilder.Entity<QueueJobModel>()
.HasIndex(job => new { job.Status, job.ScheduledAt, job.LockedUntil, job.Priority, job.Created });
modelBuilder.Entity<QueueJobModel>()
.HasIndex(job => job.CorrelationId);
modelBuilder.Entity<QueueJobModel>()
.HasIndex(job => job.WorkerName);
modelBuilder.Entity<QueueJobModel>()
.Property(job => job.CorrelationId)
.HasDefaultValueSql("NEWID()");
modelBuilder.Entity<QueueJobModel>()
.Property(job => job.Priority)
.HasDefaultValue(100);
modelBuilder.Entity<QueueJobModel>()
.Property(job => job.RowVersion)
.IsRowVersion();
modelBuilder.Entity<QueueJobTargetModel>()
.ToTable("DeploymentJobTargets");
@@ -102,6 +117,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
modelBuilder.Entity<QueueJobTargetModel>()
.Property(target => target.DeploymentGroupId)
.HasColumnName("DeploymentBatchId");
modelBuilder.Entity<QueueJobTargetModel>()
.HasIndex(target => new { target.QueueJobId, target.Status });
modelBuilder.Entity<QueueJobTargetModel>()
.ToTable(table => table.HasCheckConstraint("CK_DeploymentJobTargets_OutputMetadataJson_IsJson", "[OutputMetadataJson] IS NULL OR ISJSON([OutputMetadataJson]) = 1"));
modelBuilder.Entity<QueueJobStepModel>()
.ToTable("DeploymentJobSteps");
@@ -111,6 +130,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
modelBuilder.Entity<QueueJobStepModel>()
.Property(step => step.DependsOnQueueJobStepId)
.HasColumnName("DependsOnDeploymentJobStepId");
modelBuilder.Entity<QueueJobStepModel>()
.HasIndex(step => new { step.QueueJobId, step.Status, step.SortOrder });
modelBuilder.Entity<QueueJobStepModel>()
.ToTable(table => table.HasCheckConstraint("CK_DeploymentJobSteps_OutputMetadataJson_IsJson", "[OutputMetadataJson] IS NULL OR ISJSON([OutputMetadataJson]) = 1"));
modelBuilder.Entity<DeploymentModel>()
.HasKey(d => new { d.TargetId, d.DeploymentGroupId });

View File

@@ -0,0 +1,419 @@
namespace Microsoft.SelfService.Portal.Core.API.Context
{
internal static partial class DemoData
{
private const string BgwEnvironmentTestTemplateJson = """
{
"schemaVersion": "1.0",
"templateType": "Environment",
"metadata": {
"TemplateType": "Environment",
"Name": "Test"
},
"parameters": {
"Landscape": {
"DefaultValue": "Prod",
"Value": "Test",
"Type": "string",
"AllowedValues": [
"Prod",
"QA",
"Test"
]
}
},
"variables": {
"AdminDbName": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), \u0027Farm_AdminContent\u0027)]",
"ContentDbPrefix": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), parameters(\u0027ContentDatabaseSegment\u0027))]",
"ServiceDbPrefix": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), parameters(\u0027ServiceDatabaseSegment\u0027))]",
"DatabasePrefix": "[joinNotEmpty(\u0027_\u0027, parameters(\u0027DatabasePrefix\u0027), parameters(\u0027DomainLabel\u0027), if(equals(parameters(\u0027Landscape\u0027), \u0027Test\u0027), \u0027Test\u0027, \u0027\u0027))]",
"ConfigDbName": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), \u0027Farm_Config\u0027)]"
},
"resources": {
}
}
""";
private const string BgwDomainContosoTemplateJson = """
{
"schemaVersion": "1.0",
"templateType": "Domain",
"metadata": {
"TemplateType": "Domain",
"Name": "Contoso"
},
"parameters": {
"DomainFQDN": {
"DefaultValue": "",
"Pattern": "^[A-Za-z0-9.-]+$",
"Type": "string",
"Value": "contoso.local",
"Required": true
},
"DomainLabel": {
"Type": "string",
"MaxLength": 32,
"Value": "Contoso",
"DefaultValue": "",
"Pattern": "^[A-Za-z][A-Za-z0-9_-]*$",
"MinLength": 2,
"Required": false
},
"DomainNetBIOS": {
"Type": "string",
"MaxLength": 15,
"Value": "CONTOSO",
"DefaultValue": "",
"Pattern": "^[A-Za-z0-9_-]+$",
"MinLength": 1,
"Required": true
}
},
"variables": {
},
"resources": {
"NonNodeData": {
"Services": {
"ActiveDirectory": {
"NetBIOSName": "[parameters(\u0027DomainNetBIOS\u0027)]",
"DomainName": "[parameters(\u0027DomainFQDN\u0027)]"
}
}
}
}
}
""";
private const string BgwSharePointContosoTemplateJson = """
{
"schemaVersion": "1.0",
"templateType": "Service",
"metadata": {
"TemplateType": "Service",
"Name": "SharePoint.Contoso"
},
"parameters": {
"FarmCredential": {
"Sensitive": true,
"Value": {
"Provider": "SecretManagement",
"Vault": "Test",
"Name": "Windows/SharePoint/FarmAccount"
},
"Type": "credential",
"Required": true
},
"ContentDatabaseSegment": {
"DefaultValue": "Content",
"Type": "string",
"Metadata": {
"Description": {
"de-DE": "Namenssegment fuer SharePoint-Content-Datenbanken innerhalb des Datenbanknamens.",
"en-US": "Name segment used for SharePoint content databases within the database name."
}
}
},
"ServiceApplicationPoolDefault": {
"DefaultValue": "SharePoint Service Applications",
"Type": "string",
"Metadata": {
"Description": {
"de-DE": "Anzeigename des Standard-Application-Pools fuer SharePoint-Serviceanwendungen.",
"en-US": "Display name of the default application pool for SharePoint service applications."
}
}
},
"WebApplicationPoolDefault": {
"DefaultValue": "SharePoint Web Applications",
"Type": "string",
"Metadata": {
"Description": {
"de-DE": "Anzeigename des Standard-Application-Pools fuer SharePoint-Webanwendungen.",
"en-US": "Display name of the default application pool for SharePoint web applications."
}
}
},
"DatabaseServerName": {
"DefaultValue": "SQL_Server",
"Type": "string",
"Value": "CL-SQL-01"
},
"WebApplicationPoolDefaultAccount": {
"DefaultValue": "SVC_SHP_WAP",
"Type": "string",
"Metadata": {
"Description": {
"de-DE": "Kontoname fuer den Standard-Application-Pool der SharePoint-Webanwendungen.",
"en-US": "Account name used by the default application pool for SharePoint web applications."
}
}
},
"ServiceDatabaseSegment": {
"DefaultValue": "Services",
"Type": "string",
"Metadata": {
"Description": {
"de-DE": "Namenssegment fuer SharePoint-Service-Datenbanken innerhalb des Datenbanknamens.",
"en-US": "Name segment used for SharePoint service databases within the database name."
}
}
},
"FarmPassphrase": {
"Sensitive": true,
"Value": {
"Provider": "SecretManagement",
"Vault": "Test",
"Name": "Windows/SharePoint/FarmPassphrase"
},
"Type": "credential",
"Required": true
},
"DatabaseInstanceName": {
"DefaultValue": "SQL_Server",
"Type": "string",
"Value": "SQLServer"
},
"DatabaseTcpPort": {
"DefaultValue": 1433,
"Type": "int",
"Value": 1433
},
"DefaultServiceApplicationPoolAccount": {
"Metadata": {
"Description": {
"de-DE": "Kontoname fuer den Standard-Application-Pool der SharePoint-Serviceanwendungen.",
"en-US": "Account name used by the default application pool for SharePoint service applications."
}
},
"Sensitive": true,
"Value": {
"Provider": "SecretManagement",
"Vault": "Test",
"Name": "Windows/SharePoint/DefaultServiceAccount"
},
"Type": "credential",
"Required": true
},
"ProductKey": {
"DefaultValue": "0000-0000-0000-0000-0000",
"Type": "string",
"Metadata": {
"Description": {
"de-DE": "SharePoint-Produktlizenzschluessel.",
"en-US": "SharePoint product license key."
}
}
},
"SetupCredential": {
"Sensitive": true,
"Value": {
"Provider": "SecretManagement",
"Vault": "Test",
"Name": "Windows/SharePoint/SetupAccount"
},
"Type": "credential",
"Required": true
},
"DatabasePrefix": {
"DefaultValue": "SharePoint",
"Type": "string",
"Value": "SharePoint"
},
"SearchServiceApplicationPoolAccount": {
"Metadata": {
"Description": {
"de-DE": "Kontoname fuer den Search-Application-Pool der SharePoint-Serviceanwendungen.",
"en-US": "Account name used by the search application pool for SharePoint service applications."
}
},
"Sensitive": true,
"Value": {
"Provider": "SecretManagement",
"Vault": "Test",
"Name": "Windows/SharePoint/SearchAccount"
},
"Type": "credential",
"Required": true
},
"CentralAdminPort": {
"DefaultValue": 443,
"Type": "int",
"Value": 4000
},
"ServiceApplicationPoolSearch": {
"DefaultValue": "SharePoint Search Service Applications",
"Type": "string",
"Metadata": {
"Description": {
"de-DE": "Anzeigename des Application-Pools fuer SharePoint Search-Serviceanwendungen.",
"en-US": "Display name of the application pool for SharePoint Search service applications."
}
}
}
},
"variables": {
"AdminDbName": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), \u0027Farm_AdminContent\u0027)]",
"ContentDbPrefix": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), parameters(\u0027ContentDatabaseSegment\u0027))]",
"ServiceDbPrefix": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), parameters(\u0027ServiceDatabaseSegment\u0027))]",
"DatabasePrefix": "[joinNotEmpty(\u0027_\u0027, parameters(\u0027DatabasePrefix\u0027), parameters(\u0027DomainLabel\u0027), if(equals(parameters(\u0027Landscape\u0027), \u0027Test\u0027), \u0027Test\u0027, \u0027\u0027))]",
"ConfigDbName": "[joinNotEmpty(\u0027_\u0027, variables(\u0027DatabasePrefix\u0027), \u0027Farm_Config\u0027)]"
},
"resources": {
"AllNodes": [
{
"PSDscAllowDomainUser": true,
"PSDSCAllowPlainTextPassword": true,
"NodeName": "*",
"RunCentralAdministration": false
}
],
"NonNodeData": {
"Services": {
"SharePoint": {
"Farm": {
"ManagedAccounts": {
"DefaultServiceApplicationPoolAccount": "[parameters(\u0027DefaultServiceApplicationPoolAccount\u0027)]",
"FarmAccount": "[parameters(\u0027FarmCredential\u0027)]",
"SearchServiceApplicationPoolAccount": "[parameters(\u0027SearchServiceApplicationPoolAccount\u0027)]"
},
"Passphrase": "[parameters(\u0027FarmPassphrase\u0027)]",
"ServiceApplications": {
"AppManagementService": {
"DatabaseName": "[concat(variables(\u0027ServiceDbPrefix\u0027),\u0027AppManagement\u0027)]",
"ApplicationPool": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ServiceApplicationPools.DefaultServiceApplicationPool\u0027, \u0027Name\u0027)]",
"Provision": true
},
"StateService": {
"DatabaseName": "[concat(variables(\u0027ServiceDbPrefix\u0027),\u0027StateService\u0027)]",
"Provision": true
},
"SubscriptionSettingsService": {
"DatabaseName": "[concat(variables(\u0027ServiceDbPrefix\u0027),\u0027SubscriptionSettings\u0027)]",
"ApplicationPool": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ServiceApplicationPools.DefaultServiceApplicationPool\u0027, \u0027Name\u0027)]",
"Provision": true
},
"ManagedMetadataService": {
"Name": "Managed Metadata Service",
"DatabaseName": "[concat(variables(\u0027ServiceDbPrefix\u0027), \u0027ManagedMetadata\u0027)]",
"ApplicationPool": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ServiceApplicationPools.DefaultServiceApplicationPool\u0027, \u0027Name\u0027)]",
"Provision": true
},
"SearchService": {
"Name": "Search Service Application",
"DatabaseName": "[concat(variables(\u0027ServiceDbPrefix\u0027),\u0027Search\u0027)]",
"ApplicationPool": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ServiceApplicationPools.SearchServiceApplicationPool\u0027, \u0027Name\u0027)]",
"Provision": true
},
"UsageAndHealthService": {
"DatabaseName": "[concat(variables(\u0027ServiceDbPrefix\u0027),\u0027UsageAndHealth\u0027)]",
"Provision": true
},
"SecureStoreService": {
"Name": "Secure Store Service",
"DatabaseName": "[concat(variables(\u0027ServiceDbPrefix\u0027),\u0027SecureStore\u0027)]",
"ApplicationPool": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ServiceApplicationPools.DefaultServiceApplicationPool\u0027, \u0027Name\u0027)]",
"Provision": true,
"AuditingEnabled": true
},
"UserProfileService": {
"SyncDBName": "[concat(variables(\u0027ServiceDbPrefix\u0027), \u0027UserProfile_Sync\u0027)]",
"ApplicationPool": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ServiceApplicationPools.DefaultServiceApplicationPool\u0027, \u0027Name\u0027)]",
"Provision": true,
"Name": "User Profile Service",
"SocialDBName": "[concat(variables(\u0027ServiceDbPrefix\u0027), \u0027UserProfile_Social\u0027)]",
"ProfileDBName": "[concat(variables(\u0027ServiceDbPrefix\u0027), \u0027UserProfile_Profile\u0027)]"
}
},
"CentralAdminAuth": "NTLM",
"ConfigDatabaseName": "[variables(\u0027ConfigDbName\u0027)]",
"Accounts": {
"SetupAccount": "[parameters(\u0027SetupCredential\u0027)]"
},
"CentralAdminPort": "[parameters(\u0027CentralAdminPort\u0027)]",
"AdminContentDatabase": "[variables(\u0027AdminDbName\u0027)]",
"ServiceApplicationPools": {
"SearchServiceApplicationPool": {
"Account": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ManagedAccounts.SearchServiceApplicationPoolAccount\u0027, \u0027UserName\u0027)]",
"Name": "[parameters(\u0027ServiceApplicationPoolSearch\u0027)]"
},
"DefaultServiceApplicationPool": {
"Account": "[reference(\u0027Resources.NonNodeData.Services.SharePoint.Farm.ManagedAccounts.DefaultServiceApplicationPoolAccount\u0027, \u0027UserName\u0027)]",
"Name": "[parameters(\u0027ServiceApplicationPoolDefault\u0027)]"
}
}
},
"Database": {
"Targets": {
"Farm": {
"Server": "SQLServer",
"DependsOnAlias": "SQLServer"
},
"Content": {
"Server": "SQLServer",
"DependsOnAlias": "SQLServer"
},
"Service": {
"Server": "SQLServer",
"DependsOnAlias": "SQLServer"
}
},
"SQLAlias": {
"SQLServer": {
"InstanceName": "[parameters(\u0027DatabaseInstanceName\u0027)]",
"ServerName": "[parameters(\u0027DatabaseServerName\u0027)]",
"Protocol": "TCP",
"TcpPort": "[parameters(\u0027DatabaseTcpPort\u0027)]"
}
}
},
"General": {
"ProductKey": "[parameters(\u0027ProductKey\u0027)]"
},
"Windows": {
"Registry": {
"DisableLoopbackCheck": {
"Path": "HKLM:\\SYSTEM\\CurrentControlSet\\Control\\Lsa",
"Name": "DisableLoopbackCheck",
"Value": 1,
"Type": "DWord"
}
}
}
}
}
}
}
}
""";
private const string BgwStageInstallTemplateJson = """
{
"schemaVersion": "1.0",
"templateType": "Stage",
"metadata": {
"TemplateType": "Stage",
"Name": "Install"
},
"parameters": {
},
"variables": {
},
"resources": {
"NonNodeData": {
"LocalConfigurationManager": {
"RefreshFrequencyMins": "30",
"RefreshMode": "PUSH",
"ConfigurationModeFrequencyMins": "120",
"ConfigurationMode": "ApplyOnly"
}
}
}
}
""";
}
}

View File

@@ -3,7 +3,7 @@ using Microsoft.SelfService.Portal.Core.API.Models;
namespace Microsoft.SelfService.Portal.Core.API.Context
{
internal static class DemoData
internal static partial class DemoData
{
private static readonly DateTime Timestamp = new(2026, 7, 7, 0, 0, 0, DateTimeKind.Utc);
private const string Owner = "DemoSeed";
@@ -22,16 +22,21 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
internal static readonly Guid VmSp02Id = Guid.Parse("30000000-0000-0000-0000-000000000005");
internal static readonly Guid TargetM365TenantId = Guid.Parse("30000000-0000-0000-0000-000000000006");
internal static readonly Guid TargetTeamsPolicyScopeId = Guid.Parse("30000000-0000-0000-0000-000000000007");
internal static readonly Guid TargetBgwSp01Id = Guid.Parse("30000000-0000-0000-0000-000000000101");
internal static readonly Guid TargetBgwSp02Id = Guid.Parse("30000000-0000-0000-0000-000000000102");
internal static readonly Guid TargetBgwSp03Id = Guid.Parse("30000000-0000-0000-0000-000000000103");
internal static readonly Guid ServiceActiveDirectoryId = Guid.Parse("40000000-0000-0000-0000-000000000001");
internal static readonly Guid ServiceSqlServerId = Guid.Parse("40000000-0000-0000-0000-000000000002");
internal static readonly Guid ServiceSharePointId = Guid.Parse("40000000-0000-0000-0000-000000000003");
internal static readonly Guid ServiceTeamsId = Guid.Parse("40000000-0000-0000-0000-000000000004");
internal static readonly Guid ServiceConfigurationDataId = Guid.Parse("40000000-0000-0000-0000-000000000101");
internal static readonly Guid CategoryActiveDirectoryId = Guid.Parse("50000000-0000-0000-0000-000000000001");
internal static readonly Guid CategorySqlServerId = Guid.Parse("50000000-0000-0000-0000-000000000002");
internal static readonly Guid CategorySharePointId = Guid.Parse("50000000-0000-0000-0000-000000000003");
internal static readonly Guid CategoryTeamsId = Guid.Parse("50000000-0000-0000-0000-000000000004");
internal static readonly Guid CategoryBgwMergeTemplatesId = Guid.Parse("50000000-0000-0000-0000-000000000101");
internal static readonly Guid RuleStandardId = Guid.Parse("60000000-0000-0000-0000-000000000001");
internal static readonly Guid RuleStepValidateId = Guid.Parse("60000000-0000-0000-0000-000000000101");
@@ -42,20 +47,39 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
internal static readonly Guid TemplateSqlServerId = Guid.Parse("70000000-0000-0000-0000-000000000002");
internal static readonly Guid TemplateSharePointId = Guid.Parse("70000000-0000-0000-0000-000000000003");
internal static readonly Guid TemplateTeamsId = Guid.Parse("70000000-0000-0000-0000-000000000004");
internal static readonly Guid TemplateBgwEnvironmentTestId = Guid.Parse("70000000-0000-0000-0000-000000000101");
internal static readonly Guid TemplateBgwDomainContosoId = Guid.Parse("70000000-0000-0000-0000-000000000102");
internal static readonly Guid TemplateBgwSharePointContosoId = Guid.Parse("70000000-0000-0000-0000-000000000103");
internal static readonly Guid TemplateBgwStageInstallId = Guid.Parse("70000000-0000-0000-0000-000000000104");
internal static readonly Guid TemplateActiveDirectoryVersionId = Guid.Parse("71000000-0000-0000-0000-000000000001");
internal static readonly Guid TemplateSqlServerVersionId = Guid.Parse("71000000-0000-0000-0000-000000000002");
internal static readonly Guid TemplateSharePointVersionId = Guid.Parse("71000000-0000-0000-0000-000000000003");
internal static readonly Guid TemplateTeamsVersionId = Guid.Parse("71000000-0000-0000-0000-000000000004");
internal static readonly Guid TemplateBgwEnvironmentTestVersionId = Guid.Parse("71000000-0000-0000-0000-000000000101");
internal static readonly Guid TemplateBgwDomainContosoVersionId = Guid.Parse("71000000-0000-0000-0000-000000000102");
internal static readonly Guid TemplateBgwSharePointContosoVersionId = Guid.Parse("71000000-0000-0000-0000-000000000103");
internal static readonly Guid TemplateBgwStageInstallVersionId = Guid.Parse("71000000-0000-0000-0000-000000000104");
internal static readonly Guid DeploymentBatchSharePointId = Guid.Parse("80000000-0000-0000-0000-000000000001");
internal static readonly Guid DeploymentBatchBgwMergeId = Guid.Parse("80000000-0000-0000-0000-000000000101");
internal static readonly Guid DeploymentSp01Id = Guid.Parse("81000000-0000-0000-0000-000000000001");
internal static readonly Guid DeploymentSp02Id = Guid.Parse("81000000-0000-0000-0000-000000000002");
internal static readonly Guid DeploymentBgwSp01Id = Guid.Parse("81000000-0000-0000-0000-000000000101");
internal static readonly Guid DeploymentBgwSp02Id = Guid.Parse("81000000-0000-0000-0000-000000000102");
internal static readonly Guid DeploymentBgwSp03Id = Guid.Parse("81000000-0000-0000-0000-000000000103");
internal static readonly Guid DeploymentSharePointTemplateSelectionId = Guid.Parse("82000000-0000-0000-0000-000000000001");
internal static readonly Guid DeploymentBgwEnvironmentSelectionId = Guid.Parse("82000000-0000-0000-0000-000000000101");
internal static readonly Guid DeploymentBgwDomainSelectionId = Guid.Parse("82000000-0000-0000-0000-000000000102");
internal static readonly Guid DeploymentBgwSharePointSelectionId = Guid.Parse("82000000-0000-0000-0000-000000000103");
internal static readonly Guid DeploymentBgwStageSelectionId = Guid.Parse("82000000-0000-0000-0000-000000000104");
internal static readonly Guid DeploymentParameterDatabasePrefixId = Guid.Parse("83000000-0000-0000-0000-000000000001");
internal static readonly Guid DeploymentParameterFarmAccountId = Guid.Parse("83000000-0000-0000-0000-000000000002");
internal static readonly Guid DeploymentTargetSp01Id = Guid.Parse("84000000-0000-0000-0000-000000000001");
internal static readonly Guid DeploymentTargetSp02Id = Guid.Parse("84000000-0000-0000-0000-000000000002");
internal static readonly Guid DeploymentTargetBgwSp01Id = Guid.Parse("84000000-0000-0000-0000-000000000101");
internal static readonly Guid DeploymentTargetBgwSp02Id = Guid.Parse("84000000-0000-0000-0000-000000000102");
internal static readonly Guid DeploymentTargetBgwSp03Id = Guid.Parse("84000000-0000-0000-0000-000000000103");
internal static void Seed(ModelBuilder modelBuilder)
{
@@ -105,7 +129,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
Base(new TargetModel { Id = VmSp01Id, DomainID = DomainCentralId, Name = "CT-SHP-01", TargetType = "VirtualMachine", ProviderType = "OnPrem", MetadataJson = "{\"role\":\"SharePoint\",\"environment\":\"Test\"}" }),
Base(new TargetModel { Id = VmSp02Id, DomainID = DomainCentralId, Name = "CT-SHP-02", TargetType = "VirtualMachine", ProviderType = "OnPrem", MetadataJson = "{\"role\":\"SharePoint\",\"environment\":\"Test\"}" }),
Base(new TargetModel { Id = TargetM365TenantId, Name = "contoso.onmicrosoft.com", TargetType = "Tenant", ProviderType = "Microsoft365", ExternalId = "11111111-1111-1111-1111-111111111111", MetadataJson = "{\"environment\":\"Production\",\"workload\":\"M365\"}" }),
Base(new TargetModel { Id = TargetTeamsPolicyScopeId, Name = "Teams - Standard Users", TargetType = "PolicyScope", ProviderType = "Microsoft365", ExternalId = "Teams.StandardUsers", MetadataJson = "{\"workload\":\"Teams\",\"scope\":\"StandardUsers\"}" })
Base(new TargetModel { Id = TargetTeamsPolicyScopeId, Name = "Teams - Standard Users", TargetType = "PolicyScope", ProviderType = "Microsoft365", ExternalId = "Teams.StandardUsers", MetadataJson = "{\"workload\":\"Teams\",\"scope\":\"StandardUsers\"}" }),
Base(new TargetModel { Id = TargetBgwSp01Id, DomainID = DomainCentralId, Name = "CLD-SHP-01", TargetType = "VirtualMachine", ProviderType = "OnPrem", MetadataJson = "{\"role\":\"SharePoint\",\"environment\":\"Test\",\"source\":\"Test.Merge.ps1\"}" }),
Base(new TargetModel { Id = TargetBgwSp02Id, DomainID = DomainCentralId, Name = "CLD-SHP-02", TargetType = "VirtualMachine", ProviderType = "OnPrem", MetadataJson = "{\"role\":\"SharePoint\",\"environment\":\"Test\",\"source\":\"Test.Merge.ps1\"}" }),
Base(new TargetModel { Id = TargetBgwSp03Id, DomainID = DomainCentralId, Name = "CLD-SHP-03", TargetType = "VirtualMachine", ProviderType = "OnPrem", MetadataJson = "{\"role\":\"SharePoint\",\"environment\":\"Test\",\"source\":\"Test.Merge.ps1\"}" })
];
private static object[] Services() =>
@@ -113,7 +140,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
Base(new ServiceModel { Id = ServiceActiveDirectoryId, Name = "Active Directory", Description = "On-premises directory and identity service.", IconKey = "network", IsCloudService = false }),
Base(new ServiceModel { Id = ServiceSqlServerId, Name = "SQL Server", Description = "Database platform for application workloads.", IconKey = "database", IsCloudService = false }),
Base(new ServiceModel { Id = ServiceSharePointId, Name = "SharePoint Server", Description = "Collaboration platform for on-premises workloads.", IconKey = "sharepoint", IsCloudService = false }),
Base(new ServiceModel { Id = ServiceTeamsId, Name = "Microsoft Teams", Description = "Cloud collaboration workload in Microsoft 365.", IconKey = "messages-square", IsCloudService = true })
Base(new ServiceModel { Id = ServiceTeamsId, Name = "Microsoft Teams", Description = "Cloud collaboration workload in Microsoft 365.", IconKey = "messages-square", IsCloudService = true }),
Base(new ServiceModel { Id = ServiceConfigurationDataId, Name = "DSC Configuration Data", Description = "Reusable configuration-data template building blocks for deployment composition.", IconKey = "braces", IsCloudService = false })
];
private static object[] ServiceRoleDefinitions() =>
@@ -129,7 +157,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
Base(new TemplateCategoryModel { Id = CategoryActiveDirectoryId, ServiceId = ServiceActiveDirectoryId, Name = "Domain Services", Description = "Templates for domain controller and domain configuration.", Color = "#2563EB", IsActive = true }),
Base(new TemplateCategoryModel { Id = CategorySqlServerId, ServiceId = ServiceSqlServerId, Name = "Database Platform", Description = "Templates for SQL Server workloads.", Color = "#16A34A", IsActive = true }),
Base(new TemplateCategoryModel { Id = CategorySharePointId, ServiceId = ServiceSharePointId, Name = "Collaboration Farm", Description = "Templates for SharePoint Server farms.", Color = "#0F766E", IsActive = true }),
Base(new TemplateCategoryModel { Id = CategoryTeamsId, ServiceId = ServiceTeamsId, Name = "Teams Policies", Description = "Templates for Teams policy configuration.", Color = "#7C3AED", IsActive = true })
Base(new TemplateCategoryModel { Id = CategoryTeamsId, ServiceId = ServiceTeamsId, Name = "Teams Policies", Description = "Templates for Teams policy configuration.", Color = "#7C3AED", IsActive = true }),
Base(new TemplateCategoryModel { Id = CategoryBgwMergeTemplatesId, ServiceId = ServiceConfigurationDataId, Name = "Test.Merge.ps1 Templates", Description = "Materialized template building blocks from the BGW Test.Merge.ps1 scenario.", Color = "#2563EB", IsActive = true })
];
private static object[] DeploymentRules() =>
@@ -149,7 +178,11 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
Base(new TemplateModel { Id = TemplateActiveDirectoryId, TemplateCategoryId = CategoryActiveDirectoryId, DeploymentRuleId = RuleStandardId, Name = "Contoso Active Directory Domain", Version = "1.0.0", Description = "Creates a reusable Active Directory domain baseline.", JSONData = ActiveDirectoryTemplateJson }),
Base(new TemplateModel { Id = TemplateSqlServerId, TemplateCategoryId = CategorySqlServerId, DeploymentRuleId = RuleStandardId, Name = "Contoso SQL Server", Version = "1.0.0", Description = "Creates a SQL Server baseline for application workloads.", JSONData = SqlServerTemplateJson }),
Base(new TemplateModel { Id = TemplateSharePointId, TemplateCategoryId = CategorySharePointId, DeploymentRuleId = RuleStandardId, Name = "Contoso SharePoint Server", Version = "1.0.0", Description = "Creates a SharePoint Server farm baseline.", JSONData = SharePointTemplateJson }),
Base(new TemplateModel { Id = TemplateTeamsId, TemplateCategoryId = CategoryTeamsId, DeploymentRuleId = RuleStandardId, Name = "Contoso Teams Policies", Version = "1.0.0", Description = "Creates a Microsoft Teams policy baseline.", JSONData = TeamsTemplateJson })
Base(new TemplateModel { Id = TemplateTeamsId, TemplateCategoryId = CategoryTeamsId, DeploymentRuleId = RuleStandardId, Name = "Contoso Teams Policies", Version = "1.0.0", Description = "Creates a Microsoft Teams policy baseline.", JSONData = TeamsTemplateJson }),
Base(new TemplateModel { Id = TemplateBgwEnvironmentTestId, TemplateCategoryId = CategoryBgwMergeTemplatesId, DeploymentRuleId = RuleStandardId, Name = "BGW Environment Test", Version = "1.0.0", Description = "Materialized Environment/Test.psd1 template from Test.Merge.ps1.", JSONData = BgwEnvironmentTestTemplateJson }),
Base(new TemplateModel { Id = TemplateBgwDomainContosoId, TemplateCategoryId = CategoryBgwMergeTemplatesId, DeploymentRuleId = RuleStandardId, Name = "BGW Domain Contoso", Version = "1.0.0", Description = "Materialized Domain/Contoso.psd1 template from Test.Merge.ps1.", JSONData = BgwDomainContosoTemplateJson }),
Base(new TemplateModel { Id = TemplateBgwSharePointContosoId, TemplateCategoryId = CategoryBgwMergeTemplatesId, DeploymentRuleId = RuleStandardId, Name = "BGW SharePoint Contoso", Version = "1.0.0", Description = "Materialized Service/SharePoint/Contoso.psd1 template from Test.Merge.ps1.", JSONData = BgwSharePointContosoTemplateJson }),
Base(new TemplateModel { Id = TemplateBgwStageInstallId, TemplateCategoryId = CategoryBgwMergeTemplatesId, DeploymentRuleId = RuleStandardId, Name = "BGW Stage Install", Version = "1.0.0", Description = "Materialized Stage/Install.psd1 template from Test.Merge.ps1.", JSONData = BgwStageInstallTemplateJson })
];
private static object[] TemplateVersions() =>
@@ -157,23 +190,35 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
TemplateVersion(TemplateActiveDirectoryVersionId, TemplateActiveDirectoryId, ActiveDirectoryTemplateJson),
TemplateVersion(TemplateSqlServerVersionId, TemplateSqlServerId, SqlServerTemplateJson),
TemplateVersion(TemplateSharePointVersionId, TemplateSharePointId, SharePointTemplateJson),
TemplateVersion(TemplateTeamsVersionId, TemplateTeamsId, TeamsTemplateJson)
TemplateVersion(TemplateTeamsVersionId, TemplateTeamsId, TeamsTemplateJson),
TemplateVersion(TemplateBgwEnvironmentTestVersionId, TemplateBgwEnvironmentTestId, BgwEnvironmentTestTemplateJson),
TemplateVersion(TemplateBgwDomainContosoVersionId, TemplateBgwDomainContosoId, BgwDomainContosoTemplateJson),
TemplateVersion(TemplateBgwSharePointContosoVersionId, TemplateBgwSharePointContosoId, BgwSharePointContosoTemplateJson),
TemplateVersion(TemplateBgwStageInstallVersionId, TemplateBgwStageInstallId, BgwStageInstallTemplateJson)
];
private static object[] DeploymentBatches() =>
[
Base(new DeploymentGroupModel { Id = DeploymentBatchSharePointId, TemplateId = TemplateSharePointId, DeploymentRuleId = RuleStandardId, Status = QueueJobStatus.Pending })
Base(new DeploymentGroupModel { Id = DeploymentBatchSharePointId, TemplateId = TemplateSharePointId, DeploymentRuleId = RuleStandardId, Status = QueueJobStatus.Pending }),
Base(new DeploymentGroupModel { Id = DeploymentBatchBgwMergeId, TemplateId = TemplateBgwSharePointContosoId, DeploymentRuleId = RuleStandardId, Status = QueueJobStatus.Pending })
];
private static object[] Deployments() =>
[
Base(new DeploymentModel { Id = DeploymentSp01Id, DeploymentGroupId = DeploymentBatchSharePointId, TargetId = VmSp01Id, Status = QueueJobStatus.Pending, JSONData = "{\"role\":\"WebFrontEnd\"}" }),
Base(new DeploymentModel { Id = DeploymentSp02Id, DeploymentGroupId = DeploymentBatchSharePointId, TargetId = VmSp02Id, Status = QueueJobStatus.Pending, JSONData = "{\"role\":\"Application\"}" })
Base(new DeploymentModel { Id = DeploymentSp02Id, DeploymentGroupId = DeploymentBatchSharePointId, TargetId = VmSp02Id, Status = QueueJobStatus.Pending, JSONData = "{\"role\":\"Application\"}" }),
Base(new DeploymentModel { Id = DeploymentBgwSp01Id, DeploymentGroupId = DeploymentBatchBgwMergeId, TargetId = TargetBgwSp01Id, Status = QueueJobStatus.Pending, JSONData = "{\"role\":\"Node\"}" }),
Base(new DeploymentModel { Id = DeploymentBgwSp02Id, DeploymentGroupId = DeploymentBatchBgwMergeId, TargetId = TargetBgwSp02Id, Status = QueueJobStatus.Pending, JSONData = "{\"role\":\"Node\"}" }),
Base(new DeploymentModel { Id = DeploymentBgwSp03Id, DeploymentGroupId = DeploymentBatchBgwMergeId, TargetId = TargetBgwSp03Id, Status = QueueJobStatus.Pending, JSONData = "{\"role\":\"Node\"}" })
];
private static object[] DeploymentTemplateSelections() =>
[
Base(new DeploymentTemplateSelectionModel { Id = DeploymentSharePointTemplateSelectionId, DeploymentGroupId = DeploymentBatchSharePointId, TemplateVersionId = TemplateSharePointVersionId, TemplateRole = "Service", SortOrder = 10, Alias = "SharePoint" })
Base(new DeploymentTemplateSelectionModel { Id = DeploymentSharePointTemplateSelectionId, DeploymentGroupId = DeploymentBatchSharePointId, TemplateVersionId = TemplateSharePointVersionId, TemplateRole = "Service", SortOrder = 10, Alias = "SharePoint" }),
Base(new DeploymentTemplateSelectionModel { Id = DeploymentBgwEnvironmentSelectionId, DeploymentGroupId = DeploymentBatchBgwMergeId, TemplateVersionId = TemplateBgwEnvironmentTestVersionId, TemplateRole = "Environment", SortOrder = 10, Alias = "Environment-Test" }),
Base(new DeploymentTemplateSelectionModel { Id = DeploymentBgwDomainSelectionId, DeploymentGroupId = DeploymentBatchBgwMergeId, TemplateVersionId = TemplateBgwDomainContosoVersionId, TemplateRole = "Domain", SortOrder = 20, Alias = "Domain-Contoso" }),
Base(new DeploymentTemplateSelectionModel { Id = DeploymentBgwSharePointSelectionId, DeploymentGroupId = DeploymentBatchBgwMergeId, TemplateVersionId = TemplateBgwSharePointContosoVersionId, TemplateRole = "Service", SortOrder = 30, Alias = "Service-SharePoint-Contoso" }),
Base(new DeploymentTemplateSelectionModel { Id = DeploymentBgwStageSelectionId, DeploymentGroupId = DeploymentBatchBgwMergeId, TemplateVersionId = TemplateBgwStageInstallVersionId, TemplateRole = "Stage", SortOrder = 40, Alias = "Stage-Install" })
];
private static object[] DeploymentParameterValues() =>
@@ -185,7 +230,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Context
private static object[] DeploymentTargetAssignments() =>
[
Base(new DeploymentTargetAssignmentModel { Id = DeploymentTargetSp01Id, DeploymentGroupId = DeploymentBatchSharePointId, TargetId = VmSp01Id, RoleKey = "WebFrontEnd", SortOrder = 10, NodeDataJson = "{\"nodeName\":\"CT-SHP-01\"}" }),
Base(new DeploymentTargetAssignmentModel { Id = DeploymentTargetSp02Id, DeploymentGroupId = DeploymentBatchSharePointId, TargetId = VmSp02Id, RoleKey = "Application", SortOrder = 20, NodeDataJson = "{\"nodeName\":\"CT-SHP-02\"}" })
Base(new DeploymentTargetAssignmentModel { Id = DeploymentTargetSp02Id, DeploymentGroupId = DeploymentBatchSharePointId, TargetId = VmSp02Id, RoleKey = "Application", SortOrder = 20, NodeDataJson = "{\"nodeName\":\"CT-SHP-02\"}" }),
Base(new DeploymentTargetAssignmentModel { Id = DeploymentTargetBgwSp01Id, DeploymentGroupId = DeploymentBatchBgwMergeId, TargetId = TargetBgwSp01Id, RoleKey = "Node", SortOrder = 10, NodeDataJson = "{\"nodeName\":\"CLD-SHP-01\",\"RunCentralAdministration\":true}" }),
Base(new DeploymentTargetAssignmentModel { Id = DeploymentTargetBgwSp02Id, DeploymentGroupId = DeploymentBatchBgwMergeId, TargetId = TargetBgwSp02Id, RoleKey = "Node", SortOrder = 20, NodeDataJson = "{\"nodeName\":\"CLD-SHP-02\",\"RunCentralAdministration\":false}" }),
Base(new DeploymentTargetAssignmentModel { Id = DeploymentTargetBgwSp03Id, DeploymentGroupId = DeploymentBatchBgwMergeId, TargetId = TargetBgwSp03Id, RoleKey = "Node", SortOrder = 30, NodeDataJson = "{\"nodeName\":\"CLD-SHP-03\",\"RunCentralAdministration\":false}" })
];
private static TemplateVersionModel TemplateVersion(Guid id, Guid templateId, string jsonData)

View File

@@ -34,16 +34,28 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
{
var deploymentBatches = _deploymentBatchInterface
.GetDeploymentBatches()
.Select(batch => new GetDeploymentBatchDto
.Select(batch =>
{
Id = batch.Id,
TemplateId = batch.TemplateId,
DeploymentRuleId = batch.DeploymentRuleId,
Status = batch.Status,
Created = batch.Created,
CreatedBy = batch.CreatedBy,
Modified = batch.Modified,
ModifiedBy = batch.ModifiedBy
var primarySelection = batch.TemplateSelections
.OrderBy(selection => selection.SortOrder)
.FirstOrDefault();
return new GetDeploymentBatchDto
{
Id = batch.Id,
TemplateId = batch.TemplateId,
DeploymentRuleId = batch.DeploymentRuleId,
Status = batch.Status,
Created = batch.Created,
CreatedBy = batch.CreatedBy,
Modified = batch.Modified,
ModifiedBy = batch.ModifiedBy,
PrimaryTemplateVersionId = primarySelection?.TemplateVersionId,
PrimaryTemplateName = primarySelection?.TemplateVersion?.Template?.Name,
PrimaryTemplateVersion = primarySelection?.TemplateVersion?.Version,
TemplateSelectionCount = batch.TemplateSelections.Count,
TargetAssignmentCount = batch.TargetAssignments.Count
};
})
.ToList();
@@ -80,6 +92,20 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
if (!ModelState.IsValid)
return BadRequest(ModelState);
if (deploymentBatch.TemplateVersionId.HasValue
&& (deploymentBatch.TemplateSelections == null || deploymentBatch.TemplateSelections.Count == 0))
{
deploymentBatch.TemplateSelections = new List<AddDeploymentTemplateSelectionDto>
{
new()
{
TemplateVersionId = deploymentBatch.TemplateVersionId.Value,
TemplateRole = "Service",
SortOrder = 10
}
};
}
var deploymentBatchMap = _mapper.Map<DeploymentGroupModel>(deploymentBatch);
if (!_deploymentBatchInterface.AddDeploymentBatchById(deploymentBatchMap, deploymentBatch.TargetIds))

View File

@@ -100,12 +100,6 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
if (request == null)
return BadRequest(ModelState);
if (request.TargetIds == null || request.TargetIds.Count == 0)
{
ModelState.AddModelError("", "At least one Target must be selected.");
return BadRequest(ModelState);
}
if (!ModelState.IsValid)
return BadRequest(ModelState);
@@ -149,6 +143,11 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
Started = job.Started,
Finished = job.Finished,
ErrorMessage = job.ErrorMessage,
CorrelationId = job.CorrelationId,
Priority = job.Priority,
ScheduledAt = job.ScheduledAt,
HeartbeatAt = job.HeartbeatAt,
WorkerName = job.WorkerName,
TargetCount = job.Targets.Count,
SucceededTargetCount = job.Targets.Count(target => target.Status == QueueJobStatus.Succeeded),
FailedTargetCount = job.Targets.Count(target => target.Status == QueueJobStatus.Failed)
@@ -185,6 +184,13 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
ErrorMessage = queueJob.ErrorMessage,
MetadataJson = queueJob.MetadataJson,
RuleSnapshotJson = queueJob.RuleSnapshotJson,
CorrelationId = queueJob.CorrelationId,
Priority = queueJob.Priority,
ScheduledAt = queueJob.ScheduledAt,
HeartbeatAt = queueJob.HeartbeatAt,
WorkerName = queueJob.WorkerName,
LockedBy = queueJob.LockedBy,
LockedUntil = queueJob.LockedUntil,
Created = queueJob.Created,
CreatedBy = queueJob.CreatedBy,
Modified = queueJob.Modified,
@@ -197,7 +203,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
TemplateId = target.TemplateId,
Status = target.Status,
Attempts = target.Attempts,
ErrorMessage = target.ErrorMessage
ErrorMessage = target.ErrorMessage,
Started = target.Started,
Finished = target.Finished,
OutputMetadataJson = target.OutputMetadataJson
}).ToList(),
Steps = queueJob.Steps
.OrderBy(step => step.SortOrder)
@@ -212,7 +221,11 @@ namespace Microsoft.SelfService.Portal.Core.API.Controllers
MetadataJson = step.MetadataJson,
ApprovedAt = step.ApprovedAt,
ApprovedBy = step.ApprovedBy,
ApprovalComment = step.ApprovalComment
ApprovalComment = step.ApprovalComment,
Started = step.Started,
Finished = step.Finished,
OutputMetadataJson = step.OutputMetadataJson,
ErrorMessage = step.ErrorMessage
}).ToList()
};

View File

@@ -0,0 +1,597 @@
# SelfService Portal Process
## Purpose
This document describes the current end-to-end process as understood for the SelfService Portal.
It is intentionally written as a business and platform flow, not as a low-level API reference.
The goal is to make visible how catalog data, reusable templates, deployment composition, queue jobs, and worker execution fit together.
## Big Picture
The portal is intended to become a generic configuration composition platform.
It should support on-premises workloads such as Active Directory, SQL Server, SharePoint, and Exchange, and also cloud workloads such as Teams, Azure, Microsoft 365, and Azure resources.
The important idea is:
```text
Reusable catalog data + immutable template versions + deployment-specific choices
-> composed deployment document
-> queue job
-> worker renders and executes
```
The database should know generic concepts such as environments, domains, targets, services, templates, template versions, deployment groups, queue jobs, and artifacts.
Workload-specific details, for example SharePoint farm accounts or Teams policies, belong inside versioned template documents.
## Roles Of The Applications
### Microsoft.SelfService.Portal.Core.API
The API owns the central data model and exposes it to the GUI and worker.
Responsibilities:
- Store catalog data such as environments, domains, services, targets, templates, and template versions.
- Store deployment composition data such as selected template versions, parameter overrides, and target assignments.
- Validate JSON documents before storing them.
- Create deployment queue jobs.
- Expose queue job status, steps, target progress, errors, and metadata.
### Microsoft.SelfService.Portal.Web
The web frontend is the user-facing surface.
Responsibilities:
- Let users browse catalog data.
- Let users create and edit deployment groups.
- Let users select template versions, targets, parameters, and later preview effective configuration data.
- Submit deployment requests into the API queue.
- Show queue job state and execution progress.
The current GUI is intentionally rudimentary. The later target is a richer interactive deployment builder.
### Microsoft.SelfService.Portal.Core.Worker
The worker processes queued deployment jobs.
Responsibilities:
- Claim jobs safely from the queue.
- Load deployment composition from the API database.
- Render the deployment composition into an artifact.
- Support different renderers, currently DSC v2 PowerShell data files and DSC v3 JSON.
- Later execute or hand off the rendered artifacts.
- Persist target and step output metadata.
## Catalog Process
### 1. Environments Are Defined
An environment is a logical deployment context, for example:
```text
Prod A
Test A
QA B
Prod B
Test B
```
An environment describes where something belongs and what stage it represents.
Examples of environment metadata:
- Stage: Test, QA, Production
- Hosting type: OnPrem, Azure, M365, Hybrid
- Provider type
- Tenant or subscription reference
### 2. Domains Are Defined Once And Linked
A domain is reusable catalog and configuration data.
It can be linked to multiple environments.
Example:
```text
Central-Management Domain
-> Test A
-> QA A
-> Prod A
```
The intent is that a domain configuration is not duplicated for every environment.
Instead, a domain baseline can be maintained once, then linked or promoted into the environments that should consume it.
Target process:
```text
Change Central-Management domain baseline
-> validate in Test
-> promote or reuse for Prod
```
Not desired:
```text
Maintain Central-Management Test separately
Maintain Central-Management Prod separately
Repeat every change manually
```
### 3. Services Describe Workload Families
A service represents a workload type, not a single deployment.
Examples:
- Active Directory
- SQL Server
- SharePoint
- Exchange
- Teams
- Azure Network
- Microsoft 365 Policies
Templates are categorized below services so users can find suitable building blocks.
### 4. Targets Are Generic
Targets are everything a deployment can act on.
They are not limited to virtual machines.
Examples:
- VirtualMachine
- Tenant
- Subscription
- ResourceGroup
- User
- Group
- Site
- PolicyScope
For on-premises workloads, targets are often servers.
For cloud workloads, targets may be tenants, subscriptions, groups, sites, or policy scopes.
## Template Process
### 1. A Template Is A Catalog Entry
A template is the stable entry shown in the portal.
It has metadata such as name, category, service, and description.
The template itself should not be the mutable source of deployment content in the long term.
It is the catalog shell.
### 2. TemplateVersions Are Immutable Building Blocks
The actual configuration document lives in `TemplateVersion.JsonData`.
Each template version contains a JSON document with this general shape:
```json
{
"schemaVersion": "1.0",
"templateType": "Service",
"parameters": {},
"variables": {},
"resources": {}
}
```
The template version is the thing that should be selected in a deployment.
This makes deployments reproducible, because they point to an immutable version instead of a mutable template document.
### 3. Template Documents Stay Generic
Template documents can describe many workloads.
Examples:
- Environment defaults
- Domain defaults
- Landscape values
- Service definitions
- Stage-specific settings
- Target or role specific blocks
The document can contain parameters, variables, and resources.
The merge and resolve modules can later combine those pieces into effective configuration data.
## Deployment Design Process
### 1. User Creates A DeploymentGroup
A deployment group represents a deployable unit or one part of a larger environment rollout.
Example environment rollout:
```text
Deployment Group: Contoso Test Environment
Deployment AD
Targets: 2 domain controller servers
Templates: Active Directory baseline, environment defaults, stage defaults
Deployment SQL
Targets: 1 SQL server
Templates: SQL baseline, environment defaults, stage defaults
Deployment SharePoint
Targets: 6 SharePoint servers
Templates: SharePoint baseline, environment defaults, landscape, stage defaults
```
Current implementation still uses `DeploymentGroup`/`DeploymentBatch` naming in places.
Conceptually this is the deployment design container.
### 2. User Selects Template Versions
The deployment group gets one or more `DeploymentTemplateSelections`.
Example:
```text
SortOrder 10: Environment Default 1.0
SortOrder 20: Environment Contoso Test 1.0
SortOrder 30: Service SharePoint 1.0
SortOrder 40: Stage Install 1.0
```
The order matters because the selected template versions are composed in order.
Later selections can extend or override earlier selections, unless a parameter or resource block is sealed.
Current state:
- The API can store multiple template selections.
- The GUI can create an initial selection from a selected template version.
- The details page can add more selections manually.
### 3. User Assigns Targets
The deployment group gets `DeploymentTargetAssignments`.
For server-based workloads, each target assignment usually points to a server.
Example:
```text
Target: CT-SHP-01
RoleKey: WebFrontEnd
NodeDataJson: { "nodeName": "CT-SHP-01" }
Target: CT-SHP-02
RoleKey: Application
NodeDataJson: { "nodeName": "CT-SHP-02" }
```
For cloud workloads, the target may be a tenant, policy scope, group, or site instead of a server.
Current state:
- The API stores target assignments.
- The GUI create flow turns selected targets into target assignments.
- Queue requests can use target assignments if explicit target IDs are not sent again.
### 4. User Adds Parameter Values
The deployment group can store `DeploymentParameterValues`.
Parameter values can be global or scoped to a specific template selection.
Examples:
```text
Global:
DatabasePrefix = Contoso_Test
Scoped to SharePoint selection:
FarmAccount = secret reference
```
The intention is that the GUI later shows user-facing parameter forms based on selected template versions.
The user edits parameter values, and the portal can preview the effective resolved result.
Current state:
- API stores parameter values.
- Values are JSON validated.
- Secret references can be marked.
- Rich parameter editor and preview are still pending.
## Deployment Request Process
### 1. User Starts A Deployment
When the user starts a deployment, the web frontend calls the API deployment request endpoint.
The request currently contains:
```text
DeploymentGroupId
TargetIds optional
JsonData optional deployment override
```
If `TargetIds` are omitted, the API can derive targets from the deployment group's target assignments.
Target direction:
```text
DeploymentGroup composition should be the source of truth.
The start request should eventually only reference the DeploymentGroup and optional runtime overrides.
```
### 2. API Validates The Request
The API validates:
- The deployment group exists.
- Target IDs exist or target assignments are present.
- Runtime JSON override is valid JSON.
- A deployment rule can be resolved from the deployment group or selected template metadata.
### 3. API Creates Or Updates Legacy DeploymentExecutions
Current compatibility behavior:
- The API still creates or updates `DeploymentExecutions`.
- These records are useful for existing UI views and migration compatibility.
Target direction:
- `DeploymentExecutions` should become either a read-only compatibility view or be replaced by queue job target/artifact state.
- The deployment composition and queue job should become the primary execution model.
### 4. API Creates A QueueJob
The API creates a `QueueJob`.
The queue job contains:
- Job type
- Status
- Correlation ID
- Priority
- Schedule and lock metadata
- Payload JSON
- Rule snapshot JSON
- Queue job targets
- Queue job steps
The payload includes the deployment group, selected template versions, target assignments, target IDs, runtime JSON, and metadata.
## Queue Process
### 1. Worker Claims A Job
The worker looks for pending jobs.
It claims a job atomically by setting:
```text
Status = Running
Attempts += 1
LockedBy
LockedUntil
HeartbeatAt
WorkerName
```
This prevents two workers from processing the same job at the same time.
### 2. Worker Processes Steps
Queue jobs can contain steps.
Examples:
- Approval
- Provision
- Validate
- Custom future step types
Approval steps can pause the job until a user approves or rejects them through the API.
### 3. Worker Processes Queue Targets
For each queue target, the worker loads the deployment composition:
```text
DeploymentGroup
TemplateSelections
ParameterValues
TargetAssignments
Target
Environment and Domain context
```
The worker then renders artifacts for that target.
Current renderers:
- PowerShell DSC v2 data file renderer
- DSC v3 JSON renderer
### 4. Worker Writes Output Metadata
The worker writes target and step metadata back to the queue records.
Examples:
- Artifact paths
- Renderer name
- Finished timestamps
- Errors
## Composition And Rendering Process
### 1. Load Selected Template Versions
The worker loads all template selections in sort order.
Example:
```text
Environment Default
Environment Contoso Test
Landscape Test
Service SharePoint
Stage Install
```
### 2. Compose Documents
The selected template JSON documents are merged into one effective deployment document.
Conceptually:
```text
Parameters
Variables
Resources
Targets / AllNodes
Metadata
```
Current worker state:
- It can load the composition.
- It can render ordered PowerShell data files and JSON artifacts.
Target direction:
- DSC v2 renderer should call the existing `Merge-DSCConfigurationData` and `Resolve-DSCConfigurationData` modules.
- DSC v3 renderer can consume or emit JSON directly.
### 3. Resolve Parameters, Variables, And Secrets
The resolve module is responsible for resolving expressions and secrets.
Examples:
```text
[parameters('DatabasePrefix')]
[variables('ConfigDbName')]
[concat(parameters('DatabasePrefix'), '_Config')]
```
For previews, secrets should be skipped or replaced with dummy values.
For real deployments, secrets are resolved through the configured credential provider.
## Preview Process
This is not fully implemented yet, but the intended flow is:
```text
User edits deployment composition
-> clicks Preview
-> API builds effective deployment composition
-> API or worker-style service merges selected template versions
-> Resolve runs with SkipSecrets
-> GUI shows effective parameters, variables, resources, and target data
```
The preview should help users see what will actually be deployed before a queue job is created.
This belongs mostly to Step 8 and Step 8a.
## Promotion Process
This is not fully implemented yet.
Target idea:
```text
Change shared domain or service baseline
-> create new template version
-> test in Test environment
-> promote the same immutable version to QA or Prod deployment groups
```
Promotion should not mean copying large JSON blocks repeatedly.
It should mean reusing or advancing selected template versions in deployment groups.
## Current Implemented State
Implemented:
- Generic targets exist.
- Template versions exist and are versioned with hashes.
- Deployment groups can store template selections.
- Deployment groups can store parameter values.
- Deployment groups can store target assignments.
- Queue jobs have claim/lock/heartbeat metadata.
- Queue job targets and steps can persist output metadata.
- Worker can load deployment composition.
- Worker can render DSC v2-style PowerShell data files and DSC v3-style JSON artifacts.
- Web can create a rudimentary deployment group using a selected template version and selected targets.
Partially implemented:
- Legacy `DeploymentGroup.TemplateId` and `DeploymentExecution.JSONData` are still present for compatibility.
- API still mixes repository and direct `DataContext` logic in some controllers.
- Queue payloads include composition data, but the API contract is not yet fully cleaned up.
Pending:
- Dedicated deployment composition service.
- Transactional deployment group creation.
- Rich validation results instead of generic `false` / `500`.
- Preview endpoint based on merge and resolve.
- Sealed parameter and resource block visibility in API/GUI.
- Promotion flow.
- Final cleanup of legacy template JSON and deployment execution fields.
## Expected Future Clean Flow
The desired future flow should look like this:
```text
1. Admin maintains catalog:
Environments, Domains, Services, Targets
2. Admin maintains templates:
Template -> TemplateVersion -> Published immutable version
3. User creates deployment group:
Select environment/context
Select template versions
Assign targets
Set parameter values
4. User previews:
Merge selected template versions
Resolve parameters and variables
Resolve secrets as dummy values
Show effective output
5. User starts deployment:
API creates QueueJob
Worker claims QueueJob
Worker renders artifacts
Worker executes or hands off
API reports status and metadata
6. User promotes:
Reuse tested template versions in the next environment
Avoid copying environment-specific JSON manually
```
## Main Understanding To Validate
The core understanding is:
```text
Templates describe reusable building blocks.
TemplateVersions make those building blocks immutable.
DeploymentGroups select and order those building blocks.
ParameterValues and TargetAssignments make the deployment concrete.
QueueJobs turn the deployment design into execution.
Workers render and execute without knowing SharePoint-specific database tables.
```
If this is correct, the next API work should focus on making this process stricter and more explicit, not on adding more legacy shortcuts.

View File

@@ -12,6 +12,13 @@
public string? ErrorMessage { get; set; }
public string? MetadataJson { get; set; }
public string? RuleSnapshotJson { get; set; }
public Guid CorrelationId { get; set; }
public int Priority { get; set; }
public DateTime? ScheduledAt { get; set; }
public DateTime? HeartbeatAt { get; set; }
public string? WorkerName { get; set; }
public string? LockedBy { get; set; }
public DateTime? LockedUntil { get; set; }
public ICollection<GetQueueJobTargetDto> Targets { get; set; } = new List<GetQueueJobTargetDto>();
public ICollection<GetQueueJobStepDto> Steps { get; set; } = new List<GetQueueJobStepDto>();
}

View File

@@ -9,6 +9,11 @@
public DateTime? Started { get; set; }
public DateTime? Finished { get; set; }
public string? ErrorMessage { get; set; }
public Guid CorrelationId { get; set; }
public int Priority { get; set; }
public DateTime? ScheduledAt { get; set; }
public DateTime? HeartbeatAt { get; set; }
public string? WorkerName { get; set; }
public int TargetCount { get; set; }
public int SucceededTargetCount { get; set; }
public int FailedTargetCount { get; set; }

View File

@@ -11,6 +11,10 @@
public DateTime? ApprovedAt { get; set; }
public string? ApprovedBy { get; set; }
public string? ApprovalComment { get; set; }
public DateTime? Started { get; set; }
public DateTime? Finished { get; set; }
public string? OutputMetadataJson { get; set; }
public string? ErrorMessage { get; set; }
}
}

View File

@@ -8,6 +8,9 @@
public string Status { get; set; } = string.Empty;
public int Attempts { get; set; }
public string? ErrorMessage { get; set; }
public DateTime? Started { get; set; }
public DateTime? Finished { get; set; }
public string? OutputMetadataJson { get; set; }
}
}

View File

@@ -1,20 +1,29 @@
using System.ComponentModel.DataAnnotations.Schema;
using System.ComponentModel.DataAnnotations.Schema;
using Microsoft.SelfService.Portal.Core.API.Dto.DeploymentComposition.Add;
namespace Microsoft.SelfService.Portal.Core.API.Dto.DeploymentBatch.Add
{
public class AddDeploymentBatchDto
{
[Column(Order = 1)]
public Guid TemplateId { get; set; }
public Guid? TemplateId { get; set; }
[Column(Order = 2)]
public Guid? DeploymentRuleId { get; set; }
public Guid? TemplateVersionId { get; set; }
[Column(Order = 3)]
public string Status { get; set; } = string.Empty;
public Guid? DeploymentRuleId { get; set; }
[Column(Order = 4)]
public string Status { get; set; } = string.Empty;
[Column(Order = 5)]
public ICollection<Guid>? TargetIds { get; set; }
[Column(Order = 6)]
public ICollection<AddDeploymentTemplateSelectionDto>? TemplateSelections { get; set; }
[Column(Order = 7)]
public ICollection<AddDeploymentTargetAssignmentDto>? TargetAssignments { get; set; }
}
}

View File

@@ -1,4 +1,4 @@
using Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get;
using Microsoft.SelfService.Portal.Core.API.Dto.Deployment.Get;
using Microsoft.SelfService.Portal.Core.API.Dto.DeploymentComposition.Get;
using Microsoft.SelfService.Portal.Core.API.Dto.Template.Get;
@@ -6,11 +6,13 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.DeploymentBatch.Get
{
public class GetDeploymentBatchDetailsDto : BaseDto
{
public Guid? TemplateId { get; set; }
public Guid? DeploymentRuleId { get; set; }
public string Status { get; set; } = string.Empty;
public GetTemplateDetailsDto Template { get; set; } = null!;
public GetTemplateDetailsDto? Template { get; set; }
public ICollection<GetDeploymentDetailsDto> Deployments { get; set; } = new List<GetDeploymentDetailsDto>();
public ICollection<GetDeploymentTemplateSelectionDto> TemplateSelections { get; set; } = new List<GetDeploymentTemplateSelectionDto>();
@@ -18,4 +20,3 @@ namespace Microsoft.SelfService.Portal.Core.API.Dto.DeploymentBatch.Get
public ICollection<GetDeploymentTargetAssignmentDto> TargetAssignments { get; set; } = new List<GetDeploymentTargetAssignmentDto>();
}
}

View File

@@ -1,12 +1,21 @@
namespace Microsoft.SelfService.Portal.Core.API.Dto.DeploymentBatch.Get
namespace Microsoft.SelfService.Portal.Core.API.Dto.DeploymentBatch.Get
{
public class GetDeploymentBatchDto : BaseDetailsDto
{
public Guid TemplateId { get; set; }
public Guid? TemplateId { get; set; }
public Guid? DeploymentRuleId { get; set; }
public string Status { get; set; } = string.Empty;
public Guid? PrimaryTemplateVersionId { get; set; }
public string? PrimaryTemplateName { get; set; }
public string? PrimaryTemplateVersion { get; set; }
public int TemplateSelectionCount { get; set; }
public int TargetAssignmentCount { get; set; }
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,294 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace Microsoft.SelfService.Portal.Core.API.Migrations
{
/// <inheritdoc />
public partial class AddQueueHardening : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_DeploymentJobTargets_DeploymentJobId",
table: "DeploymentJobTargets");
migrationBuilder.DropIndex(
name: "IX_DeploymentJobSteps_DeploymentJobId",
table: "DeploymentJobSteps");
migrationBuilder.AlterColumn<string>(
name: "Status",
table: "DeploymentJobTargets",
type: "nvarchar(450)",
nullable: false,
oldClrType: typeof(string),
oldType: "nvarchar(max)");
migrationBuilder.AddColumn<DateTime>(
name: "Finished",
table: "DeploymentJobTargets",
type: "datetime2",
nullable: true)
.Annotation("Relational:ColumnOrder", 9);
migrationBuilder.AddColumn<string>(
name: "OutputMetadataJson",
table: "DeploymentJobTargets",
type: "nvarchar(max)",
nullable: true)
.Annotation("Relational:ColumnOrder", 10);
migrationBuilder.AddColumn<DateTime>(
name: "Started",
table: "DeploymentJobTargets",
type: "datetime2",
nullable: true)
.Annotation("Relational:ColumnOrder", 8);
migrationBuilder.AlterColumn<string>(
name: "Status",
table: "DeploymentJobSteps",
type: "nvarchar(450)",
nullable: false,
oldClrType: typeof(string),
oldType: "nvarchar(max)");
migrationBuilder.AddColumn<string>(
name: "ErrorMessage",
table: "DeploymentJobSteps",
type: "nvarchar(max)",
nullable: true)
.Annotation("Relational:ColumnOrder", 14);
migrationBuilder.AddColumn<DateTime>(
name: "Finished",
table: "DeploymentJobSteps",
type: "datetime2",
nullable: true)
.Annotation("Relational:ColumnOrder", 12);
migrationBuilder.AddColumn<string>(
name: "OutputMetadataJson",
table: "DeploymentJobSteps",
type: "nvarchar(max)",
nullable: true)
.Annotation("Relational:ColumnOrder", 13);
migrationBuilder.AddColumn<DateTime>(
name: "Started",
table: "DeploymentJobSteps",
type: "datetime2",
nullable: true)
.Annotation("Relational:ColumnOrder", 11);
migrationBuilder.AlterColumn<string>(
name: "Status",
table: "DeploymentJobs",
type: "nvarchar(450)",
nullable: false,
oldClrType: typeof(string),
oldType: "nvarchar(max)");
migrationBuilder.AddColumn<Guid>(
name: "CorrelationId",
table: "DeploymentJobs",
type: "uniqueidentifier",
nullable: false,
defaultValueSql: "NEWID()")
.Annotation("Relational:ColumnOrder", 13);
migrationBuilder.AddColumn<DateTime>(
name: "HeartbeatAt",
table: "DeploymentJobs",
type: "datetime2",
nullable: true)
.Annotation("Relational:ColumnOrder", 16);
migrationBuilder.AddColumn<int>(
name: "Priority",
table: "DeploymentJobs",
type: "int",
nullable: false,
defaultValue: 100)
.Annotation("Relational:ColumnOrder", 14);
migrationBuilder.AddColumn<byte[]>(
name: "RowVersion",
table: "DeploymentJobs",
type: "rowversion",
rowVersion: true,
nullable: false,
defaultValue: new byte[0]);
migrationBuilder.AddColumn<DateTime>(
name: "ScheduledAt",
table: "DeploymentJobs",
type: "datetime2",
nullable: true)
.Annotation("Relational:ColumnOrder", 15);
migrationBuilder.AddColumn<string>(
name: "WorkerName",
table: "DeploymentJobs",
type: "nvarchar(450)",
nullable: true)
.Annotation("Relational:ColumnOrder", 17);
migrationBuilder.CreateIndex(
name: "IX_DeploymentJobTargets_DeploymentJobId_Status",
table: "DeploymentJobTargets",
columns: new[] { "DeploymentJobId", "Status" });
migrationBuilder.AddCheckConstraint(
name: "CK_DeploymentJobTargets_OutputMetadataJson_IsJson",
table: "DeploymentJobTargets",
sql: "[OutputMetadataJson] IS NULL OR ISJSON([OutputMetadataJson]) = 1");
migrationBuilder.CreateIndex(
name: "IX_DeploymentJobSteps_DeploymentJobId_Status_SortOrder",
table: "DeploymentJobSteps",
columns: new[] { "DeploymentJobId", "Status", "SortOrder" });
migrationBuilder.AddCheckConstraint(
name: "CK_DeploymentJobSteps_OutputMetadataJson_IsJson",
table: "DeploymentJobSteps",
sql: "[OutputMetadataJson] IS NULL OR ISJSON([OutputMetadataJson]) = 1");
migrationBuilder.CreateIndex(
name: "IX_DeploymentJobs_CorrelationId",
table: "DeploymentJobs",
column: "CorrelationId");
migrationBuilder.CreateIndex(
name: "IX_DeploymentJobs_Status_ScheduledAt_LockedUntil_Priority_Created",
table: "DeploymentJobs",
columns: new[] { "Status", "ScheduledAt", "LockedUntil", "Priority", "Created" });
migrationBuilder.CreateIndex(
name: "IX_DeploymentJobs_WorkerName",
table: "DeploymentJobs",
column: "WorkerName");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_DeploymentJobTargets_DeploymentJobId_Status",
table: "DeploymentJobTargets");
migrationBuilder.DropCheckConstraint(
name: "CK_DeploymentJobTargets_OutputMetadataJson_IsJson",
table: "DeploymentJobTargets");
migrationBuilder.DropIndex(
name: "IX_DeploymentJobSteps_DeploymentJobId_Status_SortOrder",
table: "DeploymentJobSteps");
migrationBuilder.DropCheckConstraint(
name: "CK_DeploymentJobSteps_OutputMetadataJson_IsJson",
table: "DeploymentJobSteps");
migrationBuilder.DropIndex(
name: "IX_DeploymentJobs_CorrelationId",
table: "DeploymentJobs");
migrationBuilder.DropIndex(
name: "IX_DeploymentJobs_Status_ScheduledAt_LockedUntil_Priority_Created",
table: "DeploymentJobs");
migrationBuilder.DropIndex(
name: "IX_DeploymentJobs_WorkerName",
table: "DeploymentJobs");
migrationBuilder.DropColumn(
name: "Finished",
table: "DeploymentJobTargets");
migrationBuilder.DropColumn(
name: "OutputMetadataJson",
table: "DeploymentJobTargets");
migrationBuilder.DropColumn(
name: "Started",
table: "DeploymentJobTargets");
migrationBuilder.DropColumn(
name: "ErrorMessage",
table: "DeploymentJobSteps");
migrationBuilder.DropColumn(
name: "Finished",
table: "DeploymentJobSteps");
migrationBuilder.DropColumn(
name: "OutputMetadataJson",
table: "DeploymentJobSteps");
migrationBuilder.DropColumn(
name: "Started",
table: "DeploymentJobSteps");
migrationBuilder.DropColumn(
name: "CorrelationId",
table: "DeploymentJobs");
migrationBuilder.DropColumn(
name: "HeartbeatAt",
table: "DeploymentJobs");
migrationBuilder.DropColumn(
name: "Priority",
table: "DeploymentJobs");
migrationBuilder.DropColumn(
name: "RowVersion",
table: "DeploymentJobs");
migrationBuilder.DropColumn(
name: "ScheduledAt",
table: "DeploymentJobs");
migrationBuilder.DropColumn(
name: "WorkerName",
table: "DeploymentJobs");
migrationBuilder.AlterColumn<string>(
name: "Status",
table: "DeploymentJobTargets",
type: "nvarchar(max)",
nullable: false,
oldClrType: typeof(string),
oldType: "nvarchar(450)");
migrationBuilder.AlterColumn<string>(
name: "Status",
table: "DeploymentJobSteps",
type: "nvarchar(max)",
nullable: false,
oldClrType: typeof(string),
oldType: "nvarchar(450)");
migrationBuilder.AlterColumn<string>(
name: "Status",
table: "DeploymentJobs",
type: "nvarchar(max)",
nullable: false,
oldClrType: typeof(string),
oldType: "nvarchar(450)");
migrationBuilder.CreateIndex(
name: "IX_DeploymentJobTargets_DeploymentJobId",
table: "DeploymentJobTargets",
column: "DeploymentJobId");
migrationBuilder.CreateIndex(
name: "IX_DeploymentJobSteps_DeploymentJobId",
table: "DeploymentJobSteps",
column: "DeploymentJobId");
}
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,5 +1,7 @@
using System.ComponentModel.DataAnnotations.Schema;
using System.ComponentModel.DataAnnotations;
namespace Microsoft.SelfService.Portal.Core.API.Models
{
public class QueueJobModel : BaseModel
@@ -40,6 +42,24 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
[Column(Order = 12)]
public string? RuleSnapshotJson { get; set; }
[Column(Order = 13)]
public Guid CorrelationId { get; set; } = Guid.NewGuid();
[Column(Order = 14)]
public int Priority { get; set; } = 100;
[Column(Order = 15)]
public DateTime? ScheduledAt { get; set; }
[Column(Order = 16)]
public DateTime? HeartbeatAt { get; set; }
[Column(Order = 17)]
public string? WorkerName { get; set; }
[Timestamp]
public byte[] RowVersion { get; set; } = [];
public ICollection<QueueJobTargetModel> Targets { get; set; } = new List<QueueJobTargetModel>();
public ICollection<QueueJobStepModel> Steps { get; set; } = new List<QueueJobStepModel>();
}

View File

@@ -34,6 +34,18 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
[Column(Order = 10)]
public string? ApprovalComment { get; set; }
[Column(Order = 11)]
public DateTime? Started { get; set; }
[Column(Order = 12)]
public DateTime? Finished { get; set; }
[Column(Order = 13)]
public string? OutputMetadataJson { get; set; }
[Column(Order = 14)]
public string? ErrorMessage { get; set; }
public QueueJobModel QueueJob { get; set; }
public QueueJobStepModel? DependsOnQueueJobStep { get; set; }
}

View File

@@ -25,6 +25,15 @@ namespace Microsoft.SelfService.Portal.Core.API.Models
[Column(Order = 7)]
public string? ErrorMessage { get; set; }
[Column(Order = 8)]
public DateTime? Started { get; set; }
[Column(Order = 9)]
public DateTime? Finished { get; set; }
[Column(Order = 10)]
public string? OutputMetadataJson { get; set; }
public QueueJobModel QueueJob { get; set; }
}
}

View File

@@ -2,6 +2,7 @@
using Microsoft.SelfService.Portal.Core.API.Context;
using Microsoft.SelfService.Portal.Core.API.Interfaces;
using Microsoft.SelfService.Portal.Core.API.Models;
using System.Text.Json;
namespace Microsoft.SelfService.Portal.Core.API.Repository
{
@@ -16,7 +17,12 @@ namespace Microsoft.SelfService.Portal.Core.API.Repository
public ICollection<DeploymentGroupModel> GetDeploymentBatches()
{
return _context.DeploymentGroups.ToList();
return _context.DeploymentGroups
.Include(batch => batch.TemplateSelections)
.ThenInclude(selection => selection.TemplateVersion)
.ThenInclude(version => version.Template)
.Include(batch => batch.TargetAssignments)
.ToList();
}
public DeploymentGroupModel? GetDeploymentBatchById(Guid id)
@@ -42,16 +48,33 @@ namespace Microsoft.SelfService.Portal.Core.API.Repository
deploymentBatch.Id = Guid.NewGuid();
}
var template = _context.Templates
.Include(existing => existing.TemplateCategory)
.ThenInclude(existing => existing.Service)
.FirstOrDefault(existing => existing.Id == deploymentBatch.TemplateId);
var requestedTemplateVersionId = deploymentBatch.TemplateSelections
.OrderBy(selection => selection.SortOrder)
.Select(selection => (Guid?)selection.TemplateVersionId)
.FirstOrDefault();
var templateVersion = requestedTemplateVersionId.HasValue
? _context.TemplateVersions
.Include(version => version.Template)
.ThenInclude(template => template.TemplateCategory)
.ThenInclude(category => category.Service)
.FirstOrDefault(version => version.Id == requestedTemplateVersionId.Value)
: null;
var template = templateVersion?.Template
?? _context.Templates
.Include(existing => existing.TemplateCategory)
.ThenInclude(existing => existing.Service)
.Include(existing => existing.TemplateVersions)
.FirstOrDefault(existing => existing.Id == deploymentBatch.TemplateId);
if (template == null)
{
return false;
}
deploymentBatch.TemplateId = template.Id;
if (deploymentBatch.DeploymentRuleId.HasValue)
{
var ruleExists = _context.DeploymentRules.Any(existing => existing.Id == deploymentBatch.DeploymentRuleId.Value);
@@ -63,6 +86,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Repository
var isCloudService = template.TemplateCategory.Service.IsCloudService;
var selectedTargetIds = (targetIds ?? Array.Empty<Guid>())
.Concat(deploymentBatch.TargetAssignments.Select(assignment => assignment.TargetId))
.Distinct()
.ToList();
@@ -86,6 +110,53 @@ namespace Microsoft.SelfService.Portal.Core.API.Repository
_context.Add(deploymentBatch);
if (deploymentBatch.TemplateSelections.Count == 0)
{
templateVersion ??= template.TemplateVersions?
.OrderByDescending(version => version.IsPublished)
.ThenByDescending(version => version.PublishedAt)
.ThenByDescending(version => version.Created)
.FirstOrDefault();
if (templateVersion == null)
{
return false;
}
deploymentBatch.TemplateSelections.Add(new DeploymentTemplateSelectionModel
{
Id = Guid.NewGuid(),
DeploymentGroupId = deploymentBatch.Id,
TemplateVersionId = templateVersion.Id,
TemplateRole = "Service",
SortOrder = 10,
Alias = template.Name
});
}
if (deploymentBatch.TargetAssignments.Count == 0)
{
var sortOrder = 10;
foreach (var targetId in selectedTargetIds)
{
var targetName = _context.Targets
.Where(target => target.Id == targetId)
.Select(target => target.Name)
.FirstOrDefault();
deploymentBatch.TargetAssignments.Add(new DeploymentTargetAssignmentModel
{
Id = Guid.NewGuid(),
DeploymentGroupId = deploymentBatch.Id,
TargetId = targetId,
RoleKey = "Node",
SortOrder = sortOrder,
NodeDataJson = JsonSerializer.Serialize(new { nodeName = targetName ?? targetId.ToString() })
});
sortOrder += 10;
}
}
if (!SaveChanges())
{
return false;
@@ -112,10 +183,34 @@ namespace Microsoft.SelfService.Portal.Core.API.Repository
public bool DeleteDeploymentBatchById(DeploymentGroupModel deploymentBatch)
{
var templateSelections = _context.DeploymentTemplateSelections
.Where(existing => existing.DeploymentGroupId == deploymentBatch.Id)
.ToList();
var parameterValues = _context.DeploymentParameterValues
.Where(existing => existing.DeploymentGroupId == deploymentBatch.Id)
.ToList();
var targetAssignments = _context.DeploymentTargetAssignments
.Where(existing => existing.DeploymentGroupId == deploymentBatch.Id)
.ToList();
var deployments = _context.Deployments
.Where(existing => existing.DeploymentGroupId == deploymentBatch.Id)
.ToList();
if (parameterValues.Count > 0)
{
_context.DeploymentParameterValues.RemoveRange(parameterValues);
}
if (targetAssignments.Count > 0)
{
_context.DeploymentTargetAssignments.RemoveRange(targetAssignments);
}
if (templateSelections.Count > 0)
{
_context.DeploymentTemplateSelections.RemoveRange(templateSelections);
}
if (deployments.Count > 0)
{
_context.Deployments.RemoveRange(deployments);

View File

@@ -37,6 +37,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
{
Type = QueueJobType.TemplateJsonChanged,
Status = QueueJobStatus.Pending,
CorrelationId = Guid.NewGuid(),
PayloadJson = JsonSerializer.Serialize(payload),
Targets = deployments.Select(deployment => new QueueJobTargetModel
{
@@ -66,6 +67,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
.Include(group => group.Template)
.ThenInclude(template => template.DeploymentRule)
.ThenInclude(rule => rule.Steps)
.Include(group => group.TemplateSelections)
.ThenInclude(selection => selection.TemplateVersion)
.ThenInclude(version => version.Template)
.Include(group => group.TargetAssignments)
.Include(group => group.DeploymentRule)
.ThenInclude(rule => rule!.Steps)
.FirstOrDefault(group => group.Id == deploymentGroupId);
@@ -75,11 +80,23 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
throw new InvalidOperationException("DeploymentGroup does not exist.");
}
var templateId = deploymentGroup.TemplateId;
var primaryTemplateSelection = deploymentGroup.TemplateSelections
.OrderBy(selection => selection.SortOrder)
.FirstOrDefault();
var templateId = primaryTemplateSelection?.TemplateVersion.TemplateId ?? deploymentGroup.TemplateId;
var resolvedTargetIds = targetIds
.Distinct()
.ToList();
if (resolvedTargetIds.Count == 0)
{
resolvedTargetIds = deploymentGroup.TargetAssignments
.OrderBy(assignment => assignment.SortOrder)
.Select(assignment => assignment.TargetId)
.Distinct()
.ToList();
}
if (resolvedTargetIds.Count == 0)
{
throw new InvalidOperationException("No target Targets provided.");
@@ -133,6 +150,31 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
DeploymentGroupId = deploymentGroupId,
TemplateId = templateId,
DeploymentRuleId = resolvedRule?.Id,
TemplateSelections = deploymentGroup.TemplateSelections
.OrderBy(selection => selection.SortOrder)
.Select(selection => new
{
selection.Id,
selection.TemplateVersionId,
TemplateId = selection.TemplateVersion.TemplateId,
TemplateName = selection.TemplateVersion.Template.Name,
selection.TemplateVersion.Version,
selection.TemplateVersion.JsonHash,
selection.TemplateRole,
selection.SortOrder,
selection.Alias
}),
TargetAssignments = deploymentGroup.TargetAssignments
.OrderBy(assignment => assignment.SortOrder)
.Where(assignment => resolvedTargetIds.Contains(assignment.TargetId))
.Select(assignment => new
{
assignment.Id,
assignment.TargetId,
assignment.RoleKey,
assignment.SortOrder,
assignment.NodeDataJson
}),
TargetIds = resolvedTargetIds,
JsonData = jsonData,
TargetCount = resolvedTargetIds.Count,
@@ -143,6 +185,7 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
{
Type = QueueJobType.DeploymentRequested,
Status = QueueJobStatus.Pending,
CorrelationId = Guid.NewGuid(),
PayloadJson = JsonSerializer.Serialize(payload),
RuleSnapshotJson = resolvedRule != null
? SerializeRuleSnapshot(resolvedRule)
@@ -179,6 +222,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
queueJob.Finished = null;
queueJob.LockedUntil = null;
queueJob.LockedBy = null;
queueJob.HeartbeatAt = null;
queueJob.WorkerName = null;
queueJob.Steps ??= new List<QueueJobStepModel>();
foreach (var target in queueJob.Targets)
@@ -187,6 +232,9 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
{
target.Status = QueueJobStatus.Pending;
target.ErrorMessage = null;
target.Started = null;
target.Finished = null;
target.OutputMetadataJson = null;
}
}
foreach (var step in queueJob.Steps)
@@ -200,6 +248,10 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
step.ApprovedAt = null;
step.ApprovedBy = null;
step.ApprovalComment = null;
step.Started = null;
step.Finished = null;
step.ErrorMessage = null;
step.OutputMetadataJson = null;
}
}
@@ -224,6 +276,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
step.QueueJob.Status = QueueJobStatus.Pending;
step.QueueJob.LockedUntil = null;
step.QueueJob.LockedBy = null;
step.QueueJob.HeartbeatAt = null;
step.QueueJob.WorkerName = null;
step.QueueJob.ErrorMessage = null;
return _context.SaveChanges() > 0;
@@ -248,6 +302,8 @@ namespace Microsoft.SelfService.Portal.Core.API.Services
step.QueueJob.Finished = DateTime.UtcNow;
step.QueueJob.LockedUntil = null;
step.QueueJob.LockedBy = null;
step.QueueJob.HeartbeatAt = null;
step.QueueJob.WorkerName = null;
step.QueueJob.ErrorMessage = comment ?? "Deployment step rejected.";
return _context.SaveChanges() > 0;

37
ToDo.md
View File

@@ -79,31 +79,34 @@ Status: Completed
### 6. Worker Pipeline Refactor
Status: Pending
Status: Completed
- Load deployment composition from API/database.
- Convert JSON documents to ordered PowerShell hashtables for the existing Merge/Resolve modules.
- Add a renderer abstraction:
- `PowerShellDscV2Renderer`
- `DscV3JsonRenderer`
- future cloud/action renderers
- Store generated artifacts and logs.
- Load deployment composition from API/database. Completed in Worker `DeploymentCompositionLoader`.
- Convert JSON documents to ordered PowerShell hashtables for the existing Merge/Resolve modules. Completed as `PowerShellDscV2Renderer`, which writes `ConfigurationData.psd1` with `[ordered]@{...}` output for the composed deployment document.
- Add a renderer abstraction. Completed through `IDeploymentRenderer`.
- `PowerShellDscV2Renderer`. Completed.
- `DscV3JsonRenderer`. Completed.
- future cloud/action renderers. Extension point added.
- Store generated artifacts and logs. Completed as filesystem artifacts under configurable `WorkerPipeline:ArtifactRoot`; structured logs are written through `ILogger`.
- Replace the old dry-run provisioning provider path with `DeploymentPipeline`. Completed.
- Note: actual invocation of `Merge-DSCConfigurationData` / `Resolve-DSCConfigurationData` can now be added inside the DSC v2 renderer when the worker moves from render-only to execute mode.
### 7. Queue Hardening
Status: Pending
Status: Completed
- Add worker claim/lock semantics based on `LockedBy`, `LockedUntil`, and a concurrency token.
- Add `CorrelationId`, `Priority`, `ScheduledAt`, `HeartbeatAt`, and `WorkerName`.
- Add useful indexes for pending/running jobs.
- Persist step and target output metadata.
- Add worker claim/lock semantics based on `LockedBy`, `LockedUntil`, and a concurrency token. Completed with atomic `ExecuteUpdateAsync` claim logic in the worker and SQL `rowversion` on deployment jobs.
- Add `CorrelationId`, `Priority`, `ScheduledAt`, `HeartbeatAt`, and `WorkerName`. Completed in model, DTOs, API mapping, and Web TypeScript contracts.
- Add useful indexes for pending/running jobs. Completed for queue claim lookup, worker lookup, correlation id, target status, and step status/sort order.
- Persist step and target output metadata. Completed with JSON metadata columns and SQL `ISJSON` constraints.
- Migration `20260708194227_AddQueueHardening` and SQL script `buildcheck/AddQueueHardening.sql` generated.
### 8. Web/API Migration
Status: Pending
Status: In Progress
- Update API endpoints to expose template versions and deployment composition.
- Update Web to create DeploymentGroups with multiple Deployments.
- Update API endpoints to expose template versions and deployment composition. Completed for deployment batch list/details, version-aware create, and queue payloads.
- Update Web to create DeploymentGroups with multiple Deployments. Completed for the rudimentary create flow: users select a template version, targets become target assignments, and legacy executions stay available for compatibility.
- Add GUI support for sealed parameters and sealed template blocks.
- Add preview mode based on `Resolve-DSCConfigurationData -SkipSecrets`.
- Add promotion flow from Test to QA/Prod.
@@ -139,4 +142,4 @@ Status: In Progress
## Next Step
Start work package 6 by refactoring the worker pipeline to load deployment composition from the API/database and render artifacts through a DSC v2/v3-capable abstraction.
Continue work package 8 with sealed parameter/block visibility, a backend preview endpoint, and the later promotion flow. Keep rich interactive preview UX in Step 8a.

View File

@@ -0,0 +1,75 @@
BEGIN TRANSACTION;
DROP INDEX [IX_DeploymentJobTargets_DeploymentJobId] ON [DeploymentJobTargets];
DROP INDEX [IX_DeploymentJobSteps_DeploymentJobId] ON [DeploymentJobSteps];
DECLARE @var nvarchar(max);
SELECT @var = QUOTENAME([d].[name])
FROM [sys].[default_constraints] [d]
INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id]
WHERE ([d].[parent_object_id] = OBJECT_ID(N'[DeploymentJobTargets]') AND [c].[name] = N'Status');
IF @var IS NOT NULL EXEC(N'ALTER TABLE [DeploymentJobTargets] DROP CONSTRAINT ' + @var + ';');
ALTER TABLE [DeploymentJobTargets] ALTER COLUMN [Status] nvarchar(450) NOT NULL;
ALTER TABLE [DeploymentJobTargets] ADD [Finished] datetime2 NULL;
ALTER TABLE [DeploymentJobTargets] ADD [OutputMetadataJson] nvarchar(max) NULL;
ALTER TABLE [DeploymentJobTargets] ADD [Started] datetime2 NULL;
DECLARE @var1 nvarchar(max);
SELECT @var1 = QUOTENAME([d].[name])
FROM [sys].[default_constraints] [d]
INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id]
WHERE ([d].[parent_object_id] = OBJECT_ID(N'[DeploymentJobSteps]') AND [c].[name] = N'Status');
IF @var1 IS NOT NULL EXEC(N'ALTER TABLE [DeploymentJobSteps] DROP CONSTRAINT ' + @var1 + ';');
ALTER TABLE [DeploymentJobSteps] ALTER COLUMN [Status] nvarchar(450) NOT NULL;
ALTER TABLE [DeploymentJobSteps] ADD [ErrorMessage] nvarchar(max) NULL;
ALTER TABLE [DeploymentJobSteps] ADD [Finished] datetime2 NULL;
ALTER TABLE [DeploymentJobSteps] ADD [OutputMetadataJson] nvarchar(max) NULL;
ALTER TABLE [DeploymentJobSteps] ADD [Started] datetime2 NULL;
DECLARE @var2 nvarchar(max);
SELECT @var2 = QUOTENAME([d].[name])
FROM [sys].[default_constraints] [d]
INNER JOIN [sys].[columns] [c] ON [d].[parent_column_id] = [c].[column_id] AND [d].[parent_object_id] = [c].[object_id]
WHERE ([d].[parent_object_id] = OBJECT_ID(N'[DeploymentJobs]') AND [c].[name] = N'Status');
IF @var2 IS NOT NULL EXEC(N'ALTER TABLE [DeploymentJobs] DROP CONSTRAINT ' + @var2 + ';');
ALTER TABLE [DeploymentJobs] ALTER COLUMN [Status] nvarchar(450) NOT NULL;
ALTER TABLE [DeploymentJobs] ADD [CorrelationId] uniqueidentifier NOT NULL DEFAULT (NEWID());
ALTER TABLE [DeploymentJobs] ADD [HeartbeatAt] datetime2 NULL;
ALTER TABLE [DeploymentJobs] ADD [Priority] int NOT NULL DEFAULT 100;
ALTER TABLE [DeploymentJobs] ADD [RowVersion] rowversion NOT NULL;
ALTER TABLE [DeploymentJobs] ADD [ScheduledAt] datetime2 NULL;
ALTER TABLE [DeploymentJobs] ADD [WorkerName] nvarchar(450) NULL;
CREATE INDEX [IX_DeploymentJobTargets_DeploymentJobId_Status] ON [DeploymentJobTargets] ([DeploymentJobId], [Status]);
ALTER TABLE [DeploymentJobTargets] ADD CONSTRAINT [CK_DeploymentJobTargets_OutputMetadataJson_IsJson] CHECK ([OutputMetadataJson] IS NULL OR ISJSON([OutputMetadataJson]) = 1);
CREATE INDEX [IX_DeploymentJobSteps_DeploymentJobId_Status_SortOrder] ON [DeploymentJobSteps] ([DeploymentJobId], [Status], [SortOrder]);
ALTER TABLE [DeploymentJobSteps] ADD CONSTRAINT [CK_DeploymentJobSteps_OutputMetadataJson_IsJson] CHECK ([OutputMetadataJson] IS NULL OR ISJSON([OutputMetadataJson]) = 1);
CREATE INDEX [IX_DeploymentJobs_CorrelationId] ON [DeploymentJobs] ([CorrelationId]);
CREATE INDEX [IX_DeploymentJobs_Status_ScheduledAt_LockedUntil_Priority_Created] ON [DeploymentJobs] ([Status], [ScheduledAt], [LockedUntil], [Priority], [Created]);
CREATE INDEX [IX_DeploymentJobs_WorkerName] ON [DeploymentJobs] ([WorkerName]);
INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
VALUES (N'20260708194227_AddQueueHardening', N'10.0.8');
COMMIT;
GO

View File

@@ -14,7 +14,7 @@ using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("Microsoft.SelfService.Portal.Core.API")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+bbe521b38d2b1025802798d026ddc12b40aeb367")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+97238c28c911aa2649a9ef1c5e9f48522e0822cf")]
[assembly: System.Reflection.AssemblyProductAttribute("Microsoft.SelfService.Portal.Core.API")]
[assembly: System.Reflection.AssemblyTitleAttribute("Microsoft.SelfService.Portal.Core.API")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]

View File

@@ -1 +1 @@
9739c25723019e3534359faa29df80d589d4d7f81f05bc81477e616494ff1a53
0a79ca958402e374cec625e71698edf95ebbc8aeff8ad654ecc44a7f7862c01d

View File

@@ -1 +1 @@
e6d93761138aa5e56e9aa342a1381ffc12105e136fe8753079012d465b342813
70cb083ca1d78990e360c9946e7473dbe67844782d9253e595e598ef6042af13

View File

@@ -173,3 +173,178 @@ F:\Projekte\Coding\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\
F:\Projekte\Coding\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.pdb
F:\Projekte\Coding\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.genruntimeconfig.cache
F:\Projekte\Coding\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\ref\Microsoft.SelfService.Portal.Core.API.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\appsettings.Development.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\appsettings.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\buildcheck\appsettings.Development.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\buildcheck\appsettings.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\buildcheck\Microsoft.SelfService.Portal.Core.API.deps.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\buildcheck\Microsoft.SelfService.Portal.Core.API.runtimeconfig.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\buildcheck\Microsoft.SelfService.Portal.Core.API.staticwebassets.endpoints.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.staticwebassets.endpoints.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.exe
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.deps.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.runtimeconfig.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.pdb
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\AutoMapper.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Azure.Core.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Azure.Identity.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Humanizer.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.AspNetCore.Authentication.Negotiate.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.AspNetCore.JsonPatch.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.AspNetCore.Mvc.NewtonsoftJson.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.AspNetCore.OpenApi.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.Bcl.AsyncInterfaces.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.Bcl.Cryptography.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.Build.Framework.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.CodeAnalysis.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.CodeAnalysis.CSharp.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.CodeAnalysis.CSharp.Workspaces.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.CodeAnalysis.Workspaces.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.CodeAnalysis.ExternalAccess.RazorCompiler.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.CodeAnalysis.Workspaces.MSBuild.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.Data.SqlClient.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.EntityFrameworkCore.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.EntityFrameworkCore.Abstractions.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.EntityFrameworkCore.Design.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.EntityFrameworkCore.Relational.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.EntityFrameworkCore.SqlServer.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.Extensions.DependencyModel.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.Identity.Client.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.Identity.Client.Extensions.Msal.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.IdentityModel.Abstractions.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.IdentityModel.JsonWebTokens.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.IdentityModel.Logging.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.IdentityModel.Protocols.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.IdentityModel.Protocols.OpenIdConnect.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.IdentityModel.Tokens.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.OpenApi.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.SqlServer.Server.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Microsoft.VisualStudio.SolutionPersistence.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Mono.TextTemplating.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Newtonsoft.Json.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Newtonsoft.Json.Bson.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Swashbuckle.AspNetCore.Swagger.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Swashbuckle.AspNetCore.SwaggerGen.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\Swashbuckle.AspNetCore.SwaggerUI.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.ClientModel.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.CodeDom.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Composition.AttributedModel.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Composition.Convention.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Composition.Hosting.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Composition.Runtime.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Composition.TypedParts.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Configuration.ConfigurationManager.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.DirectoryServices.Protocols.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.IdentityModel.Tokens.Jwt.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Memory.Data.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\System.Security.Cryptography.ProtectedData.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\cs\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\de\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\es\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\fr\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\it\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ja\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ko\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pl\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pt-BR\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ru\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\tr\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hans\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hant\Microsoft.CodeAnalysis.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\cs\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\de\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\es\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\fr\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\it\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ja\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ko\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pl\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pt-BR\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ru\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\tr\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hans\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hant\Microsoft.CodeAnalysis.CSharp.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\cs\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\de\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\es\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\fr\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\it\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ja\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ko\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pl\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pt-BR\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ru\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\tr\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hans\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hant\Microsoft.CodeAnalysis.CSharp.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\cs\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\de\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\es\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\fr\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\it\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ja\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ko\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pl\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pt-BR\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ru\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\tr\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hans\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hant\Microsoft.CodeAnalysis.Workspaces.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\cs\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\de\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\es\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\fr\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\it\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ja\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ko\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pl\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pt-BR\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ru\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\tr\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hans\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hant\Microsoft.CodeAnalysis.Workspaces.MSBuild.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\cs\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\de\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\es\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\fr\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\it\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ja\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ko\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pl\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\pt-BR\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\ru\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\tr\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hans\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\zh-Hant\Microsoft.Data.SqlClient.resources.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\unix\lib\net9.0\Microsoft.Data.SqlClient.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\win\lib\net9.0\Microsoft.Data.SqlClient.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\win-arm64\native\Microsoft.Data.SqlClient.SNI.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\win-x64\native\Microsoft.Data.SqlClient.SNI.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\win-x86\native\Microsoft.Data.SqlClient.SNI.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\linux\lib\net10.0\System.DirectoryServices.Protocols.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\osx\lib\net10.0\System.DirectoryServices.Protocols.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\bin\Debug\net10.0\runtimes\win\lib\net10.0\System.DirectoryServices.Protocols.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.csproj.AssemblyReference.cache
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\rpswa.dswa.cache.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.GeneratedMSBuildEditorConfig.editorconfig
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.AssemblyInfoInputs.cache
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.AssemblyInfo.cs
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.csproj.CoreCompileInputs.cache
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.MvcApplicationPartsAssemblyInfo.cs
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.MvcApplicationPartsAssemblyInfo.cache
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\rjimswa.dswa.cache.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\rjsmrazor.dswa.cache.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\rjsmcshtml.dswa.cache.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\scopedcss\bundle\Microsoft.SelfService.Portal.Core.API.styles.css
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\staticwebassets.build.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\staticwebassets.build.json.cache
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\staticwebassets.development.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\staticwebassets.build.endpoints.json
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\swae.build.ex.cache
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsof.CC767D45.Up2Date
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\refint\Microsoft.SelfService.Portal.Core.API.dll
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.pdb
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\Microsoft.SelfService.Portal.Core.API.genruntimeconfig.cache
C:\Users\CodexSandboxOffline\.codex\.sandbox\cwd\d792b6c97b5c3243\.Net\Microsoft.SelfService.Portal.Core.API\obj\Debug\net10.0\ref\Microsoft.SelfService.Portal.Core.API.dll

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -4369,7 +4369,7 @@
"code": "NU1903",
"level": "Warning",
"warningLevel": 1,
"message": "Package 'Microsoft.OpenApi' 2.4.1 has a known high severity vulnerability, https://github.com/advisories/GHSA-v5pm-xwqc-g5wc",
"message": "Das Paket \"Microsoft.OpenApi\" 2.4.1 weist eine bekannte hoch Schweregrad-Sicherheitsanfälligkeit auf, https://github.com/advisories/GHSA-v5pm-xwqc-g5wc.",
"libraryId": "Microsoft.OpenApi",
"targetGraphs": [
"net10.0"

View File

@@ -69,7 +69,7 @@
{
"code": "NU1903",
"level": "Warning",
"message": "Package 'Microsoft.OpenApi' 2.4.1 has a known high severity vulnerability, https://github.com/advisories/GHSA-v5pm-xwqc-g5wc",
"message": "Das Paket \"Microsoft.OpenApi\" 2.4.1 weist eine bekannte hoch Schweregrad-Sicherheitsanfälligkeit auf, https://github.com/advisories/GHSA-v5pm-xwqc-g5wc.",
"projectPath": "F:\\Projekte\\Coding\\.Net\\Microsoft.SelfService.Portal.Core.API\\Microsoft.SelfService.Portal.Core.API.csproj",
"warningLevel": 1,
"filePath": "F:\\Projekte\\Coding\\.Net\\Microsoft.SelfService.Portal.Core.API\\Microsoft.SelfService.Portal.Core.API.csproj",