-
Notifications
You must be signed in to change notification settings - Fork 4k
[Azure Analysis Services] Enable associate/dissociate gateway with AS. #6043
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@@ -82,6 +82,18 @@ public class NewAnalysisServicesServer : AnalysisServicesCmdletBase | |||
HelpMessage = "Firewall configuration")] | |||
public PsAzureAnalysisServicesFirewallConfig FirewallConfig { get; set; } | |||
|
|||
[Parameter(ValueFromPipelineByPropertyName = true, Mandatory = false, | |||
HelpMessage = "Gateway resource name")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should allow them to specify the gateway by resource ID instead, they are much more likely to have this value
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We construct the resource ID internally, but sure.
@@ -88,6 +88,22 @@ public int ReadonlyReplicaCount | |||
HelpMessage = "Firewall configuration")] | |||
public PsAzureAnalysisServicesFirewallConfig FirewallConfig { get; set; } | |||
|
|||
[Parameter(ValueFromPipelineByPropertyName = true, Mandatory = false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@markcowl updated, please review again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These should be in separate parameter sets.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@markcowl updated
ping @markcowl |
ping @markcowl and @maddieclayton |
@taiwu You need to have a cmdlet review for any public api changes: https://github.com/azure/azure-powershell-cmdlet-review-pr/issues |
@@ -88,6 +88,22 @@ public int ReadonlyReplicaCount | |||
HelpMessage = "Firewall configuration")] | |||
public PsAzureAnalysisServicesFirewallConfig FirewallConfig { get; set; } | |||
|
|||
[Parameter(ValueFromPipelineByPropertyName = true, Mandatory = false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These should be in separate parameter sets.
cmdlet review already added last week. https://github.com/Azure/azure-powershell-pr/wiki/Cmdlet-Reviews |
Updated the parameter sets and help doc, cmdlet review is https://github.com/Azure/azure-powershell-cmdlet-review-pr/issues/67 |
@azuresdkci retest this please |
@@ -21,6 +21,7 @@ | |||
|
|||
## Version 0.6.7 | |||
* Set minimum dependency of module to PowerShell 5.0 | |||
* Enable Gateway assocaite/disassociate operations on AS. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should go directly under Current Release... We will move it to under a new version header when we generate the release version.
$resourceGroupName = Get-ResourceGroupName | ||
$serverName = Get-AnalysisServicesServerName | ||
$gatewayName = $env:GATEWAY_NAME | ||
$gateway = Get-AzureRmResource -ResourceName $gatewayName -ResourceGroupName $resourceGroupName |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So, this test assumes that the gateway server already exists in the subscription/RG... Is it possible to create the gateway server as part of the test?
Otherwise some one (lets say a person in the PS team) would not be able to re-record the test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This have to be a pre-setup azure resource, which requires user to install unified gateway on their on-premise server and generate an gateway azure resource associated on it. It is not possible to automate the procedure in few lines of powershell scripts. This is LiveOnly test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok... can you add a comment to the test case that describes what all needs to be done for one to be able to set up the gateway server , the documentation could be as simple as pointing the person to follow an online guide on how to get it done as well ;) )?
That way the person running the test will have the instructions to do so....
AnalysisServicesServer updatedServer = AnalysisServicesClient.CreateOrUpdateServer(ResourceGroupName, Name, location, Sku, Tag, Administrator, currentServer, BackupBlobContainerUri, ReadonlyReplicaCount, DefaultConnectionMode, setting); | ||
if (DisassociateGateway.IsPresent) | ||
{ | ||
GatewayResourceId = "-"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to see this special value, namely "-" defined in a common file as a constant in some common codethat can be comsumed from the various places this is used.
@@ -87,6 +88,16 @@ public AnalysisServicesClient() | |||
} | |||
} | |||
|
|||
GatewayDetails gatewayDetails = null; | |||
if (gatewayResourceId == "-") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to see this special value, namely "-" defined in a common file as a constant in some common codethat can be comsumed from the various places this is used.
@markcowl Please take a look, the parameter sets are updated. |
Description
Checklist
CONTRIBUTING.md
platyPS
module