Class StructureCreator
java.lang.Object
com.Lomikel.Januser.JanusClient
com.astrolabsoftware.FinkBrowser.Januser.StructureCreator
- All Implemented Interfaces:
ModifyingGremlinClient
StructureCreator
generates the network of higher level entities
from the LSST Alert
s.- Author:
- J.Hrivnac
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionStructureCreator
(String properties) Create with connection properties file.StructureCreator
(String hostname, int port, String table) Create with connection parameters.StructureCreator
(String hostname, int port, String table, boolean batch) Create with connection parameters. -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Create JanusGraph structures from the HBase database.populateGraphFromHBase
(String hbaseHost, int hbasePort, String hbaseTable, String tableSchema, String label, String rowkey, String keyPrefixSearch, String keyStart, String keyStop, long start, long stop, int limit, int skip, int commitLimit, boolean reset, boolean getOrCreate, boolean fullFill, String partialFill, String geopoint) Populate JanusGraph from HBase table.Methods inherited from class com.Lomikel.Januser.JanusClient
close, commit, g, open, open, reopen, timer, timerStart
-
Field Details
-
log
Logging .
-
-
Constructor Details
-
StructureCreator
Create with connection parameters.- Parameters:
hostname
- The HBase hostname.port
- The HBase port.table
- The HBase table.
-
StructureCreator
Create with connection parameters.- Parameters:
hostname
- The HBase hostname.port
- The HBase port.table
- The HBase table.batch
- Whether open graph for batch loading.
-
StructureCreator
Create with connection properties file.- Parameters:
properties
- The file with the complete properties.
-
-
Method Details
-
main
Create JanusGraph structures from the HBase database.- Parameters:
args
- [0] The operation to perform: populate.args
- [1] The file with the complete JanusGraph properties.args
- [2] The HBase hostname.args
- [3] The HBase port.args
- [4] The HBase table to replicate in Graph.args
- [5] The HBase table schema name.args
- [6] The label of newly created Vertexes.args
- [7] The row key name.args
- [8] The key prefix to limit replication to.args
- [9] The key to start search from (in ms), may be blank.args
- [10] The key to stop search at (in ms), may be blank.args
- [11] The time start search from, may be 0.args
- [12] The time stop search at, may be 0.args
- [13] The maximal number of entries to process (-1 means all entries).args
- [14] The number of entries to skip (-1 or 0 means no skipping).args
- [15] The number of events to commit in one step (-1 means commit only at the end).args
- [16] Whether remove allVertex
es with the define label before populating or check for each one and only create it if it doesn't exist yet.args
- [17] Whether check the existence of the vertex before creating it. (Index-based verification is disabled for speed.)args
- [18] Whether fill all variables or just rowkey and lbl. Overrides partialFill.args
- [19] List of (coma separated) HBase columns to fill besides the default column.args
- [20] List of (coma separated) geopoint property name and HBase columns representing lat and long in deg.- Throws:
LomikelException
- If anything goes wrong.Exception
-
populateGraphFromHBase
public String populateGraphFromHBase(String hbaseHost, int hbasePort, String hbaseTable, String tableSchema, String label, String rowkey, String keyPrefixSearch, String keyStart, String keyStop, long start, long stop, int limit, int skip, int commitLimit, boolean reset, boolean getOrCreate, boolean fullFill, String partialFill, String geopoint) throws LomikelException Populate JanusGraph from HBase table.- Parameters:
hbaseHost
- The HBase hostname.hbasePort
- The HBase port.hbaseTable
- The HBase table to replicate in Graph.tableSchema
- The HBase table schema name.label
- The label of newly created Vertexes.rowkey
- The row key name.keyPrefixSearch
- The key prefix to limit replication to.keyStart
- The key to start search from, may be blank.keyStop
- The key to stop search at, may be blank.start
- The time start search from (in ms), may be 0.stop
- The time stop search at (in ms), may be 0.limit
- The maximal number of entries to process (-1 means all entries).skip
- The number of entries to skip (-1 or 0 means no skipping).commitLimit
- The number of events to commit in one step (-1 means commit only at the end).reset
- Whether remove allVertex
es with the define label before populating or check for each one and only create it if it doesn't exist yet.getOrCreate
- Whether check the existence of the vertex before creating it. (Index-based verification is disabled for speed.)fullFill
- Whether fill all variables or just rowkey and lbl. Overrides partialFill.partialFill
- List of (coma separated) HBase columns to fill besides the default column.geopoint
- List of (coma separated) geopoint property name and HBase columns representing lat and long in deg.- Returns:
- Blank if the population has been executed correctly, the last sucessfull key otherwise.
- Throws:
LomikelException
- If anything goes wrong.
-