AWS SDK

AWS SDK

rev. 5673a7a38b4a4a6973351c005d572863803729fe

Files changed:

tmp-codegen-diff/aws-sdk/sdk/aws-config/Cargo.toml

@@ -44,44 +104,104 @@
   64     64   
version = "0.61.4"
   65     65   
   66     66   
[dependencies.aws-smithy-runtime]
   67     67   
path = "../aws-smithy-runtime"
   68     68   
features = ["client"]
   69     69   
version = "1.8.6"
   70     70   
   71     71   
[dependencies.aws-smithy-runtime-api]
   72     72   
path = "../aws-smithy-runtime-api"
   73     73   
features = ["client"]
   74         -
version = "1.8.6"
          74  +
version = "1.8.7"
   75     75   
   76     76   
[dependencies.aws-smithy-types]
   77     77   
path = "../aws-smithy-types"
   78     78   
version = "1.3.2"
   79     79   
   80     80   
[dependencies.aws-types]
   81     81   
path = "../aws-types"
   82     82   
version = "1.3.8"
   83     83   
   84     84   
[dependencies.time]
@@ -111,111 +157,157 @@
  131    131   
version = "1.0.6"
  132    132   
  133    133   
[dev-dependencies.aws-smithy-runtime]
  134    134   
path = "../aws-smithy-runtime"
  135    135   
features = ["client", "test-util"]
  136    136   
version = "1.8.6"
  137    137   
  138    138   
[dev-dependencies.aws-smithy-runtime-api]
  139    139   
path = "../aws-smithy-runtime-api"
  140    140   
features = ["test-util"]
  141         -
version = "1.8.6"
         141  +
version = "1.8.7"
  142    142   
  143    143   
[dev-dependencies.futures-util]
  144    144   
version = "0.3.29"
  145    145   
default-features = false
  146    146   
  147    147   
[dev-dependencies.tracing-subscriber]
  148    148   
version = "0.3.16"
  149    149   
features = ["fmt", "json"]
  150    150   
  151    151   
[dev-dependencies.tokio]

tmp-codegen-diff/aws-sdk/sdk/aws-config/src/lib.rs

@@ -867,867 +1024,1033 @@
  887    887   
                TriStateOption::Set(provider) => Some(provider),
  888    888   
                TriStateOption::NotSet => {
  889    889   
                    let mut builder =
  890    890   
                        credentials::DefaultCredentialsChain::builder().configure(conf.clone());
  891    891   
                    builder.set_region(region.clone());
  892    892   
                    Some(SharedCredentialsProvider::new(builder.build().await))
  893    893   
                }
  894    894   
                TriStateOption::ExplicitlyUnset => None,
  895    895   
            };
  896    896   
  897         -
            let token_provider = match self.token_provider {
  898         -
                Some(provider) => Some(provider),
  899         -
                None => {
  900         -
                    #[cfg(feature = "sso")]
  901         -
                    {
  902         -
                        let mut builder =
  903         -
                            crate::default_provider::token::DefaultTokenChain::builder()
  904         -
                                .configure(conf.clone());
  905         -
                        builder.set_region(region.clone());
  906         -
                        Some(SharedTokenProvider::new(builder.build().await))
  907         -
                    }
  908         -
                    #[cfg(not(feature = "sso"))]
  909         -
                    {
  910         -
                        None
  911         -
                    }
  912         -
                }
  913         -
            };
  914         -
  915    897   
            let profiles = conf.profile().await;
  916    898   
            let service_config = EnvServiceConfig {
  917    899   
                env: conf.env(),
  918    900   
                env_config_sections: profiles.cloned().unwrap_or_default(),
  919    901   
            };
  920    902   
            let mut builder = SdkConfig::builder()
  921         -
                .region(region)
         903  +
                .region(region.clone())
  922    904   
                .retry_config(retry_config)
  923    905   
                .timeout_config(timeout_config)
  924    906   
                .time_source(time_source)
  925    907   
                .service_config(service_config);
  926    908   
  927    909   
            // If an endpoint URL is set programmatically, then our work is done.
  928    910   
            let endpoint_url = if self.endpoint_url.is_some() {
  929    911   
                builder.insert_origin("endpoint_url", Origin::shared_config());
  930    912   
                self.endpoint_url
  931    913   
            } else {
  932    914   
                // Otherwise, check to see if we should ignore EP URLs set in the environment.
  933    915   
                let ignore_configured_endpoint_urls =
  934    916   
                    ignore_ep::ignore_configured_endpoint_urls_provider(&conf)
  935    917   
                        .await
  936    918   
                        .unwrap_or_default();
  937    919   
  938    920   
                if ignore_configured_endpoint_urls {
  939    921   
                    // If yes, log a trace and return `None`.
  940    922   
                    tracing::trace!(
  941    923   
                        "`ignore_configured_endpoint_urls` is set, any endpoint URLs configured in the environment will be ignored. \
  942    924   
                        NOTE: Endpoint URLs set programmatically WILL still be respected"
  943    925   
                    );
  944    926   
                    None
  945    927   
                } else {
  946    928   
                    // Otherwise, attempt to resolve one.
  947    929   
                    let (v, origin) = endpoint_url::endpoint_url_provider_with_origin(&conf).await;
  948    930   
                    builder.insert_origin("endpoint_url", origin);
  949    931   
                    v
  950    932   
                }
  951    933   
            };
  952    934   
         935  +
            let token_provider = match self.token_provider {
         936  +
                Some(provider) => {
         937  +
                    builder.insert_origin("token_provider", Origin::shared_config());
         938  +
                    Some(provider)
         939  +
                }
         940  +
                None => {
         941  +
                    #[cfg(feature = "sso")]
         942  +
                    {
         943  +
                        let mut builder =
         944  +
                            crate::default_provider::token::DefaultTokenChain::builder()
         945  +
                                .configure(conf.clone());
         946  +
                        builder.set_region(region);
         947  +
                        Some(SharedTokenProvider::new(builder.build().await))
         948  +
                    }
         949  +
                    #[cfg(not(feature = "sso"))]
         950  +
                    {
         951  +
                        None
         952  +
                    }
         953  +
                    // Not setting `Origin` in this arm, and that's good for now as long as we know
         954  +
                    // it's not programmatically set in the shared config.
         955  +
                    // We can consider adding `Origin::Default` if needed.
         956  +
                }
         957  +
            };
         958  +
  953    959   
            builder.set_endpoint_url(endpoint_url);
  954    960   
            builder.set_behavior_version(self.behavior_version);
  955    961   
            builder.set_http_client(self.http_client);
  956    962   
            builder.set_app_name(app_name);
  957    963   
  958    964   
            let identity_cache = match self.identity_cache {
  959    965   
                None => match self.behavior_version {
  960    966   
                    #[allow(deprecated)]
  961    967   
                    Some(bv) if bv.is_at_least(BehaviorVersion::v2024_03_28()) => {
  962    968   
                        Some(IdentityCache::lazy().build())
  963    969   
                    }
  964    970   
                    _ => None,
  965    971   
                },
  966    972   
                Some(user_cache) => Some(user_cache),
  967    973   
            };
  968    974   
  969    975   
            let request_checksum_calculation =
  970    976   
                if let Some(request_checksum_calculation) = self.request_checksum_calculation {
  971    977   
                    Some(request_checksum_calculation)
  972    978   
                } else {
  973    979   
                    checksums::request_checksum_calculation_provider(&conf).await
  974    980   
                };
  975    981   
  976    982   
            let response_checksum_validation =
  977    983   
                if let Some(response_checksum_validation) = self.response_checksum_validation {
  978    984   
                    Some(response_checksum_validation)
  979    985   
                } else {
  980    986   
                    checksums::response_checksum_validation_provider(&conf).await
  981    987   
                };
  982    988   
  983    989   
            let account_id_endpoint_mode =
  984    990   
                if let Some(acccount_id_endpoint_mode) = self.account_id_endpoint_mode {
  985    991   
                    Some(acccount_id_endpoint_mode)
  986    992   
                } else {
  987    993   
                    account_id_endpoint_mode::account_id_endpoint_mode_provider(&conf).await
  988    994   
                };
  989    995   
  990    996   
            let auth_scheme_preference =
  991    997   
                if let Some(auth_scheme_preference) = self.auth_scheme_preference {
         998  +
                    builder.insert_origin("auth_scheme_preference", Origin::shared_config());
  992    999   
                    Some(auth_scheme_preference)
  993   1000   
                } else {
  994   1001   
                    auth_scheme_preference::auth_scheme_preference_provider(&conf).await
        1002  +
                    // Not setting `Origin` in this arm, and that's good for now as long as we know
        1003  +
                    // it's not programmatically set in the shared config.
  995   1004   
                };
  996   1005   
  997   1006   
            builder.set_request_checksum_calculation(request_checksum_calculation);
  998   1007   
            builder.set_response_checksum_validation(response_checksum_validation);
  999   1008   
            builder.set_identity_cache(identity_cache);
 1000   1009   
            builder.set_credentials_provider(credentials_provider);
 1001   1010   
            builder.set_token_provider(token_provider);
 1002   1011   
            builder.set_sleep_impl(sleep_impl);
 1003   1012   
            builder.set_use_fips(use_fips);
 1004   1013   
            builder.set_use_dual_stack(use_dual_stack);

tmp-codegen-diff/aws-sdk/sdk/aws-credential-types/Cargo.toml

@@ -7,7 +49,49 @@
   27     27   
path = "../aws-smithy-async"
   28     28   
version = "1.2.5"
   29     29   
   30     30   
[dependencies.aws-smithy-types]
   31     31   
path = "../aws-smithy-types"
   32     32   
version = "1.3.2"
   33     33   
   34     34   
[dependencies.aws-smithy-runtime-api]
   35     35   
path = "../aws-smithy-runtime-api"
   36     36   
features = ["client", "http-auth"]
   37         -
version = "1.8.6"
          37  +
version = "1.8.7"
   38     38   
   39     39   
[dev-dependencies]
   40     40   
async-trait = "0.1.74"
   41     41   
   42     42   
[dev-dependencies.aws-smithy-runtime-api]
   43     43   
path = "../aws-smithy-runtime-api"
   44     44   
features = ["test-util"]
   45         -
version = "1.8.6"
          45  +
version = "1.8.7"
   46     46   
   47     47   
[dev-dependencies.tokio]
   48     48   
version = "1.23.1"
   49     49   
features = ["full", "test-util", "rt"]

tmp-codegen-diff/aws-sdk/sdk/aws-credential-types/src/credential_feature.rs

@@ -18,18 +52,54 @@
   38     38   
    /// An operation called using credentials resolved from an SSO session
   39     39   
    CredentialsSso,
   40     40   
    /// An operation called using credentials resolved from a process in a config file(s) profile
   41     41   
    CredentialsProfileProcess,
   42     42   
    /// An operation called using credentials resolved from a process
   43     43   
    CredentialsProcess,
   44     44   
    /// An operation called using credentials resolved from an HTTP endpoint
   45     45   
    CredentialsHttp,
   46     46   
    /// An operation called using credentials resolved from the instance metadata service (IMDS)
   47     47   
    CredentialsImds,
          48  +
    /// An operation called using a Bearer token resolved from service-specific environment variables
          49  +
    BearerServiceEnvVars,
   48     50   
}
   49     51   
   50     52   
impl Storable for AwsCredentialFeature {
   51     53   
    type Storer = StoreAppend<Self>;
   52     54   
}

tmp-codegen-diff/aws-sdk/sdk/aws-runtime/Cargo.toml

@@ -33,33 +144,144 @@
   53     53   
version = "0.62.3"
   54     54   
   55     55   
[dependencies.aws-smithy-runtime]
   56     56   
path = "../aws-smithy-runtime"
   57     57   
features = ["client"]
   58     58   
version = "1.8.6"
   59     59   
   60     60   
[dependencies.aws-smithy-runtime-api]
   61     61   
path = "../aws-smithy-runtime-api"
   62     62   
features = ["client"]
   63         -
version = "1.8.6"
          63  +
version = "1.8.7"
   64     64   
   65     65   
[dependencies.aws-smithy-types]
   66     66   
path = "../aws-smithy-types"
   67     67   
version = "1.3.2"
   68     68   
   69     69   
[dependencies.aws-types]
   70     70   
path = "../aws-types"
   71     71   
version = "1.3.8"
   72     72   
   73     73   
[dependencies.http-02x]
   74     74   
package = "http"
   75     75   
version = "0.2.9"
   76     76   
   77     77   
[dependencies.http-body-04x]
   78     78   
package = "http-body"
   79     79   
version = "0.4.5"
   80     80   
   81     81   
[dependencies.http-1x]
   82     82   
package = "http"
   83     83   
version = "1.1.0"
   84     84   
optional = true
   85     85   
   86     86   
[dependencies.http-body-1x]
   87     87   
package = "http-body"
   88     88   
version = "1.0.0"
   89     89   
optional = true
   90     90   
   91     91   
[dependencies.regex-lite]
   92     92   
version = "0.1.5"
   93     93   
optional = true
   94     94   
   95     95   
[dependencies.uuid]
   96     96   
version = "1"
   97     97   
   98     98   
[dev-dependencies]
   99     99   
arbitrary = "1.3"
  100    100   
bytes-utils = "0.1.2"
  101    101   
convert_case = "0.6.0"
  102    102   
proptest = "1.2"
  103    103   
serde_json = "1"
  104    104   
tracing-test = "0.2.4"
  105    105   
  106    106   
[dev-dependencies.aws-credential-types]
  107    107   
path = "../aws-credential-types"
  108    108   
features = ["test-util"]
  109    109   
version = "1.2.5"
  110    110   
  111    111   
[dev-dependencies.aws-smithy-async]
  112    112   
path = "../aws-smithy-async"
  113    113   
features = ["test-util"]
  114    114   
version = "1.2.5"
  115    115   
  116    116   
[dev-dependencies.aws-smithy-protocol-test]
  117    117   
path = "../aws-smithy-protocol-test"
  118    118   
version = "0.63.4"
  119    119   
  120    120   
[dev-dependencies.aws-smithy-runtime-api]
  121    121   
path = "../aws-smithy-runtime-api"
  122    122   
features = ["test-util"]
  123         -
version = "1.8.6"
         123  +
version = "1.8.7"
  124    124   
  125    125   
[dev-dependencies.aws-smithy-types]
  126    126   
path = "../aws-smithy-types"
  127    127   
features = ["test-util"]
  128    128   
version = "1.3.2"
  129    129   
  130    130   
[dev-dependencies.futures-util]
  131    131   
version = "0.3.29"
  132    132   
default-features = false
  133    133   

tmp-codegen-diff/aws-sdk/sdk/aws-runtime/src/sdk_feature.rs

@@ -1,1 +21,25 @@
    7      7   
/// This module is re-exported in `aws-runtime`, and so even though this is a pre-1.0 crate, this module should not
    8      8   
/// have any breaking changes
    9      9   
use aws_smithy_types::config_bag::{Storable, StoreAppend};
   10     10   
   11     11   
/// IDs for the features that may be used in the AWS SDK
   12     12   
#[non_exhaustive]
   13     13   
#[derive(Clone, Debug, Eq, PartialEq)]
   14     14   
pub enum AwsSdkFeature {
   15     15   
    /// Indicates that an operation was called by the S3 Transfer Manager
   16     16   
    S3Transfer,
          17  +
    /// Calling an SSO-OIDC operation as part of the SSO login flow, when using the OAuth2.0 device code grant
          18  +
    SsoLoginDevice,
          19  +
    /// Calling an SSO-OIDC operation as part of the SSO login flow, when using the OAuth2.0 authorization code grant
          20  +
    SsoLoginAuth,
   17     21   
}
   18     22   
   19     23   
impl Storable for AwsSdkFeature {
   20     24   
    type Storer = StoreAppend<Self>;
   21     25   
}

tmp-codegen-diff/aws-sdk/sdk/aws-runtime/src/user_agent/metrics.rs

@@ -134,134 +280,286 @@
  154    154   
    CredentialsProfileStsWebIdToken,
  155    155   
    CredentialsProfileSso,
  156    156   
    CredentialsSso,
  157    157   
    CredentialsProfileSsoLegacy,
  158    158   
    CredentialsSsoLegacy,
  159    159   
    CredentialsProfileProcess,
  160    160   
    CredentialsProcess,
  161    161   
    CredentialsBoto2ConfigFile,
  162    162   
    CredentialsAwsSdkStore,
  163    163   
    CredentialsHttp,
  164         -
    CredentialsImds
         164  +
    CredentialsImds,
         165  +
    SsoLoginDevice,
         166  +
    SsoLoginAuth,
         167  +
    BearerServiceEnvVars
  165    168   
);
  166    169   
  167    170   
pub(crate) trait ProvideBusinessMetric {
  168    171   
    fn provide_business_metric(&self) -> Option<BusinessMetric>;
  169    172   
}
  170    173   
  171    174   
impl ProvideBusinessMetric for SmithySdkFeature {
  172    175   
    fn provide_business_metric(&self) -> Option<BusinessMetric> {
  173    176   
        use SmithySdkFeature::*;
  174    177   
        match self {
  175    178   
            Waiter => Some(BusinessMetric::Waiter),
  176    179   
            Paginator => Some(BusinessMetric::Paginator),
  177    180   
            GzipRequestCompression => Some(BusinessMetric::GzipRequestCompression),
  178    181   
            ProtocolRpcV2Cbor => Some(BusinessMetric::ProtocolRpcV2Cbor),
  179    182   
            RetryModeStandard => Some(BusinessMetric::RetryModeStandard),
  180    183   
            RetryModeAdaptive => Some(BusinessMetric::RetryModeAdaptive),
  181    184   
            FlexibleChecksumsReqCrc32 => Some(BusinessMetric::FlexibleChecksumsReqCrc32),
  182    185   
            FlexibleChecksumsReqCrc32c => Some(BusinessMetric::FlexibleChecksumsReqCrc32c),
  183    186   
            FlexibleChecksumsReqCrc64 => Some(BusinessMetric::FlexibleChecksumsReqCrc64),
  184    187   
            FlexibleChecksumsReqSha1 => Some(BusinessMetric::FlexibleChecksumsReqSha1),
  185    188   
            FlexibleChecksumsReqSha256 => Some(BusinessMetric::FlexibleChecksumsReqSha256),
  186    189   
            FlexibleChecksumsReqWhenSupported => {
  187    190   
                Some(BusinessMetric::FlexibleChecksumsReqWhenSupported)
  188    191   
            }
  189    192   
            FlexibleChecksumsReqWhenRequired => {
  190    193   
                Some(BusinessMetric::FlexibleChecksumsReqWhenRequired)
  191    194   
            }
  192    195   
            FlexibleChecksumsResWhenSupported => {
  193    196   
                Some(BusinessMetric::FlexibleChecksumsResWhenSupported)
  194    197   
            }
  195    198   
            FlexibleChecksumsResWhenRequired => {
  196    199   
                Some(BusinessMetric::FlexibleChecksumsResWhenRequired)
  197    200   
            }
  198    201   
            otherwise => {
  199    202   
                // This may occur if a customer upgrades only the `aws-smithy-runtime-api` crate
  200    203   
                // while continuing to use an outdated version of an SDK crate or the `aws-runtime`
  201    204   
                // crate.
  202    205   
                tracing::warn!(
  203    206   
                    "Attempted to provide `BusinessMetric` for `{otherwise:?}`, which is not recognized in the current version of the `aws-runtime` crate. \
  204    207   
                    Consider upgrading to the latest version to ensure that all tracked features are properly reported in your metrics."
  205    208   
                );
  206    209   
                None
  207    210   
            }
  208    211   
        }
  209    212   
    }
  210    213   
}
  211    214   
  212    215   
impl ProvideBusinessMetric for AwsSdkFeature {
  213    216   
    fn provide_business_metric(&self) -> Option<BusinessMetric> {
  214    217   
        use AwsSdkFeature::*;
  215    218   
        match self {
  216    219   
            S3Transfer => Some(BusinessMetric::S3Transfer),
         220  +
            SsoLoginDevice => Some(BusinessMetric::SsoLoginDevice),
         221  +
            SsoLoginAuth => Some(BusinessMetric::SsoLoginAuth),
  217    222   
        }
  218    223   
    }
  219    224   
}
  220    225   
  221    226   
impl ProvideBusinessMetric for AwsCredentialFeature {
  222    227   
    fn provide_business_metric(&self) -> Option<BusinessMetric> {
  223    228   
        use AwsCredentialFeature::*;
  224    229   
        match self {
  225    230   
            CredentialsCode => Some(BusinessMetric::CredentialsCode),
  226    231   
            CredentialsEnvVars => Some(BusinessMetric::CredentialsEnvVars),
  227    232   
            CredentialsEnvVarsStsWebIdToken => {
  228    233   
                Some(BusinessMetric::CredentialsEnvVarsStsWebIdToken)
  229    234   
            }
  230    235   
            CredentialsStsAssumeRole => Some(BusinessMetric::CredentialsStsAssumeRole),
  231    236   
            CredentialsStsAssumeRoleSaml => Some(BusinessMetric::CredentialsStsAssumeRoleSaml),
  232    237   
            CredentialsStsAssumeRoleWebId => Some(BusinessMetric::CredentialsStsAssumeRoleWebId),
  233    238   
            CredentialsStsFederationToken => Some(BusinessMetric::CredentialsStsFederationToken),
  234    239   
            CredentialsStsSessionToken => Some(BusinessMetric::CredentialsStsSessionToken),
  235    240   
            CredentialsProfile => Some(BusinessMetric::CredentialsProfile),
  236    241   
            CredentialsProfileSourceProfile => {
  237    242   
                Some(BusinessMetric::CredentialsProfileSourceProfile)
  238    243   
            }
  239    244   
            CredentialsProfileNamedProvider => {
  240    245   
                Some(BusinessMetric::CredentialsProfileNamedProvider)
  241    246   
            }
  242    247   
            CredentialsProfileStsWebIdToken => {
  243    248   
                Some(BusinessMetric::CredentialsProfileStsWebIdToken)
  244    249   
            }
  245    250   
            CredentialsProfileSso => Some(BusinessMetric::CredentialsProfileSso),
  246    251   
            CredentialsSso => Some(BusinessMetric::CredentialsSso),
  247    252   
            CredentialsProfileProcess => Some(BusinessMetric::CredentialsProfileProcess),
  248    253   
            CredentialsProcess => Some(BusinessMetric::CredentialsProcess),
  249    254   
            CredentialsHttp => Some(BusinessMetric::CredentialsHttp),
  250    255   
            CredentialsImds => Some(BusinessMetric::CredentialsImds),
         256  +
            BearerServiceEnvVars => Some(BusinessMetric::BearerServiceEnvVars),
  251    257   
            otherwise => {
  252    258   
                // This may occur if a customer upgrades only the `aws-smithy-runtime-api` crate
  253    259   
                // while continuing to use an outdated version of an SDK crate or the `aws-credential-types`
  254    260   
                // crate.
  255    261   
                tracing::warn!(
  256    262   
                    "Attempted to provide `BusinessMetric` for `{otherwise:?}`, which is not recognized in the current version of the `aws-runtime` crate. \
  257    263   
                    Consider upgrading to the latest version to ensure that all tracked features are properly reported in your metrics."
  258    264   
                );
  259    265   
                None
  260    266   
            }
@@ -309,315 +426,375 @@
  329    335   
                    .as_str()
  330    336   
                    .from_case(Case::Pascal)
  331    337   
                    .with_boundaries(&[Boundary::DigitUpper, Boundary::LowerUpper])
  332    338   
                    .to_case(Case::ScreamingSnake),
  333    339   
            )
  334    340   
        }
  335    341   
    }
  336    342   
  337    343   
    #[test]
  338    344   
    fn feature_id_to_metric_value() {
  339         -
        const EXPECTED: &str = r#"
  340         -
{
  341         -
  "RESOURCE_MODEL": "A",
  342         -
  "WAITER": "B",
  343         -
  "PAGINATOR": "C",
  344         -
  "RETRY_MODE_LEGACY": "D",
  345         -
  "RETRY_MODE_STANDARD": "E",
  346         -
  "RETRY_MODE_ADAPTIVE": "F",
  347         -
  "S3_TRANSFER": "G",
  348         -
  "S3_CRYPTO_V1N": "H",
  349         -
  "S3_CRYPTO_V2": "I",
  350         -
  "S3_EXPRESS_BUCKET": "J",
  351         -
  "S3_ACCESS_GRANTS": "K",
  352         -
  "GZIP_REQUEST_COMPRESSION": "L",
  353         -
  "PROTOCOL_RPC_V2_CBOR": "M",
  354         -
  "ENDPOINT_OVERRIDE": "N",
  355         -
  "ACCOUNT_ID_ENDPOINT": "O",
  356         -
  "ACCOUNT_ID_MODE_PREFERRED": "P",
  357         -
  "ACCOUNT_ID_MODE_DISABLED": "Q",
  358         -
  "ACCOUNT_ID_MODE_REQUIRED": "R",
  359         -
  "SIGV4A_SIGNING": "S",
  360         -
  "RESOLVED_ACCOUNT_ID": "T",
  361         -
  "FLEXIBLE_CHECKSUMS_REQ_CRC32" : "U",
  362         -
  "FLEXIBLE_CHECKSUMS_REQ_CRC32C" : "V",
  363         -
  "FLEXIBLE_CHECKSUMS_REQ_CRC64" : "W",
  364         -
  "FLEXIBLE_CHECKSUMS_REQ_SHA1" : "X",
  365         -
  "FLEXIBLE_CHECKSUMS_REQ_SHA256" : "Y",
  366         -
  "FLEXIBLE_CHECKSUMS_REQ_WHEN_SUPPORTED" : "Z",
  367         -
  "FLEXIBLE_CHECKSUMS_REQ_WHEN_REQUIRED" : "a",
  368         -
  "FLEXIBLE_CHECKSUMS_RES_WHEN_SUPPORTED" : "b",
  369         -
  "FLEXIBLE_CHECKSUMS_RES_WHEN_REQUIRED" : "c",
  370         -
  "DDB_MAPPER" : "d",
  371         -
  "CREDENTIALS_CODE" : "e",
  372         -
  "CREDENTIALS_JVM_SYSTEM_PROPERTIES" : "f",
  373         -
  "CREDENTIALS_ENV_VARS" : "g",
  374         -
  "CREDENTIALS_ENV_VARS_STS_WEB_ID_TOKEN" : "h",
  375         -
  "CREDENTIALS_STS_ASSUME_ROLE" : "i",
  376         -
  "CREDENTIALS_STS_ASSUME_ROLE_SAML" : "j",
  377         -
  "CREDENTIALS_STS_ASSUME_ROLE_WEB_ID" : "k",
  378         -
  "CREDENTIALS_STS_FEDERATION_TOKEN" : "l",
  379         -
  "CREDENTIALS_STS_SESSION_TOKEN" : "m",
  380         -
  "CREDENTIALS_PROFILE" : "n",
  381         -
  "CREDENTIALS_PROFILE_SOURCE_PROFILE" : "o",
  382         -
  "CREDENTIALS_PROFILE_NAMED_PROVIDER" : "p",
  383         -
  "CREDENTIALS_PROFILE_STS_WEB_ID_TOKEN" : "q",
  384         -
  "CREDENTIALS_PROFILE_SSO" : "r",
  385         -
  "CREDENTIALS_SSO" : "s",
  386         -
  "CREDENTIALS_PROFILE_SSO_LEGACY" : "t",
  387         -
  "CREDENTIALS_SSO_LEGACY" : "u",
  388         -
  "CREDENTIALS_PROFILE_PROCESS" : "v",
  389         -
  "CREDENTIALS_PROCESS" : "w",
  390         -
  "CREDENTIALS_BOTO2_CONFIG_FILE" : "x",
  391         -
  "CREDENTIALS_AWS_SDK_STORE" : "y",
  392         -
  "CREDENTIALS_HTTP" : "z",
  393         -
  "CREDENTIALS_IMDS" : "0"
  394         -
  395         -
}
  396         -
        "#;
         345  +
        const EXPECTED: &str = include_str!("test_data/feature_id_to_metric_value.json");
  397    346   
  398    347   
        let expected: HashMap<&str, &str> = serde_json::from_str(EXPECTED).unwrap();
  399    348   
        assert_eq!(expected.len(), FEATURE_ID_TO_METRIC_VALUE.len());
  400    349   
  401    350   
        for (feature_id, metric_value) in &*FEATURE_ID_TO_METRIC_VALUE {
  402    351   
            let expected = expected.get(format!("{feature_id}").as_str());
  403    352   
            assert_eq!(
  404    353   
                expected.unwrap_or_else(|| panic!("Expected {feature_id} to have value `{metric_value}` but it was `{expected:?}` instead.")),
  405    354   
                metric_value,
  406    355   
            );

tmp-codegen-diff/aws-sdk/sdk/aws-runtime/src/user_agent/test_data/feature_id_to_metric_value.json

@@ -0,1 +0,58 @@
           1  +
{
           2  +
  "RESOURCE_MODEL": "A",
           3  +
  "WAITER": "B",
           4  +
  "PAGINATOR": "C",
           5  +
  "RETRY_MODE_LEGACY": "D",
           6  +
  "RETRY_MODE_STANDARD": "E",
           7  +
  "RETRY_MODE_ADAPTIVE": "F",
           8  +
  "S3_TRANSFER": "G",
           9  +
  "S3_CRYPTO_V1N": "H",
          10  +
  "S3_CRYPTO_V2": "I",
          11  +
  "S3_EXPRESS_BUCKET": "J",
          12  +
  "S3_ACCESS_GRANTS": "K",
          13  +
  "GZIP_REQUEST_COMPRESSION": "L",
          14  +
  "PROTOCOL_RPC_V2_CBOR": "M",
          15  +
  "ENDPOINT_OVERRIDE": "N",
          16  +
  "ACCOUNT_ID_ENDPOINT": "O",
          17  +
  "ACCOUNT_ID_MODE_PREFERRED": "P",
          18  +
  "ACCOUNT_ID_MODE_DISABLED": "Q",
          19  +
  "ACCOUNT_ID_MODE_REQUIRED": "R",
          20  +
  "SIGV4A_SIGNING": "S",
          21  +
  "RESOLVED_ACCOUNT_ID": "T",
          22  +
  "FLEXIBLE_CHECKSUMS_REQ_CRC32": "U",
          23  +
  "FLEXIBLE_CHECKSUMS_REQ_CRC32C": "V",
          24  +
  "FLEXIBLE_CHECKSUMS_REQ_CRC64": "W",
          25  +
  "FLEXIBLE_CHECKSUMS_REQ_SHA1": "X",
          26  +
  "FLEXIBLE_CHECKSUMS_REQ_SHA256": "Y",
          27  +
  "FLEXIBLE_CHECKSUMS_REQ_WHEN_SUPPORTED": "Z",
          28  +
  "FLEXIBLE_CHECKSUMS_REQ_WHEN_REQUIRED": "a",
          29  +
  "FLEXIBLE_CHECKSUMS_RES_WHEN_SUPPORTED": "b",
          30  +
  "FLEXIBLE_CHECKSUMS_RES_WHEN_REQUIRED": "c",
          31  +
  "DDB_MAPPER": "d",
          32  +
  "CREDENTIALS_CODE": "e",
          33  +
  "CREDENTIALS_JVM_SYSTEM_PROPERTIES": "f",
          34  +
  "CREDENTIALS_ENV_VARS": "g",
          35  +
  "CREDENTIALS_ENV_VARS_STS_WEB_ID_TOKEN": "h",
          36  +
  "CREDENTIALS_STS_ASSUME_ROLE": "i",
          37  +
  "CREDENTIALS_STS_ASSUME_ROLE_SAML": "j",
          38  +
  "CREDENTIALS_STS_ASSUME_ROLE_WEB_ID": "k",
          39  +
  "CREDENTIALS_STS_FEDERATION_TOKEN": "l",
          40  +
  "CREDENTIALS_STS_SESSION_TOKEN": "m",
          41  +
  "CREDENTIALS_PROFILE": "n",
          42  +
  "CREDENTIALS_PROFILE_SOURCE_PROFILE": "o",
          43  +
  "CREDENTIALS_PROFILE_NAMED_PROVIDER": "p",
          44  +
  "CREDENTIALS_PROFILE_STS_WEB_ID_TOKEN": "q",
          45  +
  "CREDENTIALS_PROFILE_SSO": "r",
          46  +
  "CREDENTIALS_SSO": "s",
          47  +
  "CREDENTIALS_PROFILE_SSO_LEGACY": "t",
          48  +
  "CREDENTIALS_SSO_LEGACY": "u",
          49  +
  "CREDENTIALS_PROFILE_PROCESS": "v",
          50  +
  "CREDENTIALS_PROCESS": "w",
          51  +
  "CREDENTIALS_BOTO2_CONFIG_FILE": "x",
          52  +
  "CREDENTIALS_AWS_SDK_STORE": "y",
          53  +
  "CREDENTIALS_HTTP": "z",
          54  +
  "CREDENTIALS_IMDS": "0",
          55  +
  "SSO_LOGIN_DEVICE": "1",
          56  +
  "SSO_LOGIN_AUTH": "2",
          57  +
  "BEARER_SERVICE_ENV_VARS": "3"
          58  +
}

tmp-codegen-diff/aws-sdk/sdk/aws-runtime/src/user_agent/test_util.rs

@@ -1,1 +70,92 @@
    5      5   
    6      6   
//! Utilities for testing the User-Agent header
    7      7   
    8      8   
use regex_lite::Regex;
    9      9   
use std::sync::LazyLock;
   10     10   
   11     11   
// regular expression pattern for base64 numeric values
   12     12   
#[allow(dead_code)]
   13     13   
static RE: LazyLock<Regex> = LazyLock::new(|| Regex::new(r"m/([A-Za-z0-9+/=_,-]+)").unwrap());
   14     14   
   15         -
/// Asserts `user_agent` contains all metric values `values`
   16         -
///
   17         -
/// Refer to the end of the parent module file `user_agent.rs` for the complete ABNF specification
   18         -
/// of `business-metrics`.
   19         -
pub fn assert_ua_contains_metric_values(user_agent: &str, values: &[&str]) {
          15  +
/// Helper function to check metric values in user agent
          16  +
fn check_ua_metric_values(user_agent: &str, values: &[&str], should_contain: bool) {
   20     17   
    match extract_ua_values(user_agent) {
   21     18   
        Some(metrics) => {
   22         -
            let mut missed = vec![];
          19  +
            let mut problematic_values = vec![];
   23     20   
   24     21   
            for value in values.iter() {
   25         -
                if !metrics.contains(value) {
   26         -
                    missed.push(value);
          22  +
                let contains = metrics.contains(value);
          23  +
                if (should_contain && !contains) || (!should_contain && contains) {
          24  +
                    problematic_values.push(value);
          25  +
                }
          26  +
            }
          27  +
          28  +
            if !problematic_values.is_empty() {
          29  +
                if should_contain {
          30  +
                    panic!("metric values {problematic_values:?} not found in `{user_agent}`");
          31  +
                } else {
          32  +
                    panic!(
          33  +
                        "metric values {problematic_values:?} unexpectedly found in `{user_agent}`"
          34  +
                    );
   27     35   
                }
   28     36   
            }
   29         -
            assert!(
   30         -
                missed.is_empty(),
   31         -
                "{}",
   32         -
                format!("metric values {missed:?} not found in `{user_agent}`")
   33         -
            );
   34     37   
        }
   35     38   
        None => {
   36         -
            panic!("{}", format!("the pattern for business-metrics `m/(metric_id) *(comma metric_id)` not found in `{user_agent}`"))
          39  +
            if should_contain {
          40  +
                panic!("the pattern for business-metrics `m/(metric_id) *(comma metric_id)` not found in `{user_agent}`");
          41  +
            }
          42  +
            // For "does not contain", no metrics pattern means the assertion passes
   37     43   
        }
   38     44   
    }
   39     45   
}
   40     46   
          47  +
/// Asserts `user_agent` contains all metric values `values`
          48  +
///
          49  +
/// Refer to the end of the parent module file `user_agent.rs` for the complete ABNF specification
          50  +
/// of `business-metrics`.
          51  +
pub fn assert_ua_contains_metric_values(user_agent: &str, values: &[&str]) {
          52  +
    check_ua_metric_values(user_agent, values, true);
          53  +
}
          54  +
          55  +
/// Asserts `user_agent` does NOT contain any of the metric values `values`
          56  +
///
          57  +
/// Refer to the end of the parent module file `user_agent.rs` for the complete ABNF specification
          58  +
/// of `business-metrics`.
          59  +
pub fn assert_ua_does_not_contain_metric_values(user_agent: &str, values: &[&str]) {
          60  +
    check_ua_metric_values(user_agent, values, false);
          61  +
}
          62  +
   41     63   
/// Extract the metric values from the `user_agent` string
   42     64   
pub fn extract_ua_values(user_agent: &str) -> Option<Vec<&str>> {
   43     65   
    RE.find(user_agent).map(|matched| {
   44     66   
        matched
   45     67   
            .as_str()
   46     68   
            .strip_prefix("m/")
   47     69   
            .expect("prefix `m/` is guaranteed to exist by regex match")
   48     70   
            .split(',')
   49     71   
            .collect()
   50     72   
    })

tmp-codegen-diff/aws-sdk/sdk/aws-sigv4/Cargo.toml

@@ -31,31 +91,91 @@
   51     51   
optional = true
   52     52   
version = "0.60.10"
   53     53   
   54     54   
[dependencies.aws-smithy-http]
   55     55   
path = "../aws-smithy-http"
   56     56   
version = "0.62.3"
   57     57   
   58     58   
[dependencies.aws-smithy-runtime-api]
   59     59   
path = "../aws-smithy-runtime-api"
   60     60   
features = ["client"]
   61         -
version = "1.8.6"
          61  +
version = "1.8.7"
   62     62   
   63     63   
[dependencies.aws-smithy-types]
   64     64   
path = "../aws-smithy-types"
   65     65   
version = "1.3.2"
   66     66   
   67     67   
[dependencies.form_urlencoded]
   68     68   
version = "1.2.1"
   69     69   
optional = true
   70     70   
   71     71   
[dependencies.http0]
@@ -94,94 +130,130 @@
  114    114   
criterion = "0.5"
  115    115   
  116    116   
[dev-dependencies.aws-credential-types]
  117    117   
path = "../aws-credential-types"
  118    118   
features = ["test-util", "hardcoded-credentials"]
  119    119   
version = "1.2.5"
  120    120   
  121    121   
[dev-dependencies.aws-smithy-runtime-api]
  122    122   
path = "../aws-smithy-runtime-api"
  123    123   
features = ["client", "test-util"]
  124         -
version = "1.8.6"
         124  +
version = "1.8.7"
  125    125   
  126    126   
[dev-dependencies.time]
  127    127   
version = "0.3.5"
  128    128   
features = ["parsing"]
  129    129   
[target."cfg(not(any(target_arch = \"powerpc\", target_arch = \"powerpc64\")))".dev-dependencies]
  130    130   
ring = "0.17.5"

tmp-codegen-diff/aws-sdk/sdk/aws-smithy-compression/Cargo.toml

@@ -3,3 +63,63 @@
   23     23   
futures-util = "0.3"
   24     24   
pin-project-lite = "0.2.14"
   25     25   
tracing = "0.1.40"
   26     26   
   27     27   
[dependencies.aws-smithy-types]
   28     28   
path = "../aws-smithy-types"
   29     29   
version = "1.3.2"
   30     30   
   31     31   
[dependencies.aws-smithy-runtime-api]
   32     32   
path = "../aws-smithy-runtime-api"
   33         -
version = "1.8.6"
          33  +
version = "1.8.7"
   34     34   
   35     35   
[dependencies.http-0-2]
   36     36   
package = "http"
   37     37   
version = "0.2.9"
   38     38   
optional = true
   39     39   
   40     40   
[dependencies.http-1-0]
   41     41   
package = "http"
   42     42   
version = "1"
   43     43   
optional = true

tmp-codegen-diff/aws-sdk/sdk/aws-smithy-http-client/Cargo.toml

@@ -32,32 +92,92 @@
   52     52   
pin-project-lite = "0.2.14"
   53     53   
tracing = "0.1.40"
   54     54   
   55     55   
[dependencies.aws-smithy-async]
   56     56   
path = "../aws-smithy-async"
   57     57   
version = "1.2.5"
   58     58   
   59     59   
[dependencies.aws-smithy-runtime-api]
   60     60   
path = "../aws-smithy-runtime-api"
   61     61   
features = ["client"]
   62         -
version = "1.8.6"
          62  +
version = "1.8.7"
   63     63   
   64     64   
[dependencies.aws-smithy-types]
   65     65   
path = "../aws-smithy-types"
   66     66   
version = "1.3.2"
   67     67   
   68     68   
[dependencies.aws-smithy-protocol-test]
   69     69   
path = "../aws-smithy-protocol-test"
   70     70   
optional = true
   71     71   
version = "0.63.4"
   72     72   
@@ -171,171 +221,221 @@
  191    191   
tokio-rustls = "0.26.1"
  192    192   
  193    193   
[dev-dependencies.aws-smithy-async]
  194    194   
path = "../aws-smithy-async"
  195    195   
features = ["rt-tokio", "test-util"]
  196    196   
version = "1.2.5"
  197    197   
  198    198   
[dev-dependencies.aws-smithy-runtime-api]
  199    199   
path = "../aws-smithy-runtime-api"
  200    200   
features = ["test-util"]
  201         -
version = "1.8.6"
         201  +
version = "1.8.7"
  202    202   
  203    203   
[dev-dependencies.aws-smithy-types]
  204    204   
path = "../aws-smithy-types"
  205    205   
features = ["http-body-0-4-x", "test-util"]
  206    206   
version = "1.3.2"
  207    207   
  208    208   
[dev-dependencies.http-body-util]
  209    209   
version = "0.1.2"
  210    210   
  211    211   
[dev-dependencies.hyper-util]

tmp-codegen-diff/aws-sdk/sdk/aws-smithy-http/Cargo.toml

@@ -7,7 +67,67 @@
   27     27   
futures-core = "0.3.31"
   28     28   
   29     29   
[dependencies.aws-smithy-eventstream]
   30     30   
path = "../aws-smithy-eventstream"
   31     31   
optional = true
   32     32   
version = "0.60.10"
   33     33   
   34     34   
[dependencies.aws-smithy-runtime-api]
   35     35   
path = "../aws-smithy-runtime-api"
   36     36   
features = ["client", "http-02x"]
   37         -
version = "1.8.6"
          37  +
version = "1.8.7"
   38     38   
   39     39   
[dependencies.aws-smithy-types]
   40     40   
path = "../aws-smithy-types"
   41     41   
features = ["byte-stream-poll-next", "http-body-0-4-x"]
   42     42   
version = "1.3.2"
   43     43   
   44     44   
[dependencies.http-02x]
   45     45   
package = "http"
   46     46   
version = "0.2.9"
   47     47   

tmp-codegen-diff/aws-sdk/sdk/aws-smithy-mocks-experimental/Cargo.toml

@@ -1,1 +29,29 @@
   16     16   
targets = ["x86_64-unknown-linux-gnu"]
   17     17   
cargo-args = ["-Zunstable-options", "-Zrustdoc-scrape-examples"]
   18     18   
rustdoc-args = ["--cfg", "docsrs"]
   19     19   
[dependencies.aws-smithy-types]
   20     20   
path = "../aws-smithy-types"
   21     21   
version = "1.3.2"
   22     22   
   23     23   
[dependencies.aws-smithy-runtime-api]
   24     24   
path = "../aws-smithy-runtime-api"
   25     25   
features = ["client", "http-02x"]
   26         -
version = "1.8.6"
          26  +
version = "1.8.7"
   27     27   
[dev-dependencies.tokio]
   28     28   
version = "1"
   29     29   
features = ["full"]

tmp-codegen-diff/aws-sdk/sdk/aws-smithy-mocks/Cargo.toml

@@ -1,1 +44,44 @@
   16     16   
[dependencies]
   17     17   
http = "1"
   18     18   
   19     19   
[dependencies.aws-smithy-types]
   20     20   
path = "../aws-smithy-types"
   21     21   
version = "1.3.2"
   22     22   
   23     23   
[dependencies.aws-smithy-runtime-api]
   24     24   
path = "../aws-smithy-runtime-api"
   25     25   
features = ["client", "http-1x"]
   26         -
version = "1.8.6"
          26  +
version = "1.8.7"
   27     27   
   28     28   
[dependencies.aws-smithy-http-client]
   29     29   
path = "../aws-smithy-http-client"
   30     30   
features = ["test-util"]
   31     31   
version = "1.0.6"
   32     32   
[dev-dependencies.tokio]
   33     33   
version = "1"
   34     34   
features = ["full"]
   35     35   
   36     36   
[dev-dependencies.aws-smithy-async]