The AWS SDK for Kotlin uses a Smithy transformer to remove operations from service models in order to generate minimized service clients for use in credentials providers such as STS, SSO, Signin, etc. Removing operations via Smithy's ModelTransformer.filterShapes API does not update the endpoint ruleset (or its BDD equivalent) in the service model. This can lead to a situation where ruleset parameters defined in a service's endpointRuleSet trait are not resolvable against the set of parameters defined in operations' staticContextParams, operationContextParams, etc. Essentially, ruleset parameters may become orphaned by shape removals. This is turn causes Smithy's RuleSetParameterValidator to fail.
Smithy's built-in APIs for transforming models should be ruleset-aware so that they do not cause validators to fail on otherwise-valid transformations. Alternatively, Smithy could provide additional APIs for transforming rulesets which could be incorporated into calling code to achieve the same effect.
The AWS SDK for Kotlin uses a Smithy transformer to remove operations from service models in order to generate minimized service clients for use in credentials providers such as STS, SSO, Signin, etc. Removing operations via Smithy's
ModelTransformer.filterShapesAPI does not update the endpoint ruleset (or its BDD equivalent) in the service model. This can lead to a situation where ruleset parameters defined in a service'sendpointRuleSettrait are not resolvable against the set of parameters defined in operations'staticContextParams,operationContextParams, etc. Essentially, ruleset parameters may become orphaned by shape removals. This is turn causes Smithy'sRuleSetParameterValidatorto fail.Smithy's built-in APIs for transforming models should be ruleset-aware so that they do not cause validators to fail on otherwise-valid transformations. Alternatively, Smithy could provide additional APIs for transforming rulesets which could be incorporated into calling code to achieve the same effect.