Skip to content
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

fix(docs: client construction): wrong type name #3633

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

problame
Copy link

@problame problame commented May 8, 2024

Motivation and Context

Docs are wrong.

Description

The docs are referring to the wrong type name (Config).
The example right below the change uses the right type name ($crateName::config::Builder).

Testing

n/a

Checklist


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@problame problame requested a review from a team as a code owner May 8, 2024 17:31
problame added a commit to neondatabase/neon that referenced this pull request May 9, 2024
…(updates AWS SDKs) (#7664)

Before this PR, using the AWS SDK profile feature for running against
minio didn't work because
* our SDK versions were too old and didn't include
  awslabs/aws-sdk-rust#1060 and 
* we didn't massage the s3 client config builder correctly.

This PR
* udpates all the AWS SDKs we use to, respectively, the latest version I
could find on crates.io (Is there a better process?)
* changes the way remote_storage constructs the S3 client, and
* documents how to run the test suite against real S3 & local minio.

Regarding the changes to `remote_storage`: if one reads the SDK docs, it
is clear that the recommended way is to use `aws_config::from_env`, then
customize.
What we were doing instead is to use the `aws_sdk_s3` builder directly.

To get the `local-minio` in the added docs working, I needed to update
both the SDKs and make the changes to the `remote_storage`. See the
commit history in this PR for details.

Refs:
* byproduct: smithy-lang/smithy-rs#3633
* follow-up on deprecation:
#7665
* follow-up for scrubber S3 setup:
#7667
@aajtodd
Copy link
Contributor

aajtodd commented May 9, 2024

Thanks for the PR!

The service client Config structs do implement From<&SdkConfig> (as does the builder). I believe this is correct and as intended.

@problame
Copy link
Author

problame commented May 9, 2024

Yeah, both implement the From.

But the context and subsequent example make it quite clear that Builder should be used in the text.

Anyway, if you don't think this is helpful please close the PR, this was a drive-by contribution from my side.

@aajtodd
Copy link
Contributor

aajtodd commented May 9, 2024

Ahh no I agree that makes more sense. Thanks for clarification.

a-masterov pushed a commit to neondatabase/neon that referenced this pull request May 20, 2024
…(updates AWS SDKs) (#7664)

Before this PR, using the AWS SDK profile feature for running against
minio didn't work because
* our SDK versions were too old and didn't include
  awslabs/aws-sdk-rust#1060 and 
* we didn't massage the s3 client config builder correctly.

This PR
* udpates all the AWS SDKs we use to, respectively, the latest version I
could find on crates.io (Is there a better process?)
* changes the way remote_storage constructs the S3 client, and
* documents how to run the test suite against real S3 & local minio.

Regarding the changes to `remote_storage`: if one reads the SDK docs, it
is clear that the recommended way is to use `aws_config::from_env`, then
customize.
What we were doing instead is to use the `aws_sdk_s3` builder directly.

To get the `local-minio` in the added docs working, I needed to update
both the SDKs and make the changes to the `remote_storage`. See the
commit history in this PR for details.

Refs:
* byproduct: smithy-lang/smithy-rs#3633
* follow-up on deprecation:
#7665
* follow-up for scrubber S3 setup:
#7667
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants