...
FEJ supports two modes of managing sessionsessions:
- immediately on the start
- postponed by using a cron expression
Managing of the timetable can be defined in in schedules.xml that which is located in the configuration directory.
...
- schedule - a group of tasks, related to the schedule
- id - ID of the schedule. Required. This parameter can be connected to the name of the endpoint. If it has the same name as an endpoint, then all tasks will be applied to that endpoint. Note that FIX session names are taken from their configuration files by the regexp - " s_fix_(.*)\.properties".
- task - there can be several tasks. Possible task properties:
- name - a name which that defines the task type
Predefined values:
start - a task for starting endpoint
stop - a task for stopping endpoints - onLoad - specifies whether a task should be executed during the FIXEdge Java server initialization.
- timeZone - time zone for triggering events within this task. Valid values are below.
- name - a name which that defines the task type
- event - triggers for the task execution.
- cron - a cron expression
- property - additional properties for the task
...
Timetable for a session that should start right after FEJ initialization
The file with the session's parameters has the following name: ss_fix_session1.properties
Code Block |
---|
<?xml version="1.0" encoding="UTF-8"?> <schedules xmlns="http://epam.com/fej/schedules"> <schedule id="session1"> <task name="start" onLoad="true"/> </schedule> </schedules> |
Note | ||
---|---|---|
| ||
The attribute "onLoad" set to "true" allows the session to start even in the case when the session property "startOnload" is set to "false" |
Timetable for a session that should start at 9 am and stop at 6 pm
The file with the session's parameters has the following name: ss_fix_Exchange.properties
Code Block |
---|
<?xml version="1.0" encoding="UTF-8"?> <schedules xmlns="http://epam.com/fej/schedules"> <schedule id="Exchange"> <task name="start" timeZone="Europe/Samara"> <event cron="0 0 09 ? * *"/> </task> <task name="stop" timeZone="Europe/Samara"> <event cron="0 0 18 ? * *"/> </task> </schedule> </schedules> |
...