Skip to content

[WIP] Introduce HTTP interface#43

Open
dorin-ga wants to merge 26 commits intomainfrom
http_interface
Open

[WIP] Introduce HTTP interface#43
dorin-ga wants to merge 26 commits intomainfrom
http_interface

Conversation

@dorin-ga
Copy link
Copy Markdown
Collaborator

@dorin-ga dorin-ga commented Apr 1, 2026

Separate HTTP implementation in order to more easily manage dependencies and support other libraries/platforms (e.g: consoles). The default HTTP implementation remains CURL.

  • create abstract HTTP interface
  • have HTTP API be agnostic of http implementation
  • create the default CURL interface
  • allow registering a custom interface
  • better dependency management
  • write tests

@dorin-ga dorin-ga requested a review from Gogoshika-ga April 1, 2026 11:48
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 1, 2026

LCOV of commit a3dc128 during Test Coverage #116

Summary coverage rate:
  lines......: 50.3% (1423 of 2829 lines)
  functions..: 61.2% (243 of 397 functions)
  branches...: no data found

Files changed coverage rate: n/a

curl_global_cleanup();
}

GAHttpWrapper::Response GAHttpCurl::sendRequest(std::string const& url, std::string const& auth, std::vector<uint8_t> const& payloadData, bool useGzip, void* userData)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

What is userData? do we need this?

logging::GALogger::d(curl_easy_strerror(res));
return NoResponse;
logging::GALogger::e("Request failed: %s", url.c_str());
return EGAHTTPApiResponse::SdkError;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Should this still return NoResponse? new implementation returns SDKError.

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