Hello! Commit 23d9ad77181 added additional length checks for tsvector, but it is inconsistent at one place: most checks use toklen > MAXSTRLEN as the error condition, but array_to_tsvector uses >=. This causes a strange corner-case issue: we can convert a 2047 length lexeme to an array, as tsvector_to_array allows it, but we can't convert it back with array_to_tsvector as it errors out.
0001 is a fix for this specific case. After looking into this further, I realized that the length handling is also inconsistent at other places, even before the mentioned commit. 0002 addresses the other preexisting places that used >= for errors instead of >
0001-Allow-maximum-length-lexemes-in-array_to_tsvector-ag.patch
Description: Binary data
0002-Accept-maximum-length-lexemes-in-all-text-search-inp.patch
Description: Binary data
