Skip to content

Add apache HTTP request stats #1863

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
merged 1 commit into from
May 28, 2020

Conversation

dagnir
Copy link
Contributor

@dagnir dagnir commented May 27, 2020

Description

Motivation and Context

Testing

Screenshots (if appropriate)

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

@dagnir dagnir requested a review from zoewangg May 27, 2020 21:07
Copy link
Contributor

@zoewangg zoewangg left a comment

Choose a reason for hiding this comment

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

Can we add some functional tests using the fake protocol test clients?

/**
* The maximum number of connections that will be pooled by the HTTP client.
*/
public static final SdkMetric<Integer> MAX_CONNECTIONS = metric("MaxConnections", Integer.class);
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we need to namespace all sdk metrics?

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 think the issue with that is if you want to "pretty print" the metrics, or write your own publisher, there's no easy way to just get the metric name

/**
* The maximum number of connections that will be pooled by the HTTP client.
*/
public static final SdkMetric<Integer> MAX_CONNECTIONS = metric("MaxConnections", Integer.class);
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we want to differentiate h2 max connection from it? Is it worth creating a new class for all h2 http metrics such as window size, max streams, etc?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah I think we should create additional metrics for H2 specific things; perhaps per-connection metrics?

@dagnir
Copy link
Contributor Author

dagnir commented May 27, 2020

Can we add some functional tests using the fake protocol test clients

Can't do this yet unfortunately until all the other things are hooked up in the request pipeline and codegen so that an SDK client actually creates a collector and passes it to the HTTP client

@dagnir dagnir merged commit 299ed84 into aws:sdk-metrics-development-2 May 28, 2020
@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.

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

58.8% 58.8% Coverage
0.0% 0.0% Duplication

warning The version of Java (1.8.0_252) you have used to run this analysis is deprecated and we will stop accepting it from October 2020. Please update to at least Java 11.
Read more here

aws-sdk-java-automation pushed a commit that referenced this pull request Dec 3, 2021
Revert "[JUnit 5] Migrate some parameterized tests to JUnit 5 (#2880)"
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.

2 participants