The Lab

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Summary

The Enterprise Replay Service allows a client to replay messages from any of their venue sessions.

Messages are available for replay immediately after they are sent to or from the original user.

  • Currently this service is only available to SBE protocol clients.
  • Message field information can be found in the SBE schema message definition.
  • Only Execution Reports are replayable.
  • Supports multiple concurrent connections. 


Client Session Management & Logon

Logon to the Replay Service is identical to any other gateway  - see https://confluence.marketfactory.com/x/IIFZAg for details.

The  Replay Service will never gap fill or require the client to gap fill. It will instead match the expected sequenece numbers provided in the Logon Message.

Any enabled user can be used to access the replay service even if the user is concurrently connected to other services.



Logon Message Notes. Does not cover all fields - refer to the SBE schema for other notes.
FieldCommentsExample
venuenameReplay service identifier provided by MarketFactory.client_replay
nextExpectedMsgSeqNum

The replay service does not track sequence numbers across sessions. It will match the sequence numbers of the client logon message.

It is preferred to set the Logon Message msgSeqNum and nextExpectedMsgSeqNum to 1.

1
sessionTypeMust be 'Replay'Replay



Logon Example
logonEncoder
  .venuename("client_replay")
  .username("testuser")
  .password("user1password")
  .nextExpectedMsgSeqNum(1)
  .heartBtInt((short) 30)
  .sessionType(SessionType.Replay)
  .text("");


Protocol Summary

1) After logon, submit an ApplicationMessageRequest to start the replay.

2) Receive zero or more ReplayedMessage messages.

3) Receive 1 ApplicationMessageReport message at the end of the replay. Every request will be terminated with an ApplicationMessageReport.



  • Only one ApplicationMessageRequest can be serviced at a time.
  • Only Execution Reports can be replayed.
  • Once a replay is complete, a new one may be started.
  • The UserRequest message is not required.


ApplicationMessageRequest Field Notes. Does not cover all fields - refer to the SBE schema for other notes. 
Field
CommentsExample
RefApplID
Gateway service name with type to replay message for. Format - venue_name.session_type.lmax.maker.exchange.Orders
ApplMessageTypes
Only ExecutionReport is supported and must be included in this field. Any other requested message types will be ignored..applMessageTypes().clear().executionReport(true)
ApplBegSeqNum

If provided, the ApplEndSeqNum must also be provided. Must be less than the ApplEndSeqNum.

Inclusive.

352
ApplEndSeqNum

If provided, the ApplBegSeqNum must also be provided. Must be greater than the ApplBegSeqNum.

Inclusive.

400
ApplStartTime

If provided, the ApplEndTime must also be provided. Must be before the ApplEndTime.

Epoch nanos.

1625718249000000000
ApplEndTime

If provided, the ApplStartTime must also be provided. Must be after the ApplStartTime.

Epoch nanos.

1625718259000000000


Acceptable ApplicationMessageRequest parameter combinations

  • Note: All 4 values must be explicitly set in each request. If not 'Set' to a value then explictily set the appropriate 'Null' Value.
applBegSeqNumapplEndSeqNumapplStartTimeapplEndTimeQuery
SetSetNullNullReplay all Execution Reports with sequence numbers equal to and between the provided sequence numbers.
NullNullSetSetReplay all Execution Reports between the provided start and end times.
SetSetSetSetReplay all Execution Reports between both the time and sequence numbers.



ApplicationMessageRequest Example
applicationMessageRequestEncoder
  .applReqID(System.currentTimeMillis())
  .applReqType(ApplReqType.StartRetransmission);
  final var noApplIDsEncoder = applicationMessageRequestEncoder.noApplIDsCount(1);
  noApplIDsEncoder.next();
  noApplIDsEncoder
    .refApplID("fidessa_orders.Orders")
    .applUsername("Test")
    .applMessageTypes().clear().executionReport(true);
  noApplIDsEncoder.applBegSeqNum(1);
  noApplIDsEncoder.applEndSeqNum(10000);
  noApplIDsEncoder.applStartTime(ApplicationMessageRequestEncoder.NoApplIDsEncoder.applStartTimeNullValue());
  noApplIDsEncoder.applEndTime(ApplicationMessageRequestEncoder.NoApplIDsEncoder.applEndTimeNullValue());




  • No labels