Skip to content

Add runtime catalog database connection options - #449

Closed
Petebro-MSFT (Petebro-MSFT) wants to merge 13 commits into
masterfrom
copilot/database-connection-options-20261015
Closed

Petebro-MSFT (Petebro-MSFT) wants to merge 13 commits into
masterfrom
copilot/database-connection-options-20261015

Conversation

@Petebro-MSFT

Copy link
Copy Markdown
Contributor

Expose runtime encryption, multi-subnet failover and certificate trust through capability-checked named WMI inputs. Preserve setup-only TLS parameters and legacy defaults; document server API requirements and add focused mock coverage.

Fixes # .

Changes proposed in this pull request:

How to test this code:

Has been tested on (remove any that don't apply):

  • Powershell 3 and above
  • Windows 7 and above
  • SQL Server 2012 and above

Expose runtime encryption, multi-subnet failover and certificate trust through capability-checked named WMI inputs. Preserve setup-only TLS parameters and legacy defaults; document server API requirements and add focused mock coverage.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Use the documented minimum NuGet provider version and terminate on bootstrap errors before installing test dependencies.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The TLS-only rerun still failed before tests. Select a documented Windows PowerShell 5.1 image, avoid unnecessary provider discovery when a sufficient provider is already available, and log bootstrap tool versions for remaining infrastructure diagnosis.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Keep running all discovered tests, upload results as each file completes, and dump server logs after the first failing file before the runner time limit can discard them. Preserve test discovery order and report per-file durations.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Recognize the WMI VARIANT_TRUE string when changing failover or runtime certificate trust without an encryption option. Cover both cmdlets on Boolean-only and modern providers, including zero-valued false controls.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Use the folder policy endpoint for direct and recursive folder reads and construct each pipeline item's URI independently. Cover folder/report routes, recursive children, pipeline input and surfaced request errors.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The old first poll could be skipped because an array containing null has count one. Poll actual history until the exact expected entries have terminal status, with a bounded stopwatch timeout and one-second polling. Keep the original exact-count assertions and cover pending, missing, failed, excess and request-error states offline.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Build writable policy bodies explicitly for grant and revoke, preserving policy arrays and error propagation.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

WMI capability checks need correction, and preservation of omitted security settings requires validation against supported report-server builds.

1 open issue
What changed in this PR

Adds runtime catalog connection options to the database administration cmdlets, separate from setup SQL connection settings. The PR also updates REST policy handling and test infrastructure.

Changes:

  • Adds capability-checked runtime encryption, multi-subnet failover, and certificate-trust options with documentation and mock coverage.
  • Cleans REST policy write payloads and corrects folder and pipeline policy-read routes.
  • Adds refresh-history completion polling and per-file CI test reporting.
File Description
Tests/​Unit/​RestAccessPolicy.Tests.ps1 Covers policy payloads, routes, and failures.
Tests/​Unit/​RefreshHistoryWait.Tests.ps1 Covers refresh polling and timeout behavior.
Tests/​Unit/​DatabaseConnectionOptions.Tests.ps1 Covers runtime options and provider capabilities.
Tests/​Common/​Wait-RsTestRefreshHistory.ps1 Adds bounded polling for terminal refresh history.
Tests/​CatalogItems/​Rest/​Get-RsRestCacheRefreshPlanHistory.Tests.ps1 Waits for completion before subsequent refreshes.
ReportingServicesTools/​Functions/​Security/​Rest/​Revoke-RsRestItemAccessPolicy.ps1 Excludes response-only fields from policy writes.
ReportingServicesTools/​Functions/​Security/​Rest/​Grant-RsRestItemAccessPolicy.ps1 Builds a writable policy request model.
ReportingServicesTools/​Functions/​Security/​Rest/​Get-RsRestItemAccessPolicy.ps1 Selects policy routes per item and type.
ReportingServicesTools/​Functions/​Common/​Get-RsDatabaseConnectionParameters.ps1 Builds capability-checked named WMI inputs.
ReportingServicesTools/​Functions/​Admin/​Set-RsDatabaseCredentials.ps1 Exposes runtime options when updating credentials.
ReportingServicesTools/​Functions/​Admin/​Set-RsDatabase.ps1 Exposes runtime options when configuring the catalog.
README.md Documents setup/runtime separation and server requirements.
appveyor.yml Updates CI initialization and per-file test reporting.

Review effort: Balanced

Comment thread ReportingServicesTools/Functions/Common/Get-RsDatabaseConnectionParameters.ps1 Outdated
… ci]

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: f2cc77f6-40eb-41b5-ad08-df3c6b762d3f
…p ci]

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: f2cc77f6-40eb-41b5-ad08-df3c6b762d3f
Updated DatabaseEncryptMode parameter to include True and False options, clarifying their equivalence to Mandatory and Optional.
Updated descriptions for DatabaseEncryptMode and DatabaseMultiSubnetFailover options in README.
@Petebro-MSFT

Copy link
Copy Markdown
Contributor Author

Superseded by #452 (recreated on current master, including #451). Closing in favor of that PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants