Class DataSourceOptions
java.lang.Object
com.complexible.stardog.virtual.api.DataSourceOptions
Options shared by data sources of all types.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classA parsed foreign key declaration: the child table, the parent table, and the column pairs (child→parent). -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final StringThe option to define the limit for data source query results.static final intThe default batch size used for queries with batchesstatic final intThe default limit used for data source queries.static final StringUser-provided foreign key declarations.static final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringSecrets Management Integrationstatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic intgetBatchSize(Properties options) getForeignKeySets(Properties options) Parses theFOREIGN_KEY_SETSoption.getUniqueKeySets(Properties options) Returns the parsed value of theUNIQUE_KEY_SETSoption.getUniqueKeySets(Properties options, Function<String, Pair<String, String>> splitTableColumn) Parses theUNIQUE_KEY_SETSoption using the providedFunctionto split a table and column string into a Pair.
-
Field Details
-
DEFAULT_RESULT_LIMIT
public static final int DEFAULT_RESULT_LIMITThe default limit used for data source queries.- See Also:
-
DEFAULT_BATCH_SIZE
public static final int DEFAULT_BATCH_SIZEThe default batch size used for queries with batches- See Also:
-
DATA_SOURCE_QUERY_RESULT_LIMIT
The option to define the limit for data source query results. Data source query results are kept in-memory so it is not recommended to set this limit to a high value.- See Also:
-
UNIQUE_KEY_SETS
- See Also:
-
FOREIGN_KEY_SETS
User-provided foreign key declarations. Each foreign key is a parenthesized list ofchild_table.column->parent_table.columnpairs. Multiple foreign keys are separated by commas.(CHILD_SCHEMA.CHILD_TABLE.COL1->PARENT_SCHEMA.PARENT_TABLE.COL1) (CHILD.COL1->PARENT.COL1,CHILD.COL2->PARENT.COL2)
- See Also:
-
BATCH_SIZE
- See Also:
-
SECRETS_MANAGER
Secrets Management Integration- See Also:
-
SECRETS_KEY
- See Also:
-
SECRETS_VERSION
- See Also:
-
SECRETS_AWS_REGION
- See Also:
-
SECRETS_AWS_SECRET_KEY
- See Also:
-
SECRETS_AWS_ACCESS_KEY
- See Also:
-
SECRETS_GOOGLE_PROJECT_ID
- See Also:
-
SECRETS_GOOGLE_KEY
- See Also:
-
SECRETS_AZURE_URL
- See Also:
-
SECRETS_AZURE_TENANT_ID
- See Also:
-
SECRETS_AZURE_CLIENT_ID
- See Also:
-
SECRETS_AZURE_CLIENT_SECRET
- See Also:
-
SECRETS_HASHICORP_VAULT_URL
- See Also:
-
SECRETS_HASHICORP_VAULT_TOKEN
- See Also:
-
-
Constructor Details
-
DataSourceOptions
public DataSourceOptions()
-
-
Method Details
-
getUniqueKeySets
Returns the parsed value of theUNIQUE_KEY_SETSoption. Takes String of unique keys, grouped by parentheses, delimited by commas and a returns a Map from each referenced table to the set of key sets. Uses default function that splits table and column on last dot. e.g.:("Table1"."Column1"), ("Table1"."Column3", "Table1"."Column4"), (mongocol.[unwind1;unwind2].unwind1.field1)is parsed to:{""Table1"" : [[""Column1""], [""Column3"", ""Column4""]]}, {"mongocol.[unwind1;unwind2]" : [["unwind1.field1"]]} -
getUniqueKeySets
public static Map<String,Set<Set<String>>> getUniqueKeySets(Properties options, Function<String, Pair<String, String>> splitTableColumn) Parses theUNIQUE_KEY_SETSoption using the providedFunctionto split a table and column string into a Pair. See:getUniqueKeySets(Properties) -
getBatchSize
-
getForeignKeySets
Parses theFOREIGN_KEY_SETSoption. Format:(child_table.col->parent_table.col, child_table.col2->parent_table.col2)Multiple FKs are in separate parenthesized groups.- Returns:
- list of foreign key declarations, or null if the option is not set
-