3
Migrate from QuickFIXJ to CrossFIX – the fastest Java ultra-low latency FIX Engine CrossFIX Engine has been designed for lowest possible latency in Java on Linux as well as to simplify migrating existing projects from QuickFIXJ Engine. - Absolute zero object allocation/garbage collection in steady state and absence of protocol errors - Lock free, zero copy, small CPU cache footprint. - Minimum queuing - TCP send/receive is done on a user thread (preferably affinitised to an isolated CPU core). - Ultra-low latency at mean and tail percentiles – 400ns latency for a typical FIX ExecutionReport message from client code to the network stack at 50th percentile and sub-500ns for 99.9 percentile; 550ns latency from the network stack to client code at 50th percentile and 700ns for 99.9 percentile. - High performance - maximum sustainable send throughput 2,669,000 messages/sec for a typical FIX ExecutionReport; receive throughput 2,213,000 messages/sec. - Message, session API/session configuration optimized for migration from QuickFIXJ with few API exceptions in latency-sensitive areas. - Sequence numbers and FIX message persistence using memory-mapped files. - Custom network library optimized for Kernel-bypass, tested with latest SolarFlare/OpenOnload. - Supports all FIX versions from 4.0 to 5.0sp2 as well as custom FIX dictionaries. - Fault tolerance with support for sequence number and FIX message replication between CrossFIX engines within the same fault-tolerant group as well as a support for electing the primary initiator. Latency benchmarks All latency tests have been conducted on Linux 3.16.7 kernel, Oracle Java 1.7.0_72, Intel Core i7- 4790K CPU. CrossFIX makes latency stamps available for querying in key areas thus simplifying the analysis of latency profiles of the applications. JMH was used to run all latency benchmarks. The test environment has been carefully tuned to remove noise coming from the operating system. This is to make sure that CrossFIX latencies in higher percentiles are completely transparent during latency benchmarking, unlike other commercial engines that either do not quote latencies in high percentiles or blame it on the operating system. Latency in high percentiles is extremely important, especially during major events when the market is moving very quickly and FIX Engine has to processes a lot of messages at lowest latency possible. 1) ExecutionReport serialization latency at 1000 messages/sec

CrossFIX 1.1

Embed Size (px)

Citation preview

Page 1: CrossFIX 1.1

Migrate from QuickFIXJ to CrossFIX – the fastest Java ultra-low latency FIX Engine

CrossFIX Engine has been designed for lowest possible latency in Java on Linux as well as to simplify migrating existing projects from QuickFIXJ Engine.

- Absolute zero object allocation/garbage collection in steady state and absence of protocol errors- Lock free, zero copy, small CPU cache footprint.- Minimum queuing - TCP send/receive is done on a user thread (preferably affinitised to an isolated CPU core).- Ultra-low latency at mean and tail percentiles – 400ns latency for a typical FIXExecutionReport message from client code to the network stack at 50th percentile and sub-500ns for 99.9 percentile; 550ns latency from the network stack to client code at 50th percentile and700ns for 99.9 percentile.- High performance - maximum sustainable send throughput 2,669,000 messages/sec for a typical FIX ExecutionReport; receive throughput 2,213,000 messages/sec.- Message, session API/session configuration optimized for migration from QuickFIXJ withfew API exceptions in latency-sensitive areas.- Sequence numbers and FIX message persistence using memory-mapped files.- Custom network library optimized for Kernel-bypass, tested with latest SolarFlare/OpenOnload.- Supports all FIX versions from 4.0 to 5.0sp2 as well as custom FIX dictionaries.- Fault tolerance with support for sequence number and FIX message replication between CrossFIX engines within the same fault-tolerant group as well as a support for electing the primary initiator.

Latency benchmarksAll latency tests have been conducted on Linux 3.16.7 kernel, Oracle Java 1.7.0_72, Intel Core i7-4790K CPU. CrossFIX makes latency stamps available for querying in key areas thus simplifyingthe analysis of latency profiles of the applications. JMH was used to run all latency benchmarks.

The test environment has been carefully tuned to remove noise coming from the operating system.This is to make sure that CrossFIX latencies in higher percentiles are completely transparent duringlatency benchmarking, unlike other commercial engines that either do not quote latencies in highpercentiles or blame it on the operating system. Latency in high percentiles is extremely important,especially during major events when the market is moving very quickly and FIX Engine has toprocesses a lot of messages at lowest latency possible.

1) ExecutionReport serialization latency at 1000 messages/sec

Page 2: CrossFIX 1.1

2) ExecutionReport send/receive latency excluding network stack latency at 1000 messages/sec

It is important to note here that all fields are serialized or parsed in session code, thus avoidinghidden latency of second-pass parsing. This is unlike some of the existing popular commercial lowlatency FIX engines that quote latency numbers that exclude field parsing.

Seamless migration from QuickFIXJ

CrossFIX API is is very similar to that of QuickFIXJ. You won't need to rewrite your Application,Session or Message handling code, most of the public methods are the same with the fewexceptions in latency sensitive areas e.g. String handling. Also in order to achieve lowest latencypossible it is preferred not to use generic methods of the Message interface – e.g. instead ofgetDouble(LastPx.FIELD) you should use getLastPx().

CrossFIX configuration closely follows that of QuickFIXJ. Almost all QuickFIXJ configurationparameters including those most frequently used in real-life applications are supported and haveexactly the same meaning in CrossFIX. There are also new configuration parameters introduced tosupport features not present in QuickFIXJ, e.g. session uptime schedule and asynchronous messagelogging.

CrossFIX has been successfully tested against the QuickFIXJ acceptance testing suite comprisingmore than 60 individual tests for each FIX protocol version and covering different aspects of FIXsession management and state transitions as well as message validation. This ensures that thebehaviour of applications that use QuickFIXJ will be exactly the same when migrated to useCrossFIX.

TestingCrossFIX has passed conformance testing on a select number of Exchanges without any issues and has been accepted for trading.

The supported platforms are Linux and Windows.

What's nextThe following features are planned in the future versions:

- FAST protocol support.- Load balancing over various network protocols.

Page 3: CrossFIX 1.1

LicensingCrossFIX is available under a commercial license. There is also a 30-day trial license available that also gives access to a rich set of documentation including Quick Start guide, User guide covering API and Configuration parameters as well as crossfix-examples project source code.

Please contact [email protected] to obtain a quote, receive a 30-day trial version or any further information

ConclusionIf your business is loosing money because of the latencies/GC pauses introduced by QuickFIXJ but do not have time to rewrite your FIX session/message handling code or if you are simply looking for the fastest ultra-low latency Java FIX Engine - CrossFIX should be your first choice.

Keywords: CrossFIX, QuickFIXJ, FIX, Low Latency Java FIX Engine

About the author: Konstantin Dmitriev, owner and developer of CrossFIX library