Skip to content

Update Apache to not reuse connections if they received a 5xx error. #2960

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
Jan 12, 2022

Conversation

millems
Copy link
Contributor

@millems millems commented Jan 11, 2022

This was already the behavior for Netty, and cannot be made the behavior for the URL connection client.

@millems millems requested a review from a team as a code owner January 11, 2022 21:55
@@ -144,6 +144,30 @@ public void connectionPoolingWorks() throws Exception {
assertThat(CONNECTION_COUNTER.openedConnections()).isEqualTo(initialOpenedConnections + 1);
}

@Test
public void connectionsAreNotReusedOn5xxErrors() throws Exception {
Copy link
Contributor

Choose a reason for hiding this comment

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

Nice!

This was already the behavior for Netty, and cannot be made the behavior for the URL connection client.
@millems millems force-pushed the millem/kill-5xx-connections branch from 50b0e97 to a80e2fe Compare January 12, 2022 20:01
@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.    Quality Gate failed

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

86.1% 86.1% Coverage
26.4% 26.4% Duplication

@millems millems enabled auto-merge (squash) January 12, 2022 21:29
@millems millems merged commit b673b84 into master Jan 12, 2022
@millems millems deleted the millem/kill-5xx-connections branch January 12, 2022 22:19
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.

3 participants