Industry Challenge
In FX markets, speed is important. Liquidity conditions are dynamic and change in real-time, so orders must be sent promptly to minimize the risk of hitting stale quotes and being rejected.
Execution systems are the engines through which investment firms access and interact with markets, combining rich functionality with high performance. Hedge funds understand that having the right tools is beneficial – a system that lags behind peers is a strategic disadvantage.
The brief – from commercial to open source
FX execution systems are multi-layered, facilitating the entire FX trading lifecycle. Each element of the system communicates via Inter-Process Communication (IPC) to complete the trading flow. The bigger and more sophisticated the system, the greater the number of components and services to run simultaneously.
Fig. 1: FX Algo Engine Architecture
Man Group’s use case centered around its multicast RFQ protocol. The system needed to be able to take orders from upstream and compare them in real time with the available liquidity streamed from multiple liquidity providers. The quotes are then aggregated and fed into an algorithm which decides when best to execute orders against which liquidity.
To achieve this, latency is key. The algo must be aware of the most up-to-date quote data in order to make informed trading decisions. Any delay between receiving data to execution can result in changes in price, impacting the cost of the trade or perhaps even missing out altogether.
Man Group was looking for fast and reliable technology to meet the following selection criteria:
- Open-source tech to give the firm greater control of its functionality and roadmap.
- Predictable, ultra-low latency.
- Reliability under the highest data loads.
- Proven industry use cases and references.
The goal was to build a fully fault-tolerant, low-latency messaging layer.
Technical challenges
When Man Group decided to move away from its legacy messaging tool and started to integrate Aeron, a key technical challenge was navigating the existing infrastructure and shifting the system to a new host. For example, the Linux kernel – which manages the interaction between software and hardware – caused issues with Aeron’s idle strategy holding back immediate performance improvements.
Fig. 2: FX IPC Simulator
These issues were overcome by creating a virtual environment, simulating the execution system, to test the new software under multiple loads and ease implementation. Parameterising variables such as the number of quotes, their rate of quoting, and idle strategy enabled the tech team to tune the deployment appropriately. The system showed how Aeron could support the low latency messaging needs and helped the development team to productionize the technology.
Migration to Aeron
Man Group’s Technology team realized they would need to move the application to an alternative host to address the kernel idle strategy limitation. However, to avoid migrating the commercial IPC solution, Aeron had to be tuned to the existing host and rolled out there first. The simulator enabled them to do this with confidence.
The two-phase rollout strategy meant that the latency gains were achieved incrementally:
- Aeron deployed alongside the application and IPC migrated. At this point the latency testing saw:
- Small gains in lower percentiles, e.g. 10%
- A slightly more stable median in a similar latency range.
- Upper percentiles, e.g. 99%, remain similar due to the kernel idle strategy issue.
- Application migrated to an alternative host, resolving the kernel incompatibility issue. At this point, latency benefits were seen across all percentiles, particularly the upper ones.
Fig. 3: Latency Profiles During Migration – Using Logarithmic Scale
Aeron Roll-out
Over the course of the year-long project, Aeron was used to build two key components.
- A new, low-latency messaging layer: Aeron Transport became the vehicle for an updated IPC protocol capable of supporting multicast RFQ, trading instructions and system availability messages. As predicted, the new platform unlocked significant performance gains.
- Message persistence: Man Group later began using Aeron Archive for the recording and replay of inbound FIX messaging streams. The persisted streams may be used for real-time monitoring, offline analysis, and counterparty simulation in lower (pre-production) environments. Use of Archive gives confidence that messages can be relayed from latency-sensitive trading processes without blocking or back pressure.
Benefits of Aeron – in a nutshell
Man Group replaced its legacy technology with a state-of-the-art, open-source solution. Leveraging Aeron Transport and Archive technology, the firm was able to:Build a high-performance messaging layer.
- Improve its latency statistics and predictability.
- Ensure higher resilience to spikes of messages and instant recovery in case of failures.
- Future-proof its FX execution system.
- Build resiliency into the system so reporting processes do not interfere with trading activity.
The future
Man Group has added Aeron to its toolkit of approved technologies for any projects with low-latency requirements. The firm’s technology team subsequently integrated it into an equities and futures trading platform for communicating signals to algo execution engines.
Oskar Wantola
Head of Execution Technology
Man Group
Oskar Wantola heads the Execution Technology team at Man Group. The team is responsible for trading platforms from execution management systems, market connectivity, traders tooling to building execution algorithms and optimising trading workflows. Before joining Man Group in 2020, Oskar worked as a trading developer for HSBC, Bank of America, Morgan Stanley, Royal Bank of Scotland and Merrill Lynch, specialising in electronic and algorithmic solutions. Oskar holds a Master’s degree in Computer Science from Warsaw University and is a CFA charterholder.
Tim Raggatt
Staff Engineer, Execution Technology
Man Group
Tim Raggatt is a Staff Engineer in Execution Technology at Man Group. Since joining the team in 2016, Tim has helped build out Man Group’s execution capabilities across various asset classes, particularly in FX. Previously, he worked as a lead engineer at Open Gamma, an open-source market risk analytics company. Prior to this he worked at Bank of America Merrill Lynch and Barclays Capital on low-latency trading systems. Tim holds a first class bachelor’s degree in Computer Science from University of Manchester. He is also a graduate of the CQF (Certificate in Quantitative Finance) programme.