Skip to content

AxonOps — AI-Native Control Plane for Open Source Data Platforms

nodetool getguardrailsconfig

Cassandra 5.0+

This command is available in Cassandra 5.0 and later.

Displays the current guardrails configuration.


Terminal window
nodetool [connection_options] getguardrailsconfig [options] [guardrail_name]

See connection options for connection options.

OptionDescription
-c, --category <category>Filter output by category: values, thresholds, flags, others
--expandShow expanded details for each guardrail
ArgumentDescription
guardrail_nameOptional. Show configuration for a specific guardrail only

nodetool getguardrailsconfig displays the current guardrails configuration for the node. Guardrails are protective limits that prevent potentially harmful operations in Cassandra, such as creating too many tables, using dangerous query patterns, or exceeding safe data sizes.

Guardrails help maintain cluster stability by enforcing best practices and preventing operations that could lead to performance degradation or outages.


The guardrails are organized into the following categories:

CategoryDescription
valuesNumeric limit values (warn/fail thresholds)
thresholdsSize and count thresholds
flagsBoolean enable/disable settings
othersOther guardrail configurations
SettingDescription
tables_warn_thresholdWarning when table count exceeds this
tables_fail_thresholdReject operations when table count exceeds this
columns_per_table_warn_thresholdWarning for columns per table
columns_per_table_fail_thresholdRejection for columns per table
SettingDescription
page_size_warn_thresholdWarning for large page sizes
page_size_fail_thresholdRejection for excessive page sizes
in_select_cartesian_product_warn_thresholdWarning for IN clause combinations
in_select_cartesian_product_fail_thresholdRejection for IN clause combinations
SettingDescription
collection_size_warn_thresholdWarning for large collections
collection_size_fail_thresholdRejection for excessive collections
items_per_collection_warn_thresholdWarning for collection item count
items_per_collection_fail_thresholdRejection for collection item count
SettingDescription
partition_keys_in_select_warn_thresholdWarning for partition keys in SELECT
partition_keys_in_select_fail_thresholdRejection for partition keys in SELECT

Terminal window
nodetool getguardrailsconfig

Sample output:

Guardrails Configuration:
Tables:
Warn Threshold: 100
Fail Threshold: 150
Columns Per Table:
Warn Threshold: 50
Fail Threshold: 100
Page Size:
Warn Threshold: 5000
Fail Threshold: 10000
Collection Size:
Warn Threshold: 65536
Fail Threshold: -1 (disabled)
...

Terminal window
# Check current guardrail configuration
nodetool getguardrailsconfig

Review guardrails when:

  • Planning schema changes
  • Debugging query rejections
  • Auditing cluster configuration
  • Onboarding new development teams
Terminal window
# Check limits before creating tables
nodetool getguardrailsconfig | grep -i table

Verify guardrail limits before operations that might be affected.

Terminal window
# Check if queries are hitting guardrails
nodetool getguardrailsconfig

When queries fail with guardrail errors, check current thresholds to understand the limits.


  • Warn threshold: Logs a warning but allows the operation
  • Fail threshold: Rejects the operation with an error

A value of -1 typically indicates the guardrail is disabled.

Schema Guardrails:

  • Number of tables per keyspace
  • Columns per table
  • Secondary indexes per table
  • Materialized views per table

Query Guardrails:

  • Page size limits
  • IN clause restrictions
  • ALLOW FILTERING controls
  • Partition scan limits

Data Guardrails:

  • Collection sizes
  • Partition sizes
  • Column value sizes
  • TTL settings

Guardrail Strategy

  1. Use warn thresholds - Enable warnings before hard failures to catch issues early
  2. Document limits - Ensure developers understand guardrail boundaries
  3. Monitor warnings - Set up alerts for guardrail warnings
  4. Review periodically - Adjust thresholds based on operational experience

When to Adjust Guardrails

Consider modifying guardrails when:

  • Legitimate use cases exceed defaults
  • Stricter controls are needed for multi-tenant environments
  • Specific applications have validated requirements

Guardrail Considerations

  • Guardrails exist to protect cluster stability
  • Relaxing limits should be done cautiously
  • Test thoroughly before changing production guardrails
  • Some guardrails affect existing data operations, not just new writes

Guardrails can also be configured in cassandra.yaml:

guardrails:
tables_warn_threshold: 100
tables_fail_threshold: 150
columns_per_table_warn_threshold: 50
columns_per_table_fail_threshold: 100
# ... additional settings

CommandRelationship
setguardrailsconfigModify guardrail settings
describeclusterCluster configuration overview
infoNode information