influxdb/influxdb3
Trevor Hilton 5395b197bb
fix: validate tag and field names when creating tables (#26641)
* fix: validate tag and field names when creating tables

Add validation to ensure tag and field names follow line protocol rules
when creating tables via the catalog API. This prevents creating tables
with invalid column names that would be rejected by the line protocol
parser.

The validation checks that tag and field names:
- Are not empty
- Do not contain spaces
- Do not contain commas
- Do not contain equals signs

Closes #26486

* test: add tests for tag and field name validation

Add unit tests using rstest to verify that the create_table method
properly validates tag and field names according to line protocol rules.

The tests cover:
- Invalid cases: empty names
- Valid cases: simple names, underscores, numbers, and mixed alphanumeric
- Valid cases with escapes
- Verification that tables are created correctly with valid names

This ensures the validation added in the previous commit works as expected.

* test: cli integration test to verify tag/field name rules

* feat: reject control characters in tag/field keys
2025-07-30 12:32:59 -04:00
..
src feat: introduce TableIndexSnapshot, TableIndex, and TableIndexCache (#26636) 2025-07-28 13:23:56 -06:00
tests fix: validate tag and field names when creating tables (#26641) 2025-07-30 12:32:59 -04:00
Cargo.toml refactor: split into binary and library targets (#26521) 2025-06-16 11:37:29 -06:00