Expand description
In-memory cache for market and execution data, with optional persistent backing.
Provides methods to load, query, and update cached data such as instruments, orders, and prices.
Re-exports§
pub use config::CacheConfig;pub use refs::AccountRef;pub use refs::AccountRefMut;pub use refs::OrderRef;pub use refs::OrderRefMut;pub use refs::PositionRef;pub use refs::PositionRefMut;
Modules§
- config
- database
- Provides a
Cachedatabase backing. - fifo
- Bounded FIFO caches for tracking IDs and key-value pairs with O(1) lookups.
- quote
- Generic quote cache for maintaining the last known quote per instrument.
- refs
- Lifetime-scoped reference newtypes for values held in the platform cache.
Structs§
- Cache
- A common in-memory
Cachefor market and execution related data. - Cache
Api - User-facing cache API.
- Cache
Snapshot Ref - Cache-owned reference to a snapshot blob.
- Cache
View - Read-only view over the platform cache.
Enums§
- Account
Lookup Error - Error returned when an account cannot be resolved from a cache or store.
- Currency
Lookup Error - Error returned when a currency cannot be resolved from a cache or store.
- Instrument
Lookup Error - Error returned when an instrument cannot be resolved from a cache or store.
- Order
Book Lookup Error - Error returned when an order book cannot be resolved from a cache or store.
- Order
List Lookup Error - Error returned when an order list cannot be resolved from a cache or store.
- Order
Lookup Error - Error returned when an order cannot be resolved from a cache or store.
- OwnOrder
Book Lookup Error - Error returned when an own order book cannot be resolved from a cache or store.
- Position
Lookup Error - Error returned when a position cannot be resolved from a cache or store.
- Synthetic
Instrument Lookup Error - Error returned when a synthetic instrument cannot be resolved from a cache or store.
Constants§
- ACCOUNT_
NOT_ FOUND - Message used for a missing account lookup.
- CURRENCY_
NOT_ FOUND - Message used for a missing currency lookup.
- INSTRUMENT_
NOT_ FOUND - Message used for a missing instrument lookup.
- ORDER_
BOOK_ NOT_ FOUND - Message used for a missing order book lookup.
- ORDER_
LIST_ NOT_ FOUND - Message used for a missing order list lookup.
- ORDER_
NOT_ FOUND - Message used for a missing order lookup.
- OWN_
ORDER_ BOOK_ NOT_ FOUND - Message used for a missing own order book lookup.
- POSITION_
NOT_ FOUND - Message used for a missing position lookup.
- SYNTHETIC_
INSTRUMENT_ NOT_ FOUND - Message used for a missing synthetic instrument lookup.