Class CalciteSystemProperty<T>
- Type Parameters:
T
- the type of the property value
Calcite system properties must always be in the "calcite" root namespace.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final CalciteSystemProperty<Boolean>
Whether the optimizer will consider adding converters of infinite cost in order to convert a relational expression from one calling convention to another.static final CalciteSystemProperty<Integer>
The concurrency level of the cache used for storing Bindable objects, instantiated via dynamically generated Java classes.static final CalciteSystemProperty<Integer>
The maximum size of the cache used for storing Bindable objects, instantiated via dynamically generated Java classes.static final CalciteSystemProperty<Boolean>
Whether to exploit join commutative property.static final CalciteSystemProperty<Boolean>
Whether to run Calcite in debug mode.static final CalciteSystemProperty<String>
The name of the default character set.static final CalciteSystemProperty<String>
The name of the default collation.static final CalciteSystemProperty<String>
The strength of the default collation.static final CalciteSystemProperty<String>
The name of the default national character set.static final CalciteSystemProperty<Boolean>
Whether to include a GraphViz representation when dumping the state of the Volcano planner.static final CalciteSystemProperty<Boolean>
Whether to includeRelSet
information when dumping the state of the Volcano planner.static final CalciteSystemProperty<Boolean>
Whether to enable the collation trait in the default planner configuration.static final CalciteSystemProperty<Boolean>
Whether the enumerable convention is enabled in the default planner configuration.static final CalciteSystemProperty<Boolean>
Whether RexNode digest should be normalized (e.g.static final CalciteSystemProperty<Boolean>
Whether streaming is enabled in the default planner configuration.static final CalciteSystemProperty<Boolean>
Whether the EnumerableTableScan should support ARRAY fields.static final CalciteSystemProperty<Boolean>
Whether the EnumerableTableScan should support MAP fields.static final CalciteSystemProperty<Boolean>
Whether the EnumerableTableScan should support MULTISET fields.static final CalciteSystemProperty<Integer>
The maximum number of items in a function-level cache.static final CalciteSystemProperty<Boolean>
Whether to run integration tests.static final CalciteSystemProperty<Integer>
Minimum numbers of fields in a Join result that will trigger the "compact code generation".static final CalciteSystemProperty<Integer>
The maximum size of the cache of metadata handlers.static final CalciteSystemProperty<Boolean>
Whether to follow the SQL standard strictly.static final CalciteSystemProperty<Boolean>
Whether to run Arrow tests.static final CalciteSystemProperty<Boolean>
Whether to run Cassandra tests.static final CalciteSystemProperty<String>
Path to the dataset file that should used for integration tests.static final CalciteSystemProperty<String>
Which database to use for tests that require a JDBC data source.static final CalciteSystemProperty<Boolean>
Whether to run Druid tests.static final CalciteSystemProperty<@Nullable String>
A list of ids designating the queries (from query.json in new.hydromatic:foodmart-queries:0.4.1) that should be run as part of FoodmartTest.static final CalciteSystemProperty<Boolean>
Whether to run InnoDB tests.static final CalciteSystemProperty<Boolean>
Whether to run MongoDB tests.static final CalciteSystemProperty<Boolean>
Whether to run Redis tests.static final CalciteSystemProperty<Boolean>
Whether to run Splunk tests.static final CalciteSystemProperty<Boolean>
Whether to use Docker containers in tests.static final CalciteSystemProperty<Boolean>
Whether to enable top-down optimization. -
Method Summary
-
Field Details
-
DEBUG
Whether to run Calcite in debug mode.When debug mode is activated significantly more information is gathered and printed to STDOUT. It is most commonly used to print and identify problems in generated java code. Debug mode is also used to perform more verifications at runtime, which are not performed during normal execution.
-
COMMUTE
Whether to exploit join commutative property. -
ENABLE_COLLATION_TRAIT
Whether to enable the collation trait in the default planner configuration.Some extra optimizations are possible if enabled, but queries should work either way. At some point this will become a preference, or we will run multiple phases: first disabled, then enabled.
-
ENABLE_ENUMERABLE
Whether the enumerable convention is enabled in the default planner configuration. -
ENUMERABLE_ENABLE_TABLESCAN_ARRAY
Whether the EnumerableTableScan should support ARRAY fields. -
ENUMERABLE_ENABLE_TABLESCAN_MAP
Whether the EnumerableTableScan should support MAP fields. -
ENUMERABLE_ENABLE_TABLESCAN_MULTISET
Whether the EnumerableTableScan should support MULTISET fields. -
ENABLE_STREAM
Whether streaming is enabled in the default planner configuration. -
ENABLE_REX_DIGEST_NORMALIZE
Whether RexNode digest should be normalized (e.g. call operands ordered).Normalization helps to treat $0=$1 and $1=$0 expressions equal, thus it saves efforts on planning.
-
STRICT
Whether to follow the SQL standard strictly. -
DUMP_GRAPHVIZ
Whether to include a GraphViz representation when dumping the state of the Volcano planner. -
DUMP_SETS
Whether to includeRelSet
information when dumping the state of the Volcano planner. -
TOPDOWN_OPT
Whether to enable top-down optimization. This config can be overridden byCalciteConnectionProperty.TOPDOWN_OPT
.Note: Enabling top-down optimization will automatically disable the use of AbstractConverter and related rules.
-
INTEGRATION_TEST
Whether to run integration tests. -
TEST_DB
Which database to use for tests that require a JDBC data source.The property can take one of the following values:
- HSQLDB (default)
- H2
- MYSQL
- ORACLE
- POSTGRESQL
If the specified value is not included in the previous list, the default is used.
We recommend that casual users use hsqldb, and frequent Calcite developers use MySQL. The test suite runs faster against the MySQL database (mainly because of the 0.1 second versus 6 seconds startup time). You have to populate MySQL manually with the foodmart data set, otherwise there will be test failures.
-
TEST_DATASET_PATH
Path to the dataset file that should used for integration tests.If a path is not set, then one of the following values will be used:
- ../calcite-test-dataset
- ../../calcite-test-dataset
- .
-
TEST_ARROW
Whether to run Arrow tests. -
TEST_MONGODB
Whether to run MongoDB tests. -
TEST_SPLUNK
Whether to run Splunk tests.Disabled by default, because we do not expect Splunk to be installed and populated with the data set necessary for testing.
-
TEST_DRUID
Whether to run Druid tests. -
TEST_CASSANDRA
Whether to run Cassandra tests. -
TEST_INNODB
Whether to run InnoDB tests. -
TEST_REDIS
Whether to run Redis tests. -
TEST_WITH_DOCKER_CONTAINER
Whether to use Docker containers in tests.If the property is set to
true
, affected tests will attempt to start Docker containers; when Docker is not available tests fallback to other execution modes and if it's not possible they are skipped entirely.If the property is set to
false
, Docker containers are not used at all and affected tests either fallback to other execution modes or skipped entirely.Users can override the default behavior to force non-Dockerized execution even when Docker is installed on the machine; this can be useful for replicating an issue that appears only in non-docker test mode or for running tests both with and without containers in CI.
-
TEST_FOODMART_QUERY_IDS
A list of ids designating the queries (from query.json in new.hydromatic:foodmart-queries:0.4.1) that should be run as part of FoodmartTest. -
ALLOW_INFINITE_COST_CONVERTERS
Whether the optimizer will consider adding converters of infinite cost in order to convert a relational expression from one calling convention to another. -
DEFAULT_CHARSET
The name of the default character set.It is used by
SqlValidator
. -
DEFAULT_NATIONAL_CHARSET
The name of the default national character set.It is used with the N'string' construct in
SqlLiteral
and may be different from theDEFAULT_CHARSET
. -
DEFAULT_COLLATION
The name of the default collation.It is used in
SqlCollation
andSqlLiteral
. -
DEFAULT_COLLATION_STRENGTH
The strength of the default collation. Allowed values (as defined inCollator
) are: primary, secondary, tertiary, identical.It is used in
SqlCollation
andSqlLiteral
. -
METADATA_HANDLER_CACHE_MAXIMUM_SIZE
The maximum size of the cache of metadata handlers.A typical value is the number of queries being concurrently prepared multiplied by the number of types of metadata.
If the value is less than 0, there is no limit.
-
BINDABLE_CACHE_MAX_SIZE
The maximum size of the cache used for storing Bindable objects, instantiated via dynamically generated Java classes.The default value is 0.
The property can take any value between [0,
Integer.MAX_VALUE
] inclusive. If the value is not valid (or not specified) then the default value is used.The cached objects may be quite big so it is suggested to use a rather small cache size (e.g., 1000). For the most common use cases a number close to 1000 should be enough to alleviate the performance penalty of compiling and loading classes.
Setting this property to 0 disables the cache.
-
BINDABLE_CACHE_CONCURRENCY_LEVEL
The concurrency level of the cache used for storing Bindable objects, instantiated via dynamically generated Java classes.The default value is 1.
The property can take any value between [1,
Integer.MAX_VALUE
] inclusive. If the value is not valid (or not specified) then the default value is used.This property has no effect if the cache is disabled (i.e.,
BINDABLE_CACHE_MAX_SIZE
set to 0. -
FUNCTION_LEVEL_CACHE_MAX_SIZE
The maximum number of items in a function-level cache.A few SQL functions have expensive processing that, if its results are cached, can be reused by future calls to the function. One such function is
RLIKE
, whose arguments are a regular expression and a string. The regular expression needs to be compiled to aPattern
. Compilation is expensive, and within a particular query, the arguments are often the same string, or a small number of distinct strings, so caching makes sense.Therefore, functions such as
RLIKE
,SIMILAR TO
,PARSE_URL
,PARSE_TIMESTAMP
,FORMAT_DATE
have a function-level cache. The cache is created in the code generated for the query, at the call site of the function, and expires when the query has finished executing. Such caches do not need time-based expiration, but we need to cap the size of the cache to deal with scenarios such as a billion-row table where every row has a distinct regular expression.Because of how Calcite generates and executes code in Enumerable convention, each function object is used from a single thread. Therefore, non thread-safe objects such as
DateFormat
can be safely cached.The value of this parameter limits the size of every function-level cache in Calcite. The default value is 1,000.
-
JOIN_SELECTOR_COMPACT_CODE_THRESHOLD
Minimum numbers of fields in a Join result that will trigger the "compact code generation". This feature reduces the risk of running into a compilation error due to the code of a dynamically generated method growing beyond the 64KB limit.Note that the compact code makes use of arraycopy operations when possible, instead of using a static array initialization. For joins with a large number of fields the resulting code should be faster, but it can be slower for joins with a very small number of fields.
The default value is 100, a negative value disables completely the "compact code" feature.
- See Also:
-
-
Method Details
-
value
Returns the value of this property.- Returns:
- the value of this property or
null
if a default value has not been defined for this property.
-