Commit ca09149
committed
fix(database): keep single-attribute indexes under MariaDB 768-byte limit
- hostname column 1024 -> 255. DNS hostnames are capped at 253 chars, so
the wider size never gained anything but pushed the bloom_filter index
past the InnoDB/utopia-php-database 768-byte single-attribute index
prefix limit.
- path column stays at 1024 for data fidelity (URLs with signed query
strings exceed 255), but its index entry now uses an explicit
lengths=[255] so MariaDB only indexes the first 255 chars. The index
validator in utopia/database treats lengths[i] as the indexLength when
set, taking the column under the 768 cap while preserving the full
column for stored data.
Caught by CI when the full Database adapter suite ran against MariaDB —
local runs skipped 45 DatabaseTest cases because pdo_mysql wasn't loaded.
Verified locally now via docker-compose: 195/195 passing.1 parent 3639dc9 commit ca09149
1 file changed
Lines changed: 15 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
617 | 617 | | |
618 | 618 | | |
619 | 619 | | |
620 | | - | |
| 620 | + | |
621 | 621 | | |
622 | 622 | | |
623 | 623 | | |
| |||
721 | 721 | | |
722 | 722 | | |
723 | 723 | | |
724 | | - | |
725 | | - | |
726 | | - | |
727 | | - | |
728 | | - | |
| 724 | + | |
| 725 | + | |
| 726 | + | |
| 727 | + | |
| 728 | + | |
| 729 | + | |
| 730 | + | |
| 731 | + | |
| 732 | + | |
| 733 | + | |
| 734 | + | |
| 735 | + | |
| 736 | + | |
| 737 | + | |
729 | 738 | | |
730 | 739 | | |
731 | 740 | | |
| |||
0 commit comments