Skip to content

Integrating AWS CRT 0.5.1 into aws-crt-dev-preview #1769

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

Merged

Conversation

rccarper
Copy link
Contributor

@rccarper rccarper commented Apr 6, 2020

Description

  • This points the SDK to the latest build of the Java CRT available in Maven, ie, 0.5.1, and includes any changes necessary to make that work.
  • Branch includes changes from crt-api-update (Updated crt http client to use latest crt api, which uses byte[] for … #1498)
  • Branch includes change from crt_v0.5.1 (alexw91@025c43c)
  • I'm currently relying on the existing unit tests invoked by mvn clean install, and would be open to any other means of validating these changes if someone knows better.

Testing

mvn clean install

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • I have read the CONTRIBUTING document
  • Local run of mvn install succeeds
  • My code follows the code style of this project
  • My change requires a change to the Javadoc documentation
  • I have updated the Javadoc documentation accordingly
  • I have read the README document
  • I have added tests to cover my changes
  • All new and existing tests passed
  • A short description of the change has been added to the CHANGELOG
  • My change is to implement 1.11 parity feature and I have updated LaunchChangelog

License

  • I confirm that this pull request can be released under the Apache 2 license

@@ -43,9 +47,13 @@ public void setup() {
continue;
}

int numThreads = 1;
eventLoopGroup = new EventLoopGroup(numThreads);
Copy link
Contributor

Choose a reason for hiding this comment

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

I"m not sure what the purposes of these changes is. Care to enlighten me?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The client doesn't create its own event loop group anymore, as people felt it was a bit awkward for them to create such a heavy object. Because of that, we don't have the .eventLoopSize(1) builder change that we used to have on the client, and this is meant to be the replacement of that. (The numThreads variable is just meant to be more explicit about what's being passed in, and could arguably be taken out or made final.)

.withMaxConnections(maxConnectionsPerEndpoint)
.withManualWindowManagement(manualWindowManagement);

return HttpClientConnectionManager.create(options);
Copy link
Contributor

Choose a reason for hiding this comment

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

create is a wierd verb for a builder pattern

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Wouldn't that be a change we would have to make on the CRT side?

*/
Builder verifyPeer(boolean verifyPeer);

/**
* If set to true, then the TCP read back pressure mechanism will be enabled.
Copy link
Contributor

Choose a reason for hiding this comment

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

make sure to call out if this is ever set to true the user is responsible for calling updateWindow on the stream object.

Copy link
Contributor

Choose a reason for hiding this comment

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

sorry, incrementWindow()

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll update the comment!

@sonarqubecloud
Copy link

sonarqubecloud bot commented Apr 7, 2020

SonarCloud Quality Gate failed.

Bug C 1 Bug
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 17 Code Smells

80.7% 80.7% Coverage
3.4% 3.4% Duplication

@millems millems merged commit 6e66a7c into aws:aws-crt-dev-preview Apr 7, 2020
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.

4 participants