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).static classA parsed functional dependency declaration: the table, the determinant columns, and the dependent columns. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final StringPer-data-source override for the server option of the same name, which controls whether Data Catalog automatically registers a metadata provider for a newly added JDBC data source.static final StringThe option to define the limit for data source query results.static final StringUndocumented.static final StringUndocumented.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 StringUser-provided functional dependency 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) static ZoneIdgetDatesTimezoneTarget(Properties options) getForeignKeySets(Properties options) Parses theFOREIGN_KEY_SETSoption.getFunctionalDependencySets(Properties options) Parses theFUNCTIONAL_DEPENDENCY_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.static booleanisDatesTimezoneIgnore(Properties options)
-
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:
-
DATES_TIMEZONE_IGNORE
Undocumented. When true, a date/time literal that carries a time zone no longer fails to translate. Anxsd:date, such asxsd:date(NOW()), is compared by its calendar fields. Anxsd:dateTimeorxsd:dateTimeStamp, such asNOW(), is converted toDATES_TIMEZONE_TARGETand compared without its zone. A workaround until time zone comparisons are pushed faithfully (PLAT-9682).- See Also:
-
DATES_TIMEZONE_TARGET
Undocumented. WithDATES_TIMEZONE_IGNORE, the time zone a zoned dateTime literal is converted to before its zone is dropped: an offset such as-05:00, or a zone ID such asAmerica/New_York, which follows daylight time. Defaults to UTC. Set it to the database session's time zone, which is how most databases compare a zone-less literal with a column that holds instants (PLAT-9682).- 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:
-
FUNCTIONAL_DEPENDENCY_SETS
User-provided functional dependency declarations. Each functional dependency is a parenthesizeddeterminant columns -> dependent columnsdeclaration whose table-qualified columns all reference the same table. Multiple functional dependencies are separated by commas.(SCHEMA.TBL.ORG_ID -> SCHEMA.TBL.ORG_NAME, SCHEMA.TBL.ORG_CITY) (TBL.ORG_ID, TBL.DEPT_CODE -> TBL.DEPT_NAME)
Declares that any two rows agreeing on the determinant columns agree on the dependent columns, with NULL treated as a value. UnlikeUNIQUE_KEY_SETS, the determinant need not be unique in the table. Used to eliminate self-joins over denormalized tables.- See Also:
-
BATCH_SIZE
- See Also:
-
CATALOG_AUTO_ADD_PROVIDERS
Per-data-source override for the server option of the same name, which controls whether Data Catalog automatically registers a metadata provider for a newly added JDBC data source. When this option is absent the server-level value is used.Set it to
falsefor data sources that should never be cataloged, in particular short-lived ones: an auto-added provider outlives the data source it is linked to and its scheduled import fails once the data source is gone. Virtual graph imports set this tofalsefor the temporary data source they create.- 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) -
isDatesTimezoneIgnore
-
getDatesTimezoneTarget
-
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
-
getFunctionalDependencySets
public static List<DataSourceOptions.FunctionalDependencyDeclaration> getFunctionalDependencySets(Properties options) Parses theFUNCTIONAL_DEPENDENCY_SETSoption. Format:(table.det_col, ... -> table.dep_col, ...)Multiple functional dependencies are in separate parenthesized groups.- Returns:
- list of functional dependency declarations, or null if the option is not set
-