mirror of https://github.com/smithy-lang/smithy-rs
Add to functions in `aws-config` a link to documentation on default configs (#3694)
## Motivation and Context aws-sdk-rust#1162 ## Testing Tests in CI ## Checklist - [x] I have updated `CHANGELOG.next.toml` if I made changes to the AWS SDK, generated SDK code, or SDK runtime crates ---- _By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice._
This commit is contained in:
parent
3ad943a1cb
commit
98a0a5ec27
|
@ -10,3 +10,9 @@
|
|||
# references = ["smithy-rs#920"]
|
||||
# meta = { "breaking" = false, "tada" = false, "bug" = false, "target" = "client | server | all"}
|
||||
# author = "rcoh"
|
||||
|
||||
[[aws-sdk-rust]]
|
||||
message = "Add documentation on the default configuration to `from_env`, `load_from_env`, `defaults`, and `load_from_defaults` in the `aws-config` crate."
|
||||
references = ["aws-sdk-rust#1162"]
|
||||
meta = { "breaking" = false, "tada" = false, "bug" = false }
|
||||
author = "ysaito1001"
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
[package]
|
||||
name = "aws-config"
|
||||
version = "1.5.1"
|
||||
version = "1.5.2"
|
||||
authors = [
|
||||
"AWS Rust SDK Team <aws-sdk-rust@amazon.com>",
|
||||
"Russell Cohen <rcoh@amazon.com>",
|
||||
|
|
|
@ -145,6 +145,8 @@ pub mod web_identity_token;
|
|||
///
|
||||
/// This loader will always set [`BehaviorVersion::latest`].
|
||||
///
|
||||
/// For more information about default configuration, refer to the AWS SDKs and Tools [shared configuration documentation](https://docs.aws.amazon.com/sdkref/latest/guide/creds-config-files.html).
|
||||
///
|
||||
/// # Examples
|
||||
/// ```no_run
|
||||
/// # async fn create_config() {
|
||||
|
@ -159,6 +161,8 @@ pub fn from_env() -> ConfigLoader {
|
|||
/// Load default configuration with the _latest_ defaults.
|
||||
///
|
||||
/// Convenience wrapper equivalent to `aws_config::load_defaults(BehaviorVersion::latest()).await`
|
||||
///
|
||||
/// For more information about default configuration, refer to the AWS SDKs and Tools [shared configuration documentation](https://docs.aws.amazon.com/sdkref/latest/guide/creds-config-files.html).
|
||||
#[cfg(feature = "behavior-version-latest")]
|
||||
pub async fn load_from_env() -> SdkConfig {
|
||||
from_env().load().await
|
||||
|
@ -184,6 +188,8 @@ pub async fn load_from_env() -> SdkConfig {
|
|||
|
||||
/// Create a config loader with the defaults for the given behavior version.
|
||||
///
|
||||
/// For more information about default configuration, refer to the AWS SDKs and Tools [shared configuration documentation](https://docs.aws.amazon.com/sdkref/latest/guide/creds-config-files.html).
|
||||
///
|
||||
/// # Examples
|
||||
/// ```no_run
|
||||
/// # async fn create_config() {
|
||||
|
@ -201,6 +207,8 @@ pub fn defaults(version: BehaviorVersion) -> ConfigLoader {
|
|||
/// Load default configuration with the given behavior version.
|
||||
///
|
||||
/// Convenience wrapper equivalent to `aws_config::defaults(behavior_version).load().await`
|
||||
///
|
||||
/// For more information about default configuration, refer to the AWS SDKs and Tools [shared configuration documentation](https://docs.aws.amazon.com/sdkref/latest/guide/creds-config-files.html).
|
||||
pub async fn load_defaults(version: BehaviorVersion) -> SdkConfig {
|
||||
defaults(version).load().await
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue