Skip to content

Conversation

kinyoklion
Copy link
Member

@kinyoklion kinyoklion commented Oct 13, 2025

BEGIN_COMMIT_OVERRIDE
feat: Add support for CURL networking.
feat: Add proxy support when using CURL networking.
END_COMMIT_OVERRIDE

This PR adds an alternate networking implementation which uses CURL instead of boost beast. Using CURL enables support for all advanced networking features including support for http, https, socks4, and socks 5 proxies.

Proxy configuration can be done using standard environment variables, or using the builder for the SDK.

CURL is used via the CURL multi interface combined with boost::asio to provide non-blocking IO. https://curl.se/libcurl/c/libcurl-multi.html

This allows for the CURL requests to be driven similarly to the boost.beast networking which is additionally supported.

CURL support is conditional based on the LD_CURL_NETWORKING CMake option. When it is enabled all HTTP/HTTPS request in the SDK use CURL. This support does not affect the redis persistence implementation.

The CI and release process has been updated to build and test the CURL and boost.Beast versions of all of the libraries. These changes constitute a non-trivial portion of the PR.


Note

Introduce optional CURL-based networking (LD_CURL_NETWORKING) with proxy support, new networking lib, SSE/cHTTP integrations, tests, docs, and CI/release pipelines building both CURL and Boost.Beast variants.

  • Networking (Core):
    • Add LD_CURL_NETWORKING option and new libs/networking with CurlMultiManager and CURL requester.
    • Introduce network::Requester abstraction; wire into client polling, event delivery, and SSE.
    • Add CURL-based SSE client; retain existing Boost.Beast path.
    • Add proxy support via HttpProperties (ProxyOptions) and C/C++ builders (client/server), incl. SSE builder.
  • Build/Config:
    • New code coverage option LD_BUILD_COVERAGE.
    • Update CMake defaults and launchdarklyConfig.cmake to find CURL when needed.
    • Scripts support --with-curl; produce separate *-curl build dirs/artifacts.
  • CI/Release:
    • New install-curl composite action; CI inputs use_curl.
    • Expand workflows to build/test both CURL and Boost.Beast across Linux/macOS/Windows (incl. contract tests and cmake integration).
    • Release action zips/upload curl and non-curl artifacts (with server experimental suffix handling).
    • Add libs/networking to release-please.
  • Tests/Examples/Docs:
    • Add unit tests for CURL requester and SSE Curl client; cmake-tests support extra args for CURL.
    • Add proxy validation Docker example and usage docs; README updates for CURL requirements and usage.

Written by Cursor Bugbot for commit 75c79b8. This will update automatically on new commits. Configure here.

@kinyoklion
Copy link
Member Author

bugbot review

cursor[bot]

This comment was marked as outdated.

@kinyoklion kinyoklion force-pushed the rlamb/basic-network-request-abstraction branch from 64ff5eb to 417b1de Compare October 18, 2025 20:57
@kinyoklion
Copy link
Member Author

bugbot review

cursor[bot]

This comment was marked as outdated.

@kinyoklion
Copy link
Member Author

bugbot review

cursor[bot]

This comment was marked as outdated.

@kinyoklion kinyoklion force-pushed the rlamb/basic-network-request-abstraction branch from 0564360 to 3782ee9 Compare October 18, 2025 21:31
@kinyoklion kinyoklion marked this pull request as ready for review October 19, 2025 01:09
@kinyoklion kinyoklion requested a review from a team as a code owner October 19, 2025 01:09
BOOST_ROOT: ${{ steps.install-boost.outputs.BOOST_ROOT }}
Boost_DIR: ${{ steps.install-boost.outputs.Boost_DIR }}
OPENSSL_ROOT_DIR: ${{ steps.install-openssl.outputs.OPENSSL_ROOT_DIR }}
CURL_ROOT: ${{ steps.install-curl.outputs.CURL_ROOT }}
Copy link
Member

Choose a reason for hiding this comment

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

Is it safe to reference a step that might be skipped?

Copy link
Member Author

Choose a reason for hiding this comment

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

It should be. It should just end up with no value.

Boost_DIR: ${{ steps.install-boost.outputs.Boost_DIR }}
OPENSSL_ROOT_DIR: ${{ steps.install-openssl.outputs.OPENSSL_ROOT_DIR }}
CURL_ROOT: ${{ steps.install-curl.outputs.CURL_ROOT }}
CMAKE_PREFIX_PATH: ${{ steps.install-curl.outputs.CURL_ROOT }}
Copy link

Choose a reason for hiding this comment

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

Bug: Conditional CURL Installation Causes Environment Variable Issues

The CURL_ROOT and CMAKE_PREFIX_PATH environment variables are unconditionally set using outputs from the Install CURL step. Since this step is conditional on inputs.use_curl == 'true', these variables become empty when CURL is not used. This can cause build failures or unexpected behavior in subsequent build steps.

Fix in Cursor Fix in Web

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