prestodb/presto · error · IllegalArgumentException
Invalid property tpcds.splits-per-node
Error message
Invalid property tpcds.splits-per-node
What it means
TpcdsConnectorFactory.getSplitsPerNode() parses the tpcds.splits-per-node catalog property, defaulting when absent. A non-integer value causes parseInt to throw NumberFormatException, which is rethrown as IllegalArgumentException("Invalid property tpcds.splits-per-node"). This fails connector creation so a bad catalog config is caught at startup.
Source
Thrown at presto-tpcds/src/main/java/com/facebook/presto/tpcds/TpcdsConnectorFactory.java:128
@Override
public ConnectorCodecProvider getConnectorCodecProvider()
{
return new ThriftCodecProvider.Builder().setThriftCodecManager(new ThriftCodecManager())
.setConnectorSplitType(TpcdsSplit.class)
.setConnectorTransactionHandle(TpcdsTransactionHandle.class)
.setConnectorTableLayoutHandle(TpcdsTableLayoutHandle.class)
.setConnectorTableHandle(TpcdsTableHandle.class).build();
}
};
}
private int getSplitsPerNode(Map<String, String> properties)
{
try {
return parseInt(firstNonNull(properties.get("tpcds.splits-per-node"), String.valueOf(defaultSplitsPerNode)));
}
catch (NumberFormatException e) {
throw new IllegalArgumentException("Invalid property tpcds.splits-per-node");
}
}
private boolean useVarcharType(Map<String, String> properties)
{
try {
return parseBoolean(firstNonNull(properties.get("tpcds.use-varchar-type"), String.valueOf(false)));
}
catch (NumberFormatException e) {
throw new IllegalArgumentException("Invalid property tpcds.use-varchar-type");
}
}
private boolean isWithNoSexism(Map<String, String> properties)
{
return parseBoolean(firstNonNull(properties.get("tpcds.with-no-sexism"), String.valueOf(false)));
}
}View on GitHub (pinned to 55bb57d202)
Solutions
- Set tpcds.splits-per-node to a plain integer (e.g., tpcds.splits-per-node=4) in the catalog properties
- Remove the property entirely to use the default
- Check for hidden whitespace/quotes or unresolved template variables in the properties file
Example fix
// before
tpcds.splits-per-node=${SPLITS_PER_NODE} # unresolved template -> IllegalArgumentException
// after
tpcds.splits-per-node=8 Defensive patterns
Strategy: validation
Validate before calling
String raw = properties.get("tpcds.splits-per-node");
if (raw != null && !raw.matches("\\d+")) {
throw new IllegalArgumentException("tpcds.splits-per-node must be an integer, got: " + raw);
} Prevention
- Keep numeric catalog properties as bare integers without units or quotes
- Grep catalog properties for unresolved ${...} templates before deploy
- Parse-validate all catalog properties at config load time in tests
When it happens
Trigger: Catalog properties contain tpcds.splits-per-node set to a non-numeric string (e.g., "ten", "1.5", or a value with stray whitespace/units).
Common situations: Hand-edited catalog properties; templating mistakes leaving placeholder text like ${SPLITS}; units accidentally appended to the number; copy-paste from docs with wrong value.
Related errors
- `tpcds.use-varchar-type` config property is not true for a n
- Invalid property tpcds.use-varchar-type
- ACCUMULO_TABLE_EXISTS
- UNEXPECTED_ACCUMULO_ERROR
- NOT_SUPPORTED
AI-assisted analysis of prestodb/presto@55bb57d202 (2026-09-04).
Data as JSON: /api/errors/460a61409d443b55.
Report an issue: GitHub.