Skip to content
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

feat: add OkHttp transport module #155

Merged
merged 26 commits into from
Jan 16, 2025
Merged

Conversation

Mohammad-Dwairi
Copy link
Contributor

Situation

One of the features of the new core module is its flexibility in supporting diverse HTTP clients by allowing end-users or product SDKs to inject their preferred implementations. This is achieved by implementing the Transport interface for synchronous requests or the AsyncTransport interface for asynchronous requests.

To achieve full decoupling between the core module and any specific HTTP client library; we will publish packages that integrates different HTTP clients (e.g., OkHttp, Apache HTTP) with the SDK's Transport interfaces. SDK users simply need to include dependencies on both the product SDK and one of the supported HTTP client packages.

In this PR, we are introducing a new module expediagroup-sdk-okhttp-transport that offers a ready-to-use Transport implementation using OkHttp.

Caution

Changes in this PR are already on the main branch and has been reviewed earlier. This PR extracts all OkHttp-related files to a new module.

Task

Move all OkHttp related files to a separate module.

Action

  1. Initialized a new module expediagroup-sdk-okhttp-transport
  2. Copied the classes and files from okhttp package to the new module.

Testing

  1. All tests are passing.

@Mohammad-Dwairi Mohammad-Dwairi requested a review from a team as a code owner January 13, 2025 09:54
Base automatically changed from mdwairi/establish-core-module to main January 15, 2025 17:29
@Mohammad-Dwairi Mohammad-Dwairi merged commit 8a7fa7e into main Jan 16, 2025
2 checks passed
@Mohammad-Dwairi Mohammad-Dwairi deleted the mdwairi/okhttp-module branch January 16, 2025 15:27
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