UCS2 to UTF8MB4 Encoding error
Los mantenedores suelen responder en 10 días
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 25/100
- Tipo de issue
- Error
- Claridad
- Necesita aclaración
- Estado de actividad
- Estancado
- Stack tecnológico
- mysql
- Área
- database
Línea de trabajo
Reproduce una migración en línea que involucre UCS2 y UTF8MB4; después, inspecciona cómo se insertan o actualizan en la tabla gho las filas leídas del binlog. Compara los bytes almacenados y los valores de los caracteres antes y después de la conversión. Se considera terminado cuando los caracteres equivalentes siguen representándose correctamente sin requerir sentencias UPDATE manuales.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Not sure if this is expected for fixed-length to variable length charset conversions but for rows read from the binlog into the gho table during the migration, the utility does not do an equivalent character conversion, it just uses the bytes given with the new charset. I could see why this behavior might make sense (charsets may not necessarily have truly equivalent representations of the same displayed character?) and is a skill issue in my part but in case this is not expected behavior, the example I saw during my migration was as follows:
"M" in UCS2: 0x004D
"M" in UTF8MB4: 0x4D
I am in the process of fixing it in my DB by running UPDATE statements in the format:
{column} = IF(CAST({column} AS BINARY) LIKE CONCAT(0x00, '%'), CONVERT(CONVERT(CAST({column} AS BINARY) USING UCS2), USING UTF8MB4), {column})
With some appropriate filters to not have to attempt to update every row of the new table of course. Is this something that gh-ost should handle itself? I think the format above allows specifically UCS2 to UTF8, if it were ran against the gho table rows upon insertion/update from the binlog but it's probably not portable outside this specific case.
Either way, this is a fantastic tool and I really appreciate that you all made this. Thanks
- Lenguaje dominante
- Go
- Estrellas
- 13.6k
- Forks
- 1.4k
- Merge medio
- 9 d 19 h
- PR fusionados (30 d)
- 1
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de github/gh-ost
-
`--resume` without `--execute` drops the ghost table it correctly skipped alteringPosiblemente ocupada @ajm188 la tomó hace 55 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 86/100
Los mantenedores suelen responder en 10 días
-
[Suggestion] Apply simple validation to alter commandPosiblemente ocupada @drkemp187 la tomó hace 106 días. Abiertoenhancement good first issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 64/100
github/gh-ost#1431 · 4 comentarios ·
Los mantenedores suelen responder en 10 días
-
Migration hangs when --attempt-instant-ddl succeedsPosiblemente ocupada Un pull request vinculado a esta issue está abierto o ya se fusionó. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 30/100
Los mantenedores suelen responder en 10 días
-
Dificultad 4/5 3-5 días Aptitud para principiantes 42/100
Los mantenedores suelen responder en 10 días
-
Atomic cut-over always fails on MySQL 9.1+: information_schema.processlist errors out (3854) while another session runs a non-BMP utf8mb4 statementPosiblemente ocupada Un pull request vinculado a esta issue está abierto o ya se fusionó. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 52/100
github/gh-ost#1780 · 1 comentario ·
Los mantenedores suelen responder en 10 días
Todos los issues de github/gh-ost
Issues similares
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
prime-radiant-inc/evener#6325 ·
Los mantenedores suelen responder en 1 día
-
team:library-maintainers
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
padok-team/burrito#1208 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
bazel-contrib/rules_go#4784 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
betterleaks/betterleaks#484 ·
Los mantenedores suelen responder en 1 día