Ember Latency Tuning Guide
This document describes how to tune the Ember configuration parameters to optimize the signal processing latency of Ember OMS and Ember algos.
More content is coming soon. The following information is a placeholder. In the meantime, please contact your Ember support team for assistance.
Out of the many things that can be done, there are several steps that usually provide quick results, described in the following sections.
CPU Affinity
Assuming you have followed the OS tuning steps like disabling C-States, isolated cores, and tuned profiles, the next step is to assign mission-critical Ember threads to isolated CPU cores.
Here's a sample configuration:
affinity {
message-bus = [8]
trade-gwy-sess-ORDERENTRY = [9]
trade-gwy-trans-ORDERENTRY = [10]
marketdata-gwy-sess-PRICES = [11]
marketdata-gwy-trans-PRICES = [12]
trade-engine = [13]
journal-swapper = [14]
algorithm-NIAGARA = [15]
#non-critical:
"[sender,receiver,driver-conductor]" = [16,17,34,35]
timebase-client = [16,17,34,35]
aeron-client-conductor = [16,17,34,35]
message-bus-input-dispatcher = [16,17,34,35]
logger = [16,17,34,35]
instrument-updater = [16,17,34,35]
CentralSMD = [16,17,34,35]
LocalSMStorage Flusher Thread 1 = [16,17,34,35]
default = [16,17,34,35]
fix-agent = [16,17,34,35]
aeron-driver-shared = [16,17,34,35]
}
You can find more information about thread-to-CPU affinity settingsd in the Configuration Guide.
IDLE Strategies
You can set idle strategies for different components in Ember to reduce the latency.
Here's a sample configuration:
engineIdleStrategy = ${template.idleStrategy.noop}
swapperIdleStrategy = ${template.idleStrategy.noop} // debatable
algorithms.NIAGARA.idleStrategy = ${template.idleStrategy.noop}
gateways.trade.ORDERENTRY.idleStrategy = ${template.idleStrategy.noop}
You can find more information about idle strategies in the Configuration Guide.
Memory usage
Large universe of instruments
When running Ember with installations that have very large set of instruments defined in TimeBase "securities" stream we recommend the following tuning:
Reduce instruments visible in Ember to tradable subset
Use Ember ability to filter out trading instruments:
instruments.subscription.filter = "TradeableSymbol != NULL"
See Configuration Guide for more information.
Reduce number of custom attributes Ember keeps in memory for each instrument
In addition to control how many instruments are cached in Ember memory you can also reduce amount of information Ember keeps for each instrument. Major part of this is custom instrument attributes.
Ember configuration allows to whitelist/blacklist set of custom attributes. Here is an example:
instruments.subscripion.includeCustomAttributes = [ "minNotionalApplyToMarket", "dma" ]