chore: Add support for persistent store contract tests.#502
Open
kinyoklion wants to merge 6 commits intomainfrom
Open
chore: Add support for persistent store contract tests.#502kinyoklion wants to merge 6 commits intomainfrom
kinyoklion wants to merge 6 commits intomainfrom
Conversation
Co-Authored-By: rlamb@launchdarkly.com <kingdewman@gmail.com>
Co-Authored-By: rlamb@launchdarkly.com <kingdewman@gmail.com>
…s CI Co-Authored-By: rlamb@launchdarkly.com <kingdewman@gmail.com>
…r Windows CI" This reverts commit d960e6f.
Member
Author
|
Devin, please update with the latest changes from main. |
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
| # Inform the test harness of test service's port. | ||
| test_service_port: ${{ env.TEST_SERVICE_PORT }} | ||
| token: ${{ secrets.GITHUB_TOKEN }} | ||
| enable_persistence_tests: true |
There was a problem hiding this comment.
Missing Redis service container for persistence contract tests
High Severity
The contract-tests and contract-tests-curl jobs enable enable_persistence_tests: true and build with use_redis: true, but neither job defines a Redis services: container. Contrast with server-redis.yml, which properly includes a services: redis: block with the Redis image and port mapping. The persistence tests will attempt to connect to Redis at runtime and fail because no instance is running.
Additional Locations (1)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Summary
Adds support for running persistent data store contract tests against the C++ server SDK's Redis integration.
Key changes:
.github/actions/ci/action.yml): Addeduse_redisinput, passed as$4tobuild.shto explicitly controlLD_BUILD_REDIS_SUPPORT.scripts/build.sh: Added$4parameter for explicit Redis support toggle (overrides automatic target-name detection when provided).server-redis.yml: Addeduse_redis: trueto all Redis workflow jobs to ensure Redis support is enabled now that$4=false(the default) would otherwise override auto-detection.server.yml: Enableduse_redis: trueandenable_persistence_tests: truefor both contract test jobs.ConfigPersistentCache,ConfigPersistentStore, andConfigPersistentDataStorestructs; wiredpersistentDataStoreintoConfigParams.entity_manager.cpp): Implemented Redis persistent store creation and cache mode configuration (off,ttl,infinite) behindLD_REDIS_SUPPORT_ENABLEDcompile flag.main.cpp): Advertisespersistent-data-store-rediswhen Redis support is compiled in.launchdarkly::server_redis_sourceand definesLD_REDIS_SUPPORT_ENABLEDwhenLD_BUILD_REDIS_SUPPORTis ON.Updates since last revision:
mainwhich now includes PR chore: update CI runners and dependencies for macOS and Windows #505 (CI runner + OpenSSL + Boost pin fixes) and PR fix: update foxy for Boost 1.90 compatibility and unpin macOS Boost #506 (foxy Boost 1.90 compatibility + Boost unpin). All CI dependencies are resolved — all 44 checks pass.Review & Testing Checklist for Human
24 * 365 hoursTTL) matches what the contract test harness expects — confirm there isn't a dedicated "infinite" API onLazyLoadBuilder.CacheRefresh(std::chrono::seconds(0))) actually disables caching in theLazyLoadBuilderAPI as intended (i.e., 0 seconds means "don't cache" rather than "always stale").build.sh$4parameter logic doesn't break any other callers ofbuild.shthat may pass positional arguments differently. Note: when$4is not provided, the variable is unset and the existing auto-detection logic is preserved.Notes