ZagTrader

QuickFIX Session Schedules: Daily vs Weekly Sessions, Time Zones and Sunday to Thursday Markets

Written and maintained by ZagTrader. Last reviewed . How this page is sourced and checked

The schedule decides two things: when the session may be logged on, and when a new session period starts. A new period starts with sequence numbers at 1. Getting the schedule wrong gives sessions that will not log on, or that reset on a day the counterparty does not.

Daily or weekly

PatternSettingsSequence numbers reset
DailyStartTime, EndTimeAt every StartTime
Daily on some days onlyStartTime, EndTime, Weekdays (QuickFIX/J, QuickFIX/n)At StartTime on each listed day
WeeklyStartDay, StartTime, EndDay, EndTimeOnce a week, at StartDay and StartTime
Never endsNonStopSession=YNever by time; only by a reset you trigger
  • Agree the reset point with the counterparty. If you reset daily and they reset weekly, Tuesday morning starts with MsgSeqNum too low.
  • At start-up the engine compares the store's creation time with the schedule. If the store belongs to an earlier period, QuickFIX/J logs "Session state is not current; resetting" and starts at 1.
  • StartDay and EndDay must come together; Weekdays cannot be combined with them.

Time zones

Times are UTC by default. That is safe but easy to get wrong when the counterparty states its hours in local time. The options differ by engine:

SettingEnginesNotes
TimeZoneQuickFIX/J, QuickFIX/nQuickFIX/J takes Java zone IDs such as Asia/Riyadh and stops with an error on an unknown ID. QuickFIX/n hands the ID to the operating system; check it resolves on your host.
StartTime=07:00:00 Asia/RiyadhQuickFIX/JA zone after the time applies to that time only.
UseLocalTimeQuickFIX/n, QuickFIX C++Uses the host's clock zone. QuickFIX/n refuses it next to TimeZone.

Prefer a named zone over UseLocalTime: the schedule then does not change when the server moves or its clock zone is changed. Messages always carry UTC in SendingTime (52) whatever the schedule uses.

Sunday to Thursday markets

The Saudi Exchange and Boursa Kuwait have traded Sunday to Thursday, and the UAE exchanges Monday to Friday (sources and details in FIX in GCC and MENA markets); take each venue's days from its own trading calendar. A firm connected to both can run sessions on six days, so each session needs its own schedule. The times below are examples; use the counterparty's session hours.

QuickFIX/J: a daily session on Sunday to Thursday, in Riyadh time
[SESSION]
BeginString=FIX.4.4
SenderCompID=BUYSIDE
TargetCompID=RIYADH-BRK
TimeZone=Asia/Riyadh
StartTime=08:00:00
EndTime=17:00:00
Weekdays=Sun,Mon,Tue,Wed,Thu
Any engine: a weekly session from Sunday morning to Thursday evening (times in UTC)
[SESSION]
StartDay=Sunday
StartTime=05:00:00
EndDay=Thursday
EndTime=14:00:00
  • QuickFIX C++ has no Weekdays setting. Use the weekly form, or one daily session and logon control in your application.
  • QuickFIX/J reads Weekdays in the JVM's default locale. On a server whose locale is Arabic or French, Sun,Mon may not parse; set the JVM locale or use the names of that locale.
  • With the weekly form, a day order's life and the sequence reset no longer line up: the session keeps its numbers all week. Make sure the counterparty resets weekly too.
  • A Sunday session on an engine scheduled Monday to Friday is simply outside its schedule and never logs on. That is the first thing to check when a regional session is silent on Sunday.

Questions

What time zone does QuickFIX use for StartTime and EndTime?
UTC, unless you set TimeZone (QuickFIX/J and QuickFIX/n), put a zone after the time (QuickFIX/J) or set UseLocalTime=Y (QuickFIX/n and QuickFIX C++).
How do I run a QuickFIX session Sunday to Thursday?
In QuickFIX/J and QuickFIX/n, use StartTime, EndTime and Weekdays=Sun,Mon,Tue,Wed,Thu with a TimeZone. In any engine, a weekly session with StartDay=Sunday and EndDay=Thursday also works.
Why does my QuickFIX session not log on at the weekend?
It is outside its schedule. QuickFIX only logs on between StartTime and EndTime on the scheduled days.

The FIX side of the problem

What the error means on any FIX engine, with example messages you can open in the parser:

Reference

Sources

  1. QuickFIX/J user manual: Configuration
  2. QuickFIX/J source: DefaultSessionSchedule.java (StartTime, Weekdays, TimeZone)
  3. QuickFIX/J source: Session.java (setting names, defaults, logout and reject texts)
  4. QuickFIX/n documentation: Configuration
  5. QuickFIX/n source: SessionSchedule.cs (Weekdays, TimeZone, UseLocalTime)
  6. QuickFIX C++ documentation: Configuration
  7. QuickFIX C++ source: SessionSettings.h (setting names)

Setting names, defaults and message texts were checked against the projects' source code and documentation on the review date shown at the top of the page. Behaviour can change between releases; check the version you run. This guide is independent and not affiliated with the QuickFIX projects.

See also

More QuickFIX guides