com.teraspaces.qwfix
Enum FIXStandaloneApplicationStartupMode

java.lang.Object
  extended by java.lang.Enum<FIXStandaloneApplicationStartupMode>
      extended by com.teraspaces.qwfix.FIXStandaloneApplicationStartupMode
All Implemented Interfaces:
Serializable, Comparable<FIXStandaloneApplicationStartupMode>

public enum FIXStandaloneApplicationStartupMode
extends Enum<FIXStandaloneApplicationStartupMode>

Specifies how a FIXStandaloneApplication should start.

FIXStandaloneApplication keep a persistence of intra-day FIX communications on local hard disk. If the process is shut down (either intentionally or because of a crash), the application business logic can be recovered by restarting the process and perform a "recovery" process.

The persistence keeps the version of all settings (schema, scheduler, session, engine etc) that were used to initially start the process. During recovery process, the settings of the exact version kept in persistence will be loaded. If new versions of settings were added to the repository after the initial startup but before the crash, the new settings won't be effective because the process still tries to load the versions kept in persistence.

RESET mode will disable recovery and force a fresh start of the process. Note Reset mode will reset the sequence number of all FIX sessions to "1". So Reset mode have to be used on both sides of connection. If the other side is not implemented with QWFIX, ask the administrator of the other side to clear all intraday FIX logs before start the process with Reset mode on your side. In Reset mode process also uses the latest version of settings from the repository.

RECONFIG will try to convert the persistence into the latest versions from the repository. Note if any schema is changed during the period, the FIX message log will be "re-converted". Some FIX message fields in the old messages may no longer be valid in new FIX schema, such fields will be removed in the new messages during the conversion process. RECONFIG will throw an exception if any old session is removed from the engine settings. Removing a session may seriously affect the business logic of the application anyway. Adding new sessions to new settings will work fine.

RESET or RECONFIG should only be used during debugging or QA process. RECOVER should be used in production mode and should be the default mode of your applications.


Enum Constant Summary
RECONFIG
          Specifies that the process should try to recover intra-day FIX communications with latest settings applied.
RECOVER
          Specifies that the process should try to recover intraday FIX communications, if there's any.
RESET
          Specifies that the process should always perform a fresh start.
 
Method Summary
static FIXStandaloneApplicationStartupMode valueOf(String name)
          Returns the enum constant of this type with the specified name.
static FIXStandaloneApplicationStartupMode[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

RECOVER

public static final FIXStandaloneApplicationStartupMode RECOVER
Specifies that the process should try to recover intraday FIX communications, if there's any. RECOVER should be the default mode and should be the only mode used in production environment.


RESET

public static final FIXStandaloneApplicationStartupMode RESET
Specifies that the process should always perform a fresh start. RESET mode always search for latest settings from repository. Note RESET mode resets the FIX sequence number of all sessions to "1". RESET mode must be performed on both sides of FIX sessions.


RECONFIG

public static final FIXStandaloneApplicationStartupMode RECONFIG
Specifies that the process should try to recover intra-day FIX communications with latest settings applied. Note RECONFIG may fail if a session is removed in the new settings.

Method Detail

values

public static FIXStandaloneApplicationStartupMode[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (FIXStandaloneApplicationStartupMode c : FIXStandaloneApplicationStartupMode.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static FIXStandaloneApplicationStartupMode valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null