OnixS C++ B3 BOE Binary Order Entry  1.2.0
API Documentation
Message Sequence Numbers

Message Sequencing

Each FIXP Session establishes independent incoming and outgoing message sequence numbers series.

Sequence numbers are initialized at the start of an FIXP session, starting at 1 and incremented by each application-level message through the session.

A single FIXP session with the same Session Version Identification (sessionVerId) can exist across multiple sequential physical connections. The client can connect and disconnect multiple times while maintaining the same FIXP session.

Once the OnixS::B3::BOE::Session::disconnect method is called, the physical connection is terminated, but the logical session does not end its lifetime. It is possible to continue the session later, using the OnixS::B3::BOE::Session::connect method again.

fixp-session-sequence-numbers.gif
See also
Restoring Session State
Scheduling Sessions for Automatic Connection

Manipulating Message Sequence Numbers

To get the expected sequence number of the next incoming message, use the OnixS::B3::BOE::Session::inSeqNum method.

To get the sequence number of the next outgoing message, use the OnixS::B3::BOE::Session::outSeqNum method.

Resetting Sequence Numbers

Resetting inbound and outbound message sequence numbers back to 1, for whatever reason, constitutes the beginning of a new logical FIXP session that should have a new SessionVerID. The OnixS::B3::BOE::Session::reset method must be used to back up previous log files, generate a new SessionVerID, and reset sequence numbers to 1.

Note
OnixS::B3::BOE::Session::inSeqNum and OnixS::B3::BOE::Session::outSeqNum methods can be used to set expected sequence numbers manually before an FIXP session is established. However, it is NOT recommended to use these methods to reset the message sequence numbers back to 1 to start a new logical FIXP session. Instead, use the OnixS::B3::BOE::Session::reset method.