Thanks to visit codestin.com
Credit goes to github.com

Skip to content

GH-2931 Allow passing a custom HTTP client into the HttpAdminClient constructor #2941

Open
viktorijabb wants to merge 7 commits intowiremock:masterfrom
viktorijabb:enhancement-2931
Open

GH-2931 Allow passing a custom HTTP client into the HttpAdminClient constructor #2941
viktorijabb wants to merge 7 commits intowiremock:masterfrom
viktorijabb:enhancement-2931

Conversation

@viktorijabb
Copy link

@viktorijabb viktorijabb commented Jan 21, 2025

References

Fixes GH-2931

Submitter checklist

  • Recommended: Join WireMock Slack to get any help in #help-contributing or a project-specific channel like #wiremock-java
  • The PR request is well described and justified, including the body and the references
  • The PR title represents the desired changelog entry
  • The repository's code style is followed (see the contributing guide)
  • Test coverage that demonstrates that the change works as expected
  • For new features, there's necessary documentation in this pull request or in a subsequent PR to wiremock.org

@viktorijabb viktorijabb requested a review from a team as a code owner January 21, 2025 11:39
@leeturner
Copy link
Contributor

Many thanks for this PR. In the issue we talked about using the WireMock HttpClient interface as the new parameter to the constructor instead of the CloseableHttpClient to help stop the Apache classes leak into our own. Is that something you would be up for implementing. It will require a little rework of the HttpAdminClient but it would be a nice addition to this PR if you are up for it?

@viktorijabb
Copy link
Author

Yep, Im happy to pick that up!

@tomakehurst
Copy link
Member

This is the right way to start, but it doesn't compile at the moment as the code that calls the HTTP client also needs to be updated.

I suggest running ./gradlew spotlessApply check before pushing new commits.

@viktorijabb
Copy link
Author

Hi @leeturner @tomakehurst , this needs some attention, when possible.

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.

Allow passing a custom HTTP client into the HttpAdminClient constructor

3 participants