ores.refdata.client
Table of Contents
2. Summary
ores.refdata.client is a header-only library of consumer-side helpers
for reference data. It hosts the convention-aware FX rate formatter used
by every rate-display surface, and the currency_pair_convention_cache:
an in-process, per-tenant cache of currency-pair conventions loaded over
NATS and reloaded on changed events. Its registrar wires the warm-up and
the changed-event subscription at service startup. Consumers are the
market-data client and the removed market-data plugins. A load carries a
Bearer token when the producer checks authorisation; pass an
ores.iam.client-style token provider in that case.
3. Inputs
- Domain types from
ores.refdata.api:currency_pair_convention. - NATS protocol messages from
ores.refdata.api: theread_currency_pair_conventions_for_cacherequest/response pair and thecurrency_pair_convention_event.
4. Outputs
- C++ headers with the rate formatter, the tenant cache, and the cache registrar.
5. Entry points
service/cache/currency_pair_convention_cache.hpp—load()andlookup()per tenant.service/cache/currency_pair_convention_cache_registrar.hpp—warm_and_subscribe_currency_pair_convention_cache().presentation/currency_pair_rate_formatter.hpp—format_rate().
6. Dependencies
ores.refdata.api— the domain and protocol types.ores.eventing— the changed-event types and thepartitioned_cacheprimitive.ores.nats— the service client and subscription type.ores.logging— logger setup.- Optionally, an
ores.iam.clienttoken provider for authenticated loads.
7. Build dependencies
What the shared profile cannot know, declared here rather than hand-edited into the generated build file. Each block is spliced into its generated file after the profile's baseline.
8. See also
- ores.refdata — component group overview.
- ores.refdata.api — domain types and NATS protocol messages.
- ores.refdata.service — the NATS service the client helpers talk to.
- ores.refdata Messaging Reference — full NATS subject and message catalogue.
- Where should an entity-mirror cache live? — the placement rules for this cache and its registrar.
9. Test dependencies
The suites link what the profile cannot know about.
target_link_libraries(${lib_target_name}
INTERFACE
ores.nats.lib
ores.refdata.api.lib
ores.eventing.api.lib
ores.eventing.core.lib
ores.logging.lib
ores.utility.lib)
target_link_libraries(${tests_target_name}
PRIVATE
ores.refdata.client.lib
ores.telemetry.core.lib
ores.utility.lib
ores.testing.lib
Catch2::Catch2
ores.openssl_cleanup
Threads::Threads)
