generated from amazon-archives/__template_Apache-2.0
-
Notifications
You must be signed in to change notification settings - Fork 271
Closed as not planned
Labels
kind/enhancementCategorizes issue or PR as related to existing feature enhancements.Categorizes issue or PR as related to existing feature enhancements.lifecycle/frozenIndicates that an issue or PR should not be auto-closed due to staleness.Indicates that an issue or PR should not be auto-closed due to staleness.
Description
Is your feature request related to a problem?
Ability to specify fields initialized by service post create. Following are the patterns observed:
- Generated fields. Example:
- roleARN field in ScalableTarget resource is generated by service. See Handle server-side defaults applicationautoscaling-controller#12 (comment) (service - Applicationautoscaling)
- staticHyperparameter field in Hyperparameter tuning resource. Slice has some extra fields returned from the service which should be ignored for comparison. See customSetDefaults in HPJob (service - SageMaker)
- Default value for fields
- Boolean fields returned as False.
- Scalable target struct in ScalableTarget resource -
SuspendedState.<*>(all fields) returned as False by default. See setDefaults in autoscaling (service - Applicationautoscaling)
- Scalable target struct in ScalableTarget resource -
- String fields return default values. e.g. Model resource -
PrimaryContainer.Moderetuned asSingleModeby default (service - SageMaker)
- Boolean fields returned as False.
Describe the solution you'd like
1.a, 2.a, 2.b - if DesiredResource.Spec.field = nil set these values from latestResource
1.b - a hook to write custom algorithm for comparison and remove service generated fields, ignore setting values from latestResource to desired
Note: In 2.a,
- whole desired.spec.SuspendedState == nil and service still returns false values for all fields in the structs (
DynamicScalingInSuspended, DynamicScalingInSuspended, ScheduledScalingSuspended) desired.spec.SuspendedState!= nil butdesired.spec.SuspendedState.DynamicScalingInSuspended== nil and service still returns False fordesired.spec.SuspendedState.DynamicScalingInSuspended
Describe alternatives you've considered
1.b - a hook to write custom logic to insert only server generated <key, value> pairs into the slice only if diff is False
1.b - a hook to write custom algorithm for comparison and insert service generated fields, set values from latestResource into desired only for comparison
Metadata
Metadata
Assignees
Labels
kind/enhancementCategorizes issue or PR as related to existing feature enhancements.Categorizes issue or PR as related to existing feature enhancements.lifecycle/frozenIndicates that an issue or PR should not be auto-closed due to staleness.Indicates that an issue or PR should not be auto-closed due to staleness.