LoadFile¶
External files can be loaded into 3forge via the Relay LoadFile plugin.
Step-by-step Guide¶
-
Telnet into the platform's real-time streaming port, this is set by the property
ami.portand is 3289 by default. -
Login with a string identifying your process (in this case,
demo). -
Run your LoadFile command, e.g.:
LoadFile Command¶
The LoadFile command has several options, below is a breakdown of each one for this example:
T="LoadFile"- Indicates a LoadFile command.
LOGIN="xxx"- Required login instruction for replay file.
FILE="/path/xxx.log"- COMPULSORY, Name and path to the file to load, this can be absolute or relative to path from the 3forge application installation directory
amione/ COLUMNS="COL1,COL2,COL3..."- COMPULSORY, a comma delimited list of column names.
CLASSES="CLASS1,CLASS2,CLASS3..."- COMPULSORY, a comma delimited list of column classes corresponding to the
COLUMNS MPS=xxx (long)- OPTIONAL, stands for "Max Per Second", which is the maximum number of lines read from the file per second. This is referred to as MAX_PER_SECOND as it does not guarantee exactness.
NULL="xxx"- OPTIONAL, by default is
null, the value that should be treated as null. QUOTES="x"- OPTIONAL, by default is
null, the char value that should be treated as quotes. For example, if the raw value is#123#, by specifyingQUOTES="#", the value that comes out will be123. LIMIT=xx (long)- OPTIONAL, by default is
java.Long.MAXVALUE, the maximum number of lines to be read from the file. SKIP=xx (long)- OPTIONAL, by default is
0, the number of lines to skip. For example, by specifyingSKIP=1, the parser would skip the first line and start reading from the second line. DELIM="x"- OPTIONAL, by default is
",", the delimeter of the row contents. TYPE="xxx"- OPTIONAL, by default is
"FILE: Your_File_Directory", the table name in the Center.
