Package io.karatelabs.http
Interface HttpClientFactory
- All Known Implementing Classes:
DefaultHttpClientFactory
public interface HttpClientFactory
Factory for creating HttpClient instances.
This interface allows external modules (such as karate-gatling) to provide custom HttpClient implementations, for example with a shared connection pool for performance testing scenarios.
The default implementation DefaultHttpClientFactory creates a new
ApacheHttpClient instance for each call, which is the standard
behavior for functional tests where isolation is preferred.
- See Also:
-
Method Summary
-
Method Details
-
create
HttpClient create()Creates a new HttpClient instance.- Returns:
- a new HttpClient instance
-