Memory-based session storage is typically used to maintain a high-performance FIX session when persisting of a sessions state and messages to the file system is not required.

Switching to Memory-based Session Storage

To create such a session the storageType parameter in Session(String, String, ProtocolVersion, Boolean, Session..::.SessionStorageType) constructor has to be set to MemoryBasedStorage value.

Example

CopyC#
bool keepSequenceNumbersAfterLogout = false;

Session session = new Session(
    "SenderCompID", 
    "TargetCompID", 
    ProtocolVersion.FIX42, 
    keepSequenceNumbersAfterLogout, 
    Session.SessionStorageType.MemoryBasedStorage);