Documentation
¶
Overview ¶
Package settings provides a typed JSON representation of QuickFIX/Go settings. It complements quickfix.ParseSettings, which reads the traditional INI-style configuration format.
JSON boolean settings accept booleans or common string forms such as "Y", "N", "true", and "false". Integer settings accept JSON numbers or numeric strings. Unknown JSON fields are rejected so misspelled settings do not get silently ignored.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Boolean ¶
type Boolean bool
Boolean is a QuickFIX Y/N setting that accepts JSON booleans and common textual boolean forms.
func (*Boolean) UnmarshalJSON ¶
UnmarshalJSON accepts booleans and strings such as "Y", "N", "yes", and "no".
type ConnectionType ¶
type ConnectionType string
ConnectionType identifies whether a session accepts or initiates FIX connections.
const ( ConnectionTypeAcceptor ConnectionType = "acceptor" ConnectionTypeInitiator ConnectionType = "initiator" )
type Integer ¶
type Integer int
Integer is a QuickFIX integer setting that accepts a JSON number or string.
func (*Integer) UnmarshalJSON ¶
UnmarshalJSON accepts values such as 30 and "30".
type LoggingSettings ¶
type LoggingSettings struct {
FileLogPath *string `json:"fileLogPath,omitempty" quickfix:"FileLogPath"`
SQLLogDriver *string `json:"sqlLogDriver,omitempty" quickfix:"SQLLogDriver"`
SQLLogDataSourceName *string `json:"sqlLogDataSourceName,omitempty" quickfix:"SQLLogDataSourceName"`
SQLLogConnMaxLifetime *string `json:"sqlLogConnMaxLifetime,omitempty" quickfix:"SQLLogConnMaxLifetime"`
MongoLogConnection *string `json:"mongoLogConnection,omitempty" quickfix:"MongoLogConnection"`
MongoLogDatabase *string `json:"mongoLogDatabase,omitempty" quickfix:"MongoLogDatabase"`
MongoLogReplicaSet *string `json:"mongoLogReplicaSet,omitempty" quickfix:"MongoLogReplicaSet"`
}
LoggingSettings configures built-in log factories.
type ScheduleSettings ¶
type ScheduleSettings struct {
DefaultApplVerID *string `json:"defaultApplVerID,omitempty" quickfix:"DefaultApplVerID"`
StartTime *string `json:"startTime,omitempty" quickfix:"StartTime"`
EndTime *string `json:"endTime,omitempty" quickfix:"EndTime"`
StartDay *string `json:"startDay,omitempty" quickfix:"StartDay"`
EndDay *string `json:"endDay,omitempty" quickfix:"EndDay"`
Weekdays *string `json:"weekdays,omitempty" quickfix:"Weekdays"`
TimeZone *string `json:"timeZone,omitempty" quickfix:"TimeZone"`
TimeStampPrecision *string `json:"timeStampPrecision,omitempty" quickfix:"TimeStampPrecision"`
ResetOnLogon *Boolean `json:"resetOnLogon,omitempty" quickfix:"ResetOnLogon"`
RefreshOnLogon *Boolean `json:"refreshOnLogon,omitempty" quickfix:"RefreshOnLogon"`
ResetOnLogout *Boolean `json:"resetOnLogout,omitempty" quickfix:"ResetOnLogout"`
ResetOnDisconnect *Boolean `json:"resetOnDisconnect,omitempty" quickfix:"ResetOnDisconnect"`
ResetSeqTime *string `json:"resetSeqTime,omitempty" quickfix:"ResetSeqTime"`
}
ScheduleSettings controls session activation and sequence resets.
type Session ¶
type Session struct {
SessionIDSettings
ScheduleSettings
ValidationSettings
TLSSettings
LoggingSettings
StorageSettings
ConnectionType *ConnectionType `json:"connectionType,omitempty" quickfix:"ConnectionType"`
HeartBtInt *Integer `json:"heartBtInt,omitempty" quickfix:"HeartBtInt"`
ReconnectInterval *Integer `json:"reconnectInterval,omitempty" quickfix:"ReconnectInterval"`
LogoutTimeout *Integer `json:"logoutTimeout,omitempty" quickfix:"LogoutTimeout"`
LogonTimeout *Integer `json:"logonTimeout,omitempty" quickfix:"LogonTimeout"`
SocketConnectHost *string `json:"socketConnectHost,omitempty" quickfix:"SocketConnectHost"`
SocketConnectPort *Integer `json:"socketConnectPort,omitempty" quickfix:"SocketConnectPort"`
SocketTimeout *string `json:"socketTimeout,omitempty" quickfix:"SocketTimeout"`
ProxyType *string `json:"proxyType,omitempty" quickfix:"ProxyType"`
ProxyHost *string `json:"proxyHost,omitempty" quickfix:"ProxyHost"`
ProxyPort *Integer `json:"proxyPort,omitempty" quickfix:"ProxyPort"`
ProxyUser *string `json:"proxyUser,omitempty" quickfix:"ProxyUser"`
ProxyPassword *string `json:"proxyPassword,omitempty" quickfix:"ProxyPassword"`
SocketAcceptHost *string `json:"socketAcceptHost,omitempty" quickfix:"SocketAcceptHost"`
SocketAcceptPort *Integer `json:"socketAcceptPort,omitempty" quickfix:"SocketAcceptPort"`
HeartBtIntOverride *Boolean `json:"heartBtIntOverride,omitempty" quickfix:"HeartBtIntOverride"`
UseTCPProxy *Boolean `json:"useTCPProxy,omitempty" quickfix:"UseTCPProxy"`
DynamicSessions *Boolean `json:"dynamicSessions,omitempty" quickfix:"DynamicSessions"`
DynamicQualifier *string `json:"dynamicQualifier,omitempty" quickfix:"DynamicQualifier"`
ResendRequestChunkSize *Integer `json:"resendRequestChunkSize,omitempty" quickfix:"ResendRequestChunkSize"`
EnableLastMsgSeqNumProcessed *Boolean `json:"enableLastMsgSeqNumProcessed,omitempty" quickfix:"EnableLastMsgSeqNumProcessed"`
EnableNextExpectedMsgSeqNum *Boolean `json:"enableNextExpectedMsgSeqNum,omitempty" quickfix:"EnableNextExpectedMsgSeqNum"`
// AdditionalSettings supports custom settings, alternate SocketConnectHostN
// entries, and version-qualified AppDataDictionary keys. Keys use the exact
// QuickFIX setting name.
AdditionalSettings map[string]Value `json:"additionalSettings,omitempty"`
}
Session is a typed set of QuickFIX settings. Fields that do not apply to a session's connection type are ignored by QuickFIX itself.
type SessionIDSettings ¶
type SessionIDSettings struct {
BeginString *string `json:"beginString,omitempty" quickfix:"BeginString"`
SenderCompID *string `json:"senderCompID,omitempty" quickfix:"SenderCompID"`
SenderSubID *string `json:"senderSubID,omitempty" quickfix:"SenderSubID"`
SenderLocationID *string `json:"senderLocationID,omitempty" quickfix:"SenderLocationID"`
TargetCompID *string `json:"targetCompID,omitempty" quickfix:"TargetCompID"`
TargetSubID *string `json:"targetSubID,omitempty" quickfix:"TargetSubID"`
TargetLocationID *string `json:"targetLocationID,omitempty" quickfix:"TargetLocationID"`
SessionQualifier *string `json:"sessionQualifier,omitempty" quickfix:"SessionQualifier"`
}
SessionIDSettings identifies a FIX session.
type Settings ¶
Settings contains global defaults and one or more FIX sessions.
type StorageSettings ¶
type StorageSettings struct {
PersistMessages *Boolean `json:"persistMessages,omitempty" quickfix:"PersistMessages"`
FileStorePath *string `json:"fileStorePath,omitempty" quickfix:"FileStorePath"`
FileStoreSync *Boolean `json:"fileStoreSync,omitempty" quickfix:"FileStoreSync"`
SQLStoreDriver *string `json:"sqlStoreDriver,omitempty" quickfix:"SQLStoreDriver"`
SQLStoreDataSourceName *string `json:"sqlStoreDataSourceName,omitempty" quickfix:"SQLStoreDataSourceName"`
SQLStoreConnMaxLifetime *string `json:"sqlStoreConnMaxLifetime,omitempty" quickfix:"SQLStoreConnMaxLifetime"`
SQLStoreMessagesTableName *string `json:"sqlStoreMessagesTableName,omitempty" quickfix:"SQLStoreMessagesTableName"`
SQLStoreSessionsTableName *string `json:"sqlStoreSessionsTableName,omitempty" quickfix:"SQLStoreSessionsTableName"`
MongoStoreConnection *string `json:"mongoStoreConnection,omitempty" quickfix:"MongoStoreConnection"`
MongoStoreDatabase *string `json:"mongoStoreDatabase,omitempty" quickfix:"MongoStoreDatabase"`
MongoStoreReplicaSet *string `json:"mongoStoreReplicaSet,omitempty" quickfix:"MongoStoreReplicaSet"`
}
StorageSettings configures built-in message stores.
type TLSSettings ¶
type TLSSettings struct {
SocketPrivateKeyFile *string `json:"socketPrivateKeyFile,omitempty" quickfix:"SocketPrivateKeyFile"`
SocketCertificateFile *string `json:"socketCertificateFile,omitempty" quickfix:"SocketCertificateFile"`
SocketCAFile *string `json:"socketCAFile,omitempty" quickfix:"SocketCAFile"`
SocketPrivateKeyBytes *string `json:"socketPrivateKeyBytes,omitempty" quickfix:"SocketPrivateKeyBytes"`
SocketCertificateBytes *string `json:"socketCertificateBytes,omitempty" quickfix:"SocketCertificateBytes"`
SocketCABytes *string `json:"socketCABytes,omitempty" quickfix:"SocketCABytes"`
SocketInsecureSkipVerify *Boolean `json:"socketInsecureSkipVerify,omitempty" quickfix:"SocketInsecureSkipVerify"`
SocketServerName *string `json:"socketServerName,omitempty" quickfix:"SocketServerName"`
SocketMinimumTLSVersion *string `json:"socketMinimumTLSVersion,omitempty" quickfix:"SocketMinimumTLSVersion"`
SocketUseSSL *Boolean `json:"socketUseSSL,omitempty" quickfix:"SocketUseSSL"`
}
TLSSettings controls TLS connections.
type ValidationSettings ¶
type ValidationSettings struct {
DataDictionary *string `json:"dataDictionary,omitempty" quickfix:"DataDictionary"`
TransportDataDictionary *string `json:"transportDataDictionary,omitempty" quickfix:"TransportDataDictionary"`
AppDataDictionary *string `json:"appDataDictionary,omitempty" quickfix:"AppDataDictionary"`
RejectInvalidMessage *Boolean `json:"rejectInvalidMessage,omitempty" quickfix:"RejectInvalidMessage"`
AllowUnknownMessageFields *Boolean `json:"allowUnknownMsgFields,omitempty" quickfix:"AllowUnknownMsgFields"`
CheckUserDefinedFields *Boolean `json:"validateUserDefinedFields,omitempty" quickfix:"ValidateUserDefinedFields"`
ValidateFieldsOutOfOrder *Boolean `json:"validateFieldsOutOfOrder,omitempty" quickfix:"ValidateFieldsOutOfOrder"`
ValidateFieldsHaveValues *Boolean `json:"validateFieldsHaveValues,omitempty" quickfix:"ValidateFieldsHaveValues"`
CheckLatency *Boolean `json:"checkLatency,omitempty" quickfix:"CheckLatency"`
MaxLatency *Integer `json:"maxLatency,omitempty" quickfix:"MaxLatency"`
InChanCapacity *Integer `json:"inChanCapacity,omitempty" quickfix:"InChanCapacity"`
}
ValidationSettings controls data dictionaries and message validation.
type Value ¶
type Value string
Value is an additional QuickFIX setting value. It accepts a JSON string, number, or boolean and converts it to the textual representation expected by SessionSettings.
func (*Value) UnmarshalJSON ¶
UnmarshalJSON converts primitive JSON settings to QuickFIX text values.