Skip to content

Binary EntryPoint Support

Richard Warburton edited this page Aug 30, 2021 · 5 revisions

What is Binary EntryPoint and who should use it?

Binary EntryPoint is a FIXP based protocol for binary order entry used by B3. The B3 Documentation provides details of the protocol itself and should be considered a reference guide, the rest of this wiki page just explains how Artio can be used with Binary EntryPoint.

How does Binary EntryPoint relate to Artio?

Binary EntryPoint is an order entry protocol that Artio supports. Just in the same way that Artio supports different versions of the FIX protocol. That means that Artio will manage the Binary EntryPoint session protocol and your application has to handle the business logic side of things for example sending orders and handling execution reports.

Status

Feature complete.

Implementing Binary EntryPoint with Artio

Setup your project

The Binary EntryPoint implementation requires additional dependencies to artio-core with the following coordinates: uk.co.real-logic:artio-binary-entrypoint-codecs and uk.co.real-logic:artio-binary-entrypoint-impl. These packages are released to maven central along with normal artio releases. Here is an example dependencies section that includes Artio with Binary EntryPoint support.

dependencies {
    implementation "uk.co.real-logic:artio-binary-entrypoint-codecs:${artioVersion}"
    implementation "uk.co.real-logic:artio-binary-entrypoint-impl:${artioVersion}"
    implementation "uk.co.real-logic:artio-codecs:${artioVersion}"
    implementation "uk.co.real-logic:artio-core:${artioVersion}"
}

Core concepts

Within Artio each FIXP session is uniquely identified by a uk.co.real_logic.artio.fixp.FixPKey and each individual connection by a uk.co.real_logic.artio.fixp.FixPContext. Because sessions can have many connections each FixPKey can be associated with many FixPContext objects. The core object that represents a FIXP connection is a uk.co.real_logic.artio.fixp.FixPConnection - the equivalent of our Session object for FIX. This defines the state and the API that is common to all FIXP implementations.

For any Binary EntryPoint implementation specific methods you can cast this connection object to a uk.co.real_logic.artio.binary_entrypoint.BinaryEntryPointConnection.

Please refer to Artio's normal documentation and samples for examples of how to setup a FixEngine and FixLibrary within your project. These examples assume that you have a connected Library and go from there. The general pattern for accepting FIXP connections is that you have equivalent to Handler interfaces to the FIX interface but with a FIXP prefix here is a table showing comparable interfaces. Due to the nature of the difference between the FIX and FIXP protocols we don't share the exact same interface.

FIX FIXP
uk.co.real_logic.artio.session.CompositeKey uk.co.real_logic.artio.fixp.FixPKey
uk.co.real_logic.artio.library.SessionExistsHandler uk.co.real_logic.artio.library.FixPConnectionExistsHandler
uk.co.real_logic.artio.library.SessionAcquireHandler uk.co.real_logic.artio.library.FixPConnectionAcquiredHandler
uk.co.real_logic.artio.library.SessionHandler uk.co.real_logic.artio.fixp.FixPConnectionHandler
uk.co.real_logic.artio.session.Session uk.co.real_logic.artio.fixp.FixPConnection
uk.co.real_logic.artio.engine.logger.FixMessageConsumer uk.co.real_logic.artio.fixp.FixPMessageConsumer
uk.co.real_logic.artio.BusinessRejectRefIdExtractor uk.co.real_logic.artio.fixp.FixPRejectRefIdExtractor

Accepting Connections

You can take a look at a working example in the uk.co.real_logic.artio.example_fixp_exchange package of the artio-samples project. This can be run with the sample program uk.co.real_logic.artio.system_tests.FixPExchangeApplication.

Firstly in order to accept Binary EntryPoint connections you need to set EngineConfiguration configuration option: configuration.acceptFixPProtocol(FixPProtocolType.BINARY_ENTRYPOINT).

configuration.fixPAuthenticationStrategy((context, authProxy) ->
{
    System.out.println("Request to authenticate: " + context);
    authProxy.accept();
});

Sending Application level Messages

Artio implementation differences compared to FIX

Artio's Binary EntryPoint implementation is Acceptor only, doesn't support Engine owned sessions, sole library mode.

Clone this wiki locally