Package deltix.qsrv.testsetup
Class TickDBCreator
- java.lang.Object
-
- deltix.util.cmdline.DefaultApplication
-
- deltix.qsrv.testsetup.TickDBCreator
-
public class TickDBCreator extends deltix.util.cmdline.DefaultApplication
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
BARS_STREAM_KEY
static java.lang.String
LOCATION
static int
NUM_MESSAGES
static int
NUM_SYMBOLS
static int
NUM_TEST_STREAMS
static int
NUM_TYPES
static java.lang.String
RO_CUST_TICKS_LOCATION
static java.lang.String
RO_MINUTES_LOCATION
static long
TEST_BASE_TIMESTAMP
static int
TEST_DF
static deltix.qsrv.hf.pub.InstrumentIdentity[]
TEST_IDS
static java.lang.String[]
TEST_STREAM_KEYS
static java.lang.String[]
TEST_SYMBOLS
static java.lang.String[]
TYPE_NAMES
-
Constructor Summary
Constructors Constructor Description TickDBCreator(java.lang.String[] args)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static DXTickStream
createBarsStream(DXTickDB db)
static DXTickStream
createBarsStream(DXTickDB tdb, java.lang.String name)
static DXTickStream
createTestStream(DXTickDB tdb, int idx)
static void
createTestStreams(DXTickDB db)
static DXTickDB
createTickDB(java.lang.String url, boolean format)
static void
generateTestData(int sidx, TickLoader loader)
static long
getTestTimestamp(int streamIdx, int entityIdx, int sequenceIdx)
static void
loadBars(java.lang.String symbol, java.io.InputStream is, TickLoader loader)
static void
loadBarsFromZip(java.util.zip.ZipInputStream zis, TickLoader loader)
static void
loadBarsFromZipResource(java.lang.String path, TickLoader loader)
static void
main(java.lang.String[] args)
static DXTickDB
openStdMinutesTestDB()
static DXTickDB
openStdTicksTestDB(java.lang.String path)
protected void
run()
static deltix.qsrv.hf.pub.InstrumentIdentity[]
testEntities(int... ids)
-
Methods inherited from class deltix.util.cmdline.DefaultApplication
createDateFormat, createDecimalFormat, findArg, getArgs, getArgValue, getArgValue, getArgValues, getDateArg, getDateFormatSpec, getDefaultDateFormat, getDefaultTimeZone, getDoubleArgValue, getFileArg, getFileArgs, getIntArgValue, getLongArgValue, getMandatoryArgValue, getMandatoryFileArg, getTimeZone, handleException, isArgSpecified, parseDateTime, printException, printException, printUsage, printUsage, printUsageAndExit, start
-
-
-
-
Field Detail
-
LOCATION
public static final java.lang.String LOCATION
-
RO_MINUTES_LOCATION
public static final java.lang.String RO_MINUTES_LOCATION
-
RO_CUST_TICKS_LOCATION
public static final java.lang.String RO_CUST_TICKS_LOCATION
-
BARS_STREAM_KEY
public static final java.lang.String BARS_STREAM_KEY
- See Also:
- Constant Field Values
-
TEST_BASE_TIMESTAMP
public static final long TEST_BASE_TIMESTAMP
- See Also:
- Constant Field Values
-
NUM_TEST_STREAMS
public static final int NUM_TEST_STREAMS
- See Also:
- Constant Field Values
-
TEST_STREAM_KEYS
public static final java.lang.String[] TEST_STREAM_KEYS
-
TEST_DF
public static final int TEST_DF
- See Also:
- Constant Field Values
-
NUM_SYMBOLS
public static final int NUM_SYMBOLS
- See Also:
- Constant Field Values
-
TEST_SYMBOLS
public static final java.lang.String[] TEST_SYMBOLS
-
TEST_IDS
public static final deltix.qsrv.hf.pub.InstrumentIdentity[] TEST_IDS
-
NUM_MESSAGES
public static final int NUM_MESSAGES
- See Also:
- Constant Field Values
-
TYPE_NAMES
public static final java.lang.String[] TYPE_NAMES
-
NUM_TYPES
public static final int NUM_TYPES
-
-
Method Detail
-
openStdMinutesTestDB
public static DXTickDB openStdMinutesTestDB()
-
openStdTicksTestDB
public static DXTickDB openStdTicksTestDB(java.lang.String path) throws java.io.IOException, java.lang.InterruptedException
- Throws:
java.io.IOException
java.lang.InterruptedException
-
loadBars
public static void loadBars(java.lang.String symbol, java.io.InputStream is, TickLoader loader) throws java.io.IOException
- Throws:
java.io.IOException
-
loadBarsFromZip
public static void loadBarsFromZip(java.util.zip.ZipInputStream zis, TickLoader loader) throws java.io.IOException
- Throws:
java.io.IOException
-
loadBarsFromZipResource
public static void loadBarsFromZipResource(java.lang.String path, TickLoader loader) throws java.io.IOException
- Throws:
java.io.IOException
-
testEntities
public static deltix.qsrv.hf.pub.InstrumentIdentity[] testEntities(int... ids)
-
getTestTimestamp
public static long getTestTimestamp(int streamIdx, int entityIdx, int sequenceIdx)
-
generateTestData
public static void generateTestData(int sidx, TickLoader loader)
-
createTestStreams
public static void createTestStreams(DXTickDB db)
-
createTestStream
public static DXTickStream createTestStream(DXTickDB tdb, int idx)
-
createTickDB
public static DXTickDB createTickDB(java.lang.String url, boolean format)
-
createBarsStream
public static DXTickStream createBarsStream(DXTickDB db)
-
createBarsStream
public static DXTickStream createBarsStream(DXTickDB tdb, java.lang.String name)
-
run
protected void run() throws java.lang.Throwable
- Specified by:
run
in classdeltix.util.cmdline.DefaultApplication
- Throws:
java.lang.Throwable
-
main
public static void main(java.lang.String[] args) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-