Skip to content

Conversation

michele-tahay-kohera
Copy link

Changes this PR brings

  • fixed error in getting AO details when running on a machine with multiple named instances (each instance with 1 AG)
  • fixed empty cluster object when getting internal AO error

Remarks:
I tried following the instructions on how to test a PR, but did not manage to get the required result. The instructions were confusing for me:

  • no folder .\tests available, changing it to .\checks did a little bit better
  • Get-ManifestValue was not recognised, but changed the requiredversions parameter with fixed-values
  • Exclusions of "integration" tags while we would want them to run?
  • tests then seemed to execute all checks on the SqlInstance values of my last check. It did execute, but of course some of the checks fails (because which server would be 100% ok in the real world :) )

I did test these changes in a custom version of HADR.Test1 file that I include in my DbaChecks project, they work there now and much less failed tests for that one server I had trouble with.

The Find-DbaInstance returns an object for the browser service when there are multiple (named) instances on one machine. This makes the subsequent Get-DbaAvailabilityGroup call fail.
When an error occurs in getting AG info, the whole $result object should not be nullified
@michele-tahay-kohera
Copy link
Author

This file was not present in the "development" branch, and I had no idea to which branch I could push my modifications...

@michele-tahay-kohera michele-tahay-kohera marked this pull request as draft August 29, 2025 13:46
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.

1 participant