Document DryRun/Plan feature and update module version#497
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds a terraform-style “planning” mode to Publish-AdfV2FromJson by introducing -Plan (alias behavior of -DryRun) and emitting a structured Create/Update/Delete/Unchanged plan that can be consumed in CI/CD, alongside documentation, tests, and a module version bump.
Changes:
- Added
-Planswitch (alias behavior of-DryRun) and attached aDryRunPlanobject to the returned ADF object during dry runs. - Implemented plan generation/printing helpers (
Get-DryRunPlan,Write-DryRunPlan) to produce terraform-like output. - Updated docs/tests and bumped module version to
1.18.0(with changelog entry).
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| test/Publish-AdfV2FromJson-DryRun.Tests.ps1 | Adds unit tests validating DryRunPlan classification and -Plan alias behavior. |
| README.md | Documents the new DryRun/Plan output format and CI policy usage example; fixes “Stoping” typo. |
| public/Publish-AdfV2FromJson.ps1 | Adds -Plan switch, loads target ADF in dry run for classification, and returns DryRunPlan. |
| private/ApplyExclusionOptions.ps1 | Adds functions to compute and print a terraform-style plan. |
| docs/GUIDE/PUBLISHING.md | Updates cmdlet signature and describes -Plan behavior. |
| docs/ADVANCED/CMDLET_REFERENCE.md | Updates cmdlet signature and parameter list to include -Plan. |
| changelog.md | Adds 1.18.0 entry describing the new planning feature. |
| azure.datafactory.tools.psd1 | Bumps module version to 1.18.0. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+267
to
+269
| $dryRunPlan = $null | ||
| if ($DryRun.IsPresent) { | ||
| $targetAdfInstance = $null |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces a major enhancement to the
Publish-AdfV2FromJsoncmdlet by adding a terraform-style planning mode for deployments, along with documentation updates and supporting code changes. The new-Planswitch (an alias for-DryRun) provides a clear, structured summary of intended changes (create, update, delete, unchanged) and exposes this plan for CI/CD policy enforcement. Documentation and tests have been updated to reflect and validate this new functionality.New Planning Feature:
Added a
-Planswitch toPublish-AdfV2FromJson, acting as an alias for-DryRunbut with terraform-style intent and output. The plan summarizes changes as create, update, delete, or unchanged, and the result object now includes aDryRunPlanproperty for CI/CD checks. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11]Implemented supporting functions in
ApplyExclusionOptions.ps1to generate and print the terraform-like plan, including detailed classification of objects. [1] [2]Documentation Updates:
README.md,CMDLET_REFERENCE.md,PUBLISHING.md) to describe the new-Planswitch, its output format, and CI/CD usage examples. Also fixed a typo ("Stoping" → "Stopping"). [1] [2] [3] [4] [5] [6]Testing Enhancements:
-Planbehaves as an alias for-DryRun. [1] [2]Other Changes:
1.18.0inazure.datafactory.tools.psd1.