7 #include <launchdarkly/server_side/integrations/data_reader/iserialized_data_reader.hpp>
9 #include <tl/expected.hpp>
18 namespace launchdarkly::server_side::integrations {
49 static tl::expected<std::unique_ptr<RedisDataSource>, std::string>
Create(
53 [[nodiscard]] GetResult Get(ISerializedItemKind
const& kind,
54 std::string
const& itemKey)
const override;
55 [[nodiscard]] AllResult All(ISerializedItemKind
const& kind)
const override;
56 [[nodiscard]] std::string
const& Identity()
const override;
57 [[nodiscard]]
bool Initialized()
const override;
65 [[nodiscard]] std::string key_for_kind(
66 ISerializedItemKind
const& kind)
const;
68 std::string
const prefix_;
69 std::string
const inited_key_;
70 std::unique_ptr<sw::redis::Redis> redis_;
RedisDataSource represents a data source for the Server-Side SDK backed by Redis. It is meant to be u...
Definition: redis_source.hpp:32
static tl::expected< std::unique_ptr< RedisDataSource >, std::string > Create(std::string uri, std::string prefix)
Creates a new RedisDataSource, or returns an error if construction failed.
Definition: redis_source.cpp:7