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

chore: Remove not used cache in InstanceCredentialProvider #5888

Merged
merged 1 commit into from
Jun 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion object_store/src/aws/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -898,7 +898,6 @@ impl AmazonS3Builder {
info!("Using Instance credential provider");

let token = InstanceCredentialProvider {
cache: Default::default(),
imdsv1_fallback: self.imdsv1_fallback.get()?,
metadata_endpoint: self
.metadata_endpoint
Expand Down
3 changes: 0 additions & 3 deletions object_store/src/aws/credential.rs
Original file line number Diff line number Diff line change
Expand Up @@ -424,9 +424,6 @@ fn canonicalize_headers(header_map: &HeaderMap) -> (String, String) {
/// <https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/configuring-instance-metadata-service.html>
#[derive(Debug)]
pub struct InstanceCredentialProvider {
// https://github.com/apache/arrow-rs/issues/5884
#[allow(dead_code)]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 sine this is a pub field, this might qualify as a breaking change -- in which case we may need to hold the PR until main is open for breaking changes again. I plan to file a ticket to discuss the plan in the next day or two (I keep meaing to do it but I haven't found the time yet)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This struct is crate private so this is not a breaking change

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gah! it would be nice if we followed the pattern to mark all such structs pub(crate) so it is clearer from the definition

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably a good first issue, FWIW very little is actually public

pub cache: TokenCache<Arc<AwsCredential>>,
pub imdsv1_fallback: bool,
pub metadata_endpoint: String,
}
Expand Down
Loading