-
Notifications
You must be signed in to change notification settings - Fork 4k
sql: add table-level max_row_size guardrails #151286
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
sql: add table-level max_row_size guardrails #151286
Conversation
Thank you for contributing to CockroachDB. Please ensure you have followed the guidelines for creating a PR. Before a member of our team reviews your PR, I have some potential action items for you:
I have added a few people who may be able to assist in reviewing: 🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
Your pull request contains more than 1000 changes. It is strongly encouraged to split big PRs into smaller chunks. Thank you for updating your pull request. Before a member of our team reviews your PR, I have some potential action items for you:
🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
f692f8c
to
4727f3e
Compare
Thank you for updating your pull request. Before a member of our team reviews your PR, I have some potential action items for you:
🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
4727f3e
to
4ade614
Compare
Thank you for updating your pull request. Before a member of our team reviews your PR, I have some potential action items for you:
🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf. |
I'll be adding database-level guardrails in separate PR. this PR is ready for review |
Currently, CockroachDB only supports cluster-wide row size guardrails. However, different tables, databases may have different requirements:
Addresses #137518
sql: add table-level row size guardrails
max_row_size_log
: Log a warning when a row exceeds this size (overrides cluster setting)max_row_size_err
: Return an error when a row exceeds this size (overrides cluster setting)CREATE TABLE ... WITH (max_row_size_log = '10MB', max_row_size_err = '50MB');
ALTER TABLE user_profiles SET (max_row_size_log = '10MB', max_row_size_err = '50MB');
Prioritizes guardrails in following order