-
Notifications
You must be signed in to change notification settings - Fork 88
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
ResourceRecordSet object always has a weight
property even when Weighted Routing is not enabled
#344
Comments
@appleoddity Good morning. Thanks for reporting the issue. AWS Tools for PowerShell uses AWS .NET SDK behind the scenes. Looking at the property definition for Weight, even though it has the This is a breaking change for current version of SDK. Also, the property definition in this case is generated from service models. There is a similar issue aws/aws-sdk-net#1721 (comment) in our backlog to be queued for fix in the next version of AWS .NET SDK. CCing @normj for visibility. Thanks, |
@appleoddity In case you are blocked by this issue, we could do a customization to expose public Thanks, |
Thank you for the fast response and explanation. If it's in the backlog, I will wait until the next release. I went ahead and worked around the problem now, because I didn't actually have any weighted records. The only thing I want to point out is I believe TTL has the same problem. If the record is an alias, there is no TTL value, yet it exports as |
This has been fixed in AWS Tools for PowerShell version Instructions:
Closing this issue. |
|
Describe the bug
When I call the
Get-R53ResourceRecordSet
function for a hosted zone it returns a collection of ResourceRecordSet. The value of theweight
property is 0 even when there is no Weighted Routing policy applied. In contrast, the documentation indicates that theweight
property only applies to weighted resource record sets only. For this reason, it is impossible to determine if the exported resource is supposed to have a weighted routing policy or not.I am using Powershell 7.
Expected Behavior
Similar to the aws cli, I expect the
weight
property to be null or undefined when the record does not have a weighted routing policy applied.Current Behavior
The
weight
property is 0 even when no weighted routing policy is enabled. A value of0
has special meaning and this created ambiguity. I assume because theweight
property is typed to Int64 .NET is converting a null value to 0.Reproduction Steps
(Get-R53ResourceRecordSet -HostedZoneId $zone.Id -MaxItem 1000).ResourceRecordSets
Observe the
weight
property on the exported resource records.Possible Solution
No response
Additional Information/Context
No response
AWS .NET SDK and/or Package version used
AWS Tools for PowerShell
Version 4.1.547
Copyright 2012-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
Amazon Web Services SDK for .NET
Core Runtime Version 3.7.303.4
Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
Targeted .NET Platform
.NET Core
Operating System and version
Ubuntu w/ Powershell 7
The text was updated successfully, but these errors were encountered: