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

Expose fetchMetadataToken to AWS.MetadataService #4240

Merged
merged 1 commit into from
May 22, 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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changes/next-release/feature-MetadataService-3a550e8f.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"type": "feature",
"category": "MetadataService",
"description": "Update AWS.MetadataService to expose the fetchMetadataToken function."
}
4 changes: 4 additions & 0 deletions lib/metadata_service.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ export class MetadataService {
options: {method?: string, headers?: {[key: string]: String} },
callback: (err: AWSError, data: string) => void
): void;
/**
* Fetches metadata token used for authenticating against the instance metadata service.
*/
fetchMetadataToken(callback: (err: AWSError, token: string) => void): void;
/**
* 169.254.169.254
*/
Expand Down
3 changes: 1 addition & 2 deletions lib/metadata_service.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,8 @@ AWS.MetadataService = inherit({
loadCredentialsCallbacks: [],

/**
* Fetches metadata token used for getting credentials
* Fetches metadata token used for authenticating against the instance metadata service.
*
* @api private
* @callback callback function(err, token)
* Called when token is loaded from the resource
*/
Expand Down