What happens if I turn off database.mysql.enforce-utf8mb4 ?
-
What are the implications, if any on functionality of fusionauth by setting the
database.mysql.enforce-utf8mb4
property tofalse
? -
Doing so will allow FusionAuth to run even when utf8mb4 is not configured properly. We added that enforcement to ensure the limitation is understood before you turn off the enforcement.
The implication is that if you attempt to store a 4 byte unicode character the INSERT or UPDATE request will fail. The initial MySQL UTF-8 support only allowed for 3 byte characters, they then came out with utf8mb4 to support 4 byte characters.
For example, many emoji are 4 byte characters, so if you tried to store a piece of text with a smiley such as it will fail. The is a four byte character, U+1F601 or \xF0\x9F\x98\x81.
Unless you configure MySQL to use utf8mb4 any character points between U+10000 and U+10FFFF will fail to be stored.
Extracted from https://github.com/FusionAuth/fusionauth-issues/issues/234#issuecomment-632757441