[ 
https://issues.apache.org/jira/browse/CASSANDRA-17499?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17514616#comment-17514616
 ] 

Andres de la Peña commented on CASSANDRA-17499:
-----------------------------------------------

Guardrails can be disabled both individually and globally. The global flag is 
disabled by default, and all the new guardrails that have been recently added 
are also individually disabled:
{code:java}
guardrails_enabled: false
keyspaces_warn_threshold: -1
keyspaces_fail_threshold: -1
tables_warn_threshold: -1
tables_fail_threshold: -1
{code}
The problem comes when we try to migrate existing properties to guardrails. 
Those properties can have a default value, so they are not disabled, for 
example:
{code:java}
tombstone_warn_threshold: 1000
tombstone_failure_threshold: 100000
{code}
If we transform those properties into guardrails they would be subjected to the 
{{guardrails_enabled}} flag. Since that flag is disabled by default, they would 
become disabled, breaking compatibility with previous releases where it was 
enabled by default.

Some options to deal with this are:
 # Do not migrate properties until the next major.
 # Set {{guardrails_enabled}} to true by default.
 # Get rid of {{{}guardrails_enabled{}}}, as it's proposed here.
 # Have two type of guardrails, those using the global enable flag and those 
not using it. That feels like overcomplicating things.

The main reason to have that global flag was to provide a set of aggressive, 
opinionated defaults for every individual guardrail, and then disable them by 
default with the global flag. That way, one could choose to drive with or 
without the entire set of recommended guardrails. However, we don't have that 
set of recommended defaults and, instead, every guardrail is disabled by 
default, so currently the global flag doesn't add that much value.

 

> Remove global Guardrails Enable flag
> ------------------------------------
>
>                 Key: CASSANDRA-17499
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-17499
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Feature/Guardrails
>            Reporter: Savni Nagarkar
>            Assignee: Savni Nagarkar
>            Priority: Normal
>             Fix For: 4.x
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> This ticket removes the global Guardrails enable flag. Currently the flag 
> turns all Guardrails on and off regardless of the individual setting of the 
> guardrail property. This presents a problem for maximum replication factor 
> and minimum replication factor configurations which will soon be moved to 
> guardrails. Those configurations will always need to be enabled so no 
> problems arise as Cassandra users create keyspaces. This ensures all 
> Guardrail properties follow the same enable / disable procedure.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org
For additional commands, e-mail: commits-h...@cassandra.apache.org

Reply via email to