Skip to content

Conversation

@L-Applin
Copy link
Contributor

@L-Applin L-Applin commented Jan 30, 2023

Release IMDS feature to master branch

Closes Issue 61

srsaikumarreddy and others added 18 commits June 21, 2022 15:38
* Created the Configuration class for Ec2Metadata

* Added CR comments in EndpointMode.java

Co-authored-by: Sai Chandupatla <[email protected]>
* Implemented Happy Path client functionality along with Request Marshaller Class

* Changed expected Exception message in Test Case

* Incorporated PR feedback

* Fixed SonarCloud Issues

Co-authored-by: Sai Chandupatla <[email protected]>
* Implemented Response Handling and Parsing Methods for output

* Added Javadoc info

* Implemented PR comments

* Changed dependency scope

Co-authored-by: Sai Chandupatla <[email protected]>
* Implemented Retries functionality

* Incorporated Code Review comments

* Implemented PR Changes-2

* Adding CR review files

* Implemented CR comments -4

* nit comment fixed

Co-authored-by: Sai Chandupatla <[email protected]>
* Placed EndpointMode.java outside internal folder. Increased Test Coverage

* Removed aws-json-protocol dependency

* Added test cases for DocumentUnMarshaller

Co-authored-by: Sai Chandupatla <[email protected]>
* Added Apache Client tests

* Removed extra space in imds pom file

* Removed duplicated cases as per PR comments

* Removed duplicated cases as per PR comments

Co-authored-by: Sai Chandupatla <[email protected]>
* IMDS Ec2 Metada refactoring

* IMDS Ec2 Metada refactoring

* IMDS Ec2 Metada refactoring

* IMDS Ec2 Metada refactoring

* IMDS Ec2 Metada refactoring

* IMDS Ec2 Metada refactoring

* IMDS Ec2 Metada refactoring

* fix checkstyle error

* Increase IMDS test code coverage
* IMDS Async client

* Fix test classes

* JavaDoc

* PR comments and added IMDS to test-coverage-reporting
- Create a common builder Ec2MetadataClientBuilder
- Create a common test class BaseEc2MetadataClientTest
- Refactor common initialization logic for both sync and async client in BaseEc2MetadataClient class
- Use netty async client in unit tests
- fix Async error logic

* Improve JavaDoc and rename some variables
- fix one failing unit test
* IMDS Async

* IMDS Async client

* Token caching in sync and async client and sync client unit test

* Async token caching with retry

* Temporarily remove AsyncClient token cache implementation
- Pr comments

* internal Api for token cache strategies
Async token cache implementation
* Surface area review
- removed getters on client builder public interface
- rename MetadataResponse to Ec2MetadataResponse
- add builder-consumer for retry policy
- add DefaultSdkAsyncHttpClientBuilder and DefaultSdkHttpClientBuilder to client builders
- remove duplication in BaseEc2MetadataClient constructors
- TokenResponseHandler cleanup
- Updated ttl header logic if not found in response headers
- use SdkHttpClient.Builder in IMDS Client Builder interface
- Javadoc
- Async Http Request Handlers refactor
- add test for mutual exclusion of http client and http client builder in IMDS client builders
- dont retry on bad response format from server
* feature changelog
@L-Applin L-Applin requested a review from a team as a code owner January 30, 2023 13:40
@L-Applin L-Applin requested a review from dave-fn January 30, 2023 18:57
Comment on lines +76 to +81
public String toString() {
return "Ec2MetadataRetryPolicy{" +
"backoffStrategy=" + backoffStrategy.toString() +
", numRetries=" + numRetries +
'}';
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Not a problem, can leave as is, but wanted to point out the ToString utils method.

@L-Applin L-Applin enabled auto-merge (squash) January 31, 2023 20:10
@L-Applin L-Applin merged commit a8848f1 into master Feb 1, 2023
@sonarqubecloud
Copy link

sonarqubecloud bot commented Feb 1, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 8 Code Smells

83.0% 83.0% Coverage
2.0% 2.0% Duplication

@L-Applin L-Applin linked an issue Feb 3, 2023 that may be closed by this pull request
@L-Applin L-Applin mentioned this pull request Feb 3, 2023
12 tasks
@L-Applin L-Applin deleted the olapplin/imds-merge-master branch August 15, 2025 18:18
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.

EC2 Metadata Client

3 participants