biz.onixs.fix.engine
Class EngineSettings

java.lang.Object
  extended by biz.onixs.fix.engine.EngineSettings

public class EngineSettings
extends Object

The Engine configuration settings.


Field Summary
protected static String DEFAULT_STORAGE_FOLDER
           
 
Constructor Summary
EngineSettings()
           
 
Method Summary
 void addListenPort(int listenPort)
          Adds listen port for incoming FIX connections.
 int getConnectionInputStreamBufferSize()
           
 int getConnectionOutputQueueDrainAmount()
          Returns the max number of messages to take from the outgoing queue and send to the socket in a single call.
 int getConnectionOutputQueueSize()
           
 int getConnectionOutputStreamBufferSize()
           
 int getConnectionPerfPreferenceBandwidth()
           
 int getConnectionPerfPreferenceConnectionTime()
           
 int getConnectionPerfPreferenceLatency()
           
 int getConnectionRetriesInterval()
          Returns reconnection interval in milliseconds.
 int getConnectionRetriesNumber()
          Returns reconnection attempts number.
 int getConnectionTcpReceiveBufferSize()
           
 int getConnectionTcpSendBufferSize()
           
 int getDefaultHeartbeatInterval()
          Returns the default heartbeat interval in seconds.
 String getDialects()
          Returns the location of one or several files with the FIX dialects definition.
 String getFullStorageFolder()
           
 MessageFilter getInboundMessageLogFilter()
           
 String getLicense()
          Returns the content of the license file if it is set explicitly using setLicense(String).
 String getLicenseFile()
          Returns the name of the license file resource.
 Integer[] getListenPorts()
          Returns listen port(s) for incoming FIX connections.
 int getReasonableTransmissionTime()
          Returns reasonable transmission time as % from heartbeat interval value.
 int getSessionListenerDelayWarningThreshold()
           
 String getStorageFolder()
           
 void init(biz.onixs.util.settings.Settings settings)
           
 boolean isCheckCompIdsMatch()
          Returns whether SenderCompId and TargetCompId must match session values in every inbound FIX message.
 boolean isConnectionTcpNoDelay()
           
 boolean isLogInboundMessages()
           
 boolean isProcessLogonNextExpectedMsgSeqNum()
           
 boolean isSessionEventArgReuse()
          Returns whether to re-use session event argument objects in each session.
 boolean isSessionSendLogoutOnException()
          Returns option to send the Logout message before dropping the telecommunication link in case of Exception during the processing of incoming FIX message.
 boolean isValidateFieldValues()
           
 boolean isValidateInboundMessages()
           
 boolean isValidateNumberOfRepeatingGroupInstances()
           
 boolean isValidateOutboundMessages()
           
 boolean isValidateRequiredFields()
           
 boolean isValidateUnknownFields()
           
 void setCheckCompIdsMatch(boolean checkCompIdsMatch)
          Sets whether SenderCompId and TargetCompId must match session values in every inbound FIX message.
 void setConnectionInputStreamBufferSize(int connectionInputStreamBufferSize)
           
 void setConnectionOutputQueueDrainAmount(int connectionOutputQueueDrainAmount)
          Sets the max number of messages to take from the outgoing queue and send to the socket in a single call.
 void setConnectionOutputQueueSize(int connectionOutputQueueSize)
           
 void setConnectionOutputStreamBufferSize(int connectionOutputStreamBufferSize)
           
 void setConnectionPerfPreferenceBandwidth(int connectionPerfPreferenceBandwidth)
           
 void setConnectionPerfPreferenceConnectionTime(int connectionPerfPreferenceConnectionTime)
           
 void setConnectionPerfPreferenceLatency(int connectionPerfPreferenceLatency)
           
 void setConnectionRetriesInterval(int connectionRetriesInterval)
          Sets the reconnection interval in milliseconds.
 void setConnectionRetriesNumber(int connectionRetries)
          Sets reconnection attempts number.
 void setConnectionTcpNoDelay(boolean connectionTcpNoDelay)
           
 void setConnectionTcpReceiveBufferSize(int connectionTcpReceiveBufferSize)
           
 void setConnectionTcpSendBufferSize(int connectionTcpSendBufferSize)
           
 void setDefaultHeartbeatInterval(int defaultHeartbeatInterval)
          Sets the default heartbeat interval in seconds.
 void setDialects(String dialects)
          Sets the location of one or several files with the FIX dialects definition.
 void setInboundMessageLogFilter(MessageFilter inboundMessageLogFilter)
           
 void setLicense(String license)
          Sets the content of the license file.
 void setLicenseFile(String licenseFile)
          Sets the name of the license file resource.
 void setListenPorts(String listenPorts)
          Sets listen port(s) for incoming FIX connections.
 void setLogInboundMessages(boolean logInboundMessages)
           
 void setProcessLogonNextExpectedMsgSeqNum(boolean processLogonNextExpectedMsgSeqNum)
           
 void setReasonableTransmissionTime(int reasonableTransmissionTime)
          Sets reasonable transmission time as % from heartbeat interval value.
 void setSessionEventArgReuse(boolean sessionEventArgReuse)
          Sets whether to re-use session event argument objects in each session.
 void setSessionListenerDelayWarningThreshold(int sessionListenerDelayWarningThreshold)
           
 void setSessionSendLogoutOnException(boolean sessionSendLogoutOnException)
          Sets option to send the Logout message before dropping the telecommunication link in case of Exception during the processing of incoming FIX message.
 void setStorageFolder(String storageFolder)
           
 void setValidateFieldValues(boolean validateFieldValues)
           
 void setValidateInboundMessages(boolean validateInboundMessages)
           
 void setValidateNumberOfRepeatingGroupInstances(boolean validateNumberOfRepeatingGroupInstances)
           
 void setValidateOutboundMessages(boolean validateOutboundMessages)
           
 void setValidateRequiredFields(boolean validateRequiredFields)
           
 void setValidateUnknownFields(boolean validateUnknownFields)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_STORAGE_FOLDER

protected static final String DEFAULT_STORAGE_FOLDER
See Also:
Constant Field Values
Constructor Detail

EngineSettings

public EngineSettings()
Method Detail

getSessionListenerDelayWarningThreshold

public int getSessionListenerDelayWarningThreshold()

setSessionListenerDelayWarningThreshold

public void setSessionListenerDelayWarningThreshold(int sessionListenerDelayWarningThreshold)

isProcessLogonNextExpectedMsgSeqNum

public boolean isProcessLogonNextExpectedMsgSeqNum()

setProcessLogonNextExpectedMsgSeqNum

public void setProcessLogonNextExpectedMsgSeqNum(boolean processLogonNextExpectedMsgSeqNum)

getInboundMessageLogFilter

public MessageFilter getInboundMessageLogFilter()

setInboundMessageLogFilter

public void setInboundMessageLogFilter(MessageFilter inboundMessageLogFilter)

getConnectionOutputQueueDrainAmount

public int getConnectionOutputQueueDrainAmount()
Returns the max number of messages to take from the outgoing queue and send to the socket in a single call.

Returns:
max number of messages to send at once

setConnectionOutputQueueDrainAmount

public void setConnectionOutputQueueDrainAmount(int connectionOutputQueueDrainAmount)
Sets the max number of messages to take from the outgoing queue and send to the socket in a single call.

Parameters:
connectionOutputQueueDrainAmount - max number of messages to send at once
Throws:
EngineException - if (connectionOutputQueueDrainAmount < 1)

isValidateOutboundMessages

public boolean isValidateOutboundMessages()

setValidateOutboundMessages

public void setValidateOutboundMessages(boolean validateOutboundMessages)

isValidateInboundMessages

public boolean isValidateInboundMessages()

setValidateInboundMessages

public void setValidateInboundMessages(boolean validateInboundMessages)

isSessionSendLogoutOnException

public boolean isSessionSendLogoutOnException()
Returns option to send the Logout message before dropping the telecommunication link in case of Exception during the processing of incoming FIX message.

Returns:
option to send or not to send

setSessionSendLogoutOnException

public void setSessionSendLogoutOnException(boolean sessionSendLogoutOnException)
Sets option to send the Logout message before dropping the telecommunication link in case of Exception during the processing of incoming FIX message.

Parameters:
sessionSendLogoutOnException - option to send or not to send

isCheckCompIdsMatch

public boolean isCheckCompIdsMatch()
Returns whether SenderCompId and TargetCompId must match session values in every inbound FIX message.

Returns:
check flag

setCheckCompIdsMatch

public void setCheckCompIdsMatch(boolean checkCompIdsMatch)
Sets whether SenderCompId and TargetCompId must match session values in every inbound FIX message.

Parameters:
checkCompIdsMatch - check flag

getConnectionRetriesNumber

public int getConnectionRetriesNumber()
Returns reconnection attempts number.

Returns:
reconnection attempts number.

setConnectionRetriesNumber

public void setConnectionRetriesNumber(int connectionRetries)
Sets reconnection attempts number. The default value is 3.

Parameters:
connectionRetries - reconnection attempts number.
Throws:
EngineException - if (connectionRetries < 0)

getConnectionRetriesInterval

public int getConnectionRetriesInterval()
Returns reconnection interval in milliseconds.

Returns:
reconnection interval in milliseconds

setConnectionRetriesInterval

public void setConnectionRetriesInterval(int connectionRetriesInterval)
Sets the reconnection interval in milliseconds. The default value is 90000.

Parameters:
connectionRetriesInterval - reconnection interval in milliseconds
Throws:
EngineException - if (connectionRetriesInterval <= 0)

getDefaultHeartbeatInterval

public int getDefaultHeartbeatInterval()
Returns the default heartbeat interval in seconds.

Returns:
default heartbeat interval in seconds

setDefaultHeartbeatInterval

public void setDefaultHeartbeatInterval(int defaultHeartbeatInterval)
Sets the default heartbeat interval in seconds. The default value is 30.

Parameters:
defaultHeartbeatInterval - default heartbeat interval in seconds
Throws:
EngineException - if (defaultHeartbeatInterval < 0)

getFullStorageFolder

public String getFullStorageFolder()

setDialects

public void setDialects(String dialects)
Sets the location of one or several files with the FIX dialects definition. The file names are separated with the '|' character.

Parameters:
dialects - dialect files or empty string to set not dialects

getDialects

public String getDialects()
Returns the location of one or several files with the FIX dialects definition. The file names are separated with the '|' character.

Returns:
dialect files or empty string for no dialects

init

public void init(biz.onixs.util.settings.Settings settings)

getLicenseFile

public String getLicenseFile()
Returns the name of the license file resource. The default one is "OnixS.lic".

Returns:
license file resource

setLicenseFile

public void setLicenseFile(String licenseFile)
Sets the name of the license file resource. The default one is "OnixS.lic".

Parameters:
licenseFile - license file resource

setLicense

public void setLicense(String license)
Sets the content of the license file. It will have priority over external license file.

Parameters:
license - license file content, null to reset the value

getLicense

public String getLicense()
Returns the content of the license file if it is set explicitly using setLicense(String).

Returns:
license file content, null if it is not set explicitly

setListenPorts

public void setListenPorts(String listenPorts)
Sets listen port(s) for incoming FIX connections. Use comma delimited list if more than one listen port is required.

Parameters:
listenPorts - comma delimited list of listen ports

getListenPorts

public Integer[] getListenPorts()
Returns listen port(s) for incoming FIX connections.

Returns:
listen port(s)

addListenPort

public void addListenPort(int listenPort)
Adds listen port for incoming FIX connections. If it is set to 0 then only session-initiators can be created. If it is set to -1 then the telecommunication level is disabled and only message parsing/assembling.

Parameters:
listenPort - listen port

getStorageFolder

public String getStorageFolder()

setStorageFolder

public void setStorageFolder(String storageFolder)

isLogInboundMessages

public boolean isLogInboundMessages()

setLogInboundMessages

public void setLogInboundMessages(boolean logInboundMessages)

getReasonableTransmissionTime

public int getReasonableTransmissionTime()
Returns reasonable transmission time as % from heartbeat interval value.

Returns:
reasonable transmission time

setReasonableTransmissionTime

public void setReasonableTransmissionTime(int reasonableTransmissionTime)
Sets reasonable transmission time as % from heartbeat interval value.

Parameters:
reasonableTransmissionTime - reasonable transmission time

isValidateFieldValues

public boolean isValidateFieldValues()

isValidateNumberOfRepeatingGroupInstances

public boolean isValidateNumberOfRepeatingGroupInstances()

isValidateRequiredFields

public boolean isValidateRequiredFields()

isValidateUnknownFields

public boolean isValidateUnknownFields()

getConnectionPerfPreferenceBandwidth

public int getConnectionPerfPreferenceBandwidth()

getConnectionPerfPreferenceLatency

public int getConnectionPerfPreferenceLatency()

getConnectionPerfPreferenceConnectionTime

public int getConnectionPerfPreferenceConnectionTime()

setConnectionPerfPreferenceConnectionTime

public void setConnectionPerfPreferenceConnectionTime(int connectionPerfPreferenceConnectionTime)

setConnectionPerfPreferenceLatency

public void setConnectionPerfPreferenceLatency(int connectionPerfPreferenceLatency)

setConnectionPerfPreferenceBandwidth

public void setConnectionPerfPreferenceBandwidth(int connectionPerfPreferenceBandwidth)

getConnectionTcpReceiveBufferSize

public int getConnectionTcpReceiveBufferSize()

getConnectionTcpSendBufferSize

public int getConnectionTcpSendBufferSize()

setConnectionTcpReceiveBufferSize

public void setConnectionTcpReceiveBufferSize(int connectionTcpReceiveBufferSize)

setConnectionTcpSendBufferSize

public void setConnectionTcpSendBufferSize(int connectionTcpSendBufferSize)

isConnectionTcpNoDelay

public boolean isConnectionTcpNoDelay()

setConnectionTcpNoDelay

public void setConnectionTcpNoDelay(boolean connectionTcpNoDelay)

getConnectionInputStreamBufferSize

public int getConnectionInputStreamBufferSize()

setConnectionInputStreamBufferSize

public void setConnectionInputStreamBufferSize(int connectionInputStreamBufferSize)

getConnectionOutputStreamBufferSize

public int getConnectionOutputStreamBufferSize()

setConnectionOutputStreamBufferSize

public void setConnectionOutputStreamBufferSize(int connectionOutputStreamBufferSize)

getConnectionOutputQueueSize

public int getConnectionOutputQueueSize()

setConnectionOutputQueueSize

public void setConnectionOutputQueueSize(int connectionOutputQueueSize)

setValidateFieldValues

public void setValidateFieldValues(boolean validateFieldValues)

setValidateRequiredFields

public void setValidateRequiredFields(boolean validateRequiredFields)

setValidateUnknownFields

public void setValidateUnknownFields(boolean validateUnknownFields)

setValidateNumberOfRepeatingGroupInstances

public void setValidateNumberOfRepeatingGroupInstances(boolean validateNumberOfRepeatingGroupInstances)

isSessionEventArgReuse

public boolean isSessionEventArgReuse()
Returns whether to re-use session event argument objects in each session.

Returns:
whether to re-use session event argument objects

setSessionEventArgReuse

public void setSessionEventArgReuse(boolean sessionEventArgReuse)
Sets whether to re-use session event argument objects in each session.

Parameters:
sessionEventArgReuse - whether to re-use session event argument objects

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2005-2012 Onix Solutions. All Rights Reserved.