The default LONGTEXT column length is incompatible with the TiPB message.
Open
component/ddl
type/bug
- Dominant language
- Go
- Stars
- 40.5k
- Forks
- 6.2k
- PR merge metrics
- PR metrics pending
Description
DDL sets the default column length for the `LONGTEXT` data type to [4,294,967,295](https://github.com/pingcap/tidb/blob/master/pkg/parser/mysql/util.go#L21-L49), which does not fit the `int32` field `column_length` defined in TiPB’s [schema.proto](https://github.com/pingcap/tipb/blob/9fd33ded6f2c94633e601104cde26f2bdb5147d5/proto/schema.proto#L28). Since TiCI follows the `int32` definition from TiPB, this causes a serialization error in TiCI.
In addition, according to the `LONGTEXT` [documentation](https://docs.pingcap.com/zh/tidb/stable/data-type-string/), its maximum practical length cannot exceed approximately 120 MB.
Contributor guide
Assessment
This issue has not been assessed yet.