Strategy Orders Service Deployment
Strategy Order Server is a windows service.
Prerequisites
Database tables
Strategy order server uses the following Database Tables and sql create scripts can be found below for MS SQL Server.
[STRATEGY_ORDERS]
[STRATEGY_ORDER_LEGS]
Sql Server
Access Rules
An access rule needs to be inserted for the relevant groups which will use the service.
insert into ACCESSRULES (OPERATION_NAME, PERMISSION, ACCESSLIST_ID) values ('StrategyOrderEntryService', 1, 1)
Deployment
0: Make sure the prerequisites have been fullfilled.
1: Copy files to server
The files should be installed here: C:\KodiakStrategyServer\
2: Windows Service install
The windows service is installed with the followind command line script as administrator.
"C:\Windows\Microsoft.NET\Framework\v4.0.30319\installutil.exe" "C:\KodiakStrategyServer\Kodi.Kodiak.Strategies.StrategyServer.exe"
3: Configure Task Scheduler task
A task scheduler task should be created to run the attached script file once a day.
Restart Strategy windows service batch script.
Configuration
There is only one configuration file which needs to be set.
Kodi.Kodiak.Strategies.StrategyServer.exe.config
App Settings
<appSettings>
<add key="ConnectionString" value="Server=xxxx;Initial Catalog=KODIAK;User Id=Kodiak;Password=xxxx;" />
<add key="ActiveMQPath" value="tcp://localhost:61616" />
<add key="ActiveMQClientId" value="StrategyServer" />
<!-- PROD environment -->
<add key="ApiUrl" value="https://api.livemarketdata.com" />
<add key="AuthUrl" value="https://users.livemarketdata.com/v2/token" />
<!-- Test Environment
<add key="ApiUrl" value="https://api-staging.livemarketdata.com" />
<add key="AuthUrl" value="https://users-staging.livemarketdata.com/v2/token" />
-->
<add key="AuthUsername" value="username@kodi.is" />
<add key="AuthPassword" value="xxxxxxx" />
<add key="log4net.Internal.Debug" value="false" />
</appSettings>
Wcf configuration in Kodi.Kodiak.Strategies.StrategyServer.exe.config
Logging
Logs are located in the following folder
C:\KODIAK_LOGS\StrategyServer
StrategyServer.log
StrategyServer.Requests.log
StrategyServer.Publisher.log