• Alexey Botchkov's avatar
    MDEV-717 LP:1003679 - Wrong binlog order on concurrent DROP schema and CREATE function. · 2783fc7d
    Alexey Botchkov authored
            The cause of the issue is when DROP DATABASE takes
            metadata lock and is in progress through it's
            execution, a concurrently running CREATE FUNCTION checks
            for the existence of database which it succeeds and then it
            waits on the metadata lock.  Once DROP DATABASE writes to
            BINLOG and finally releases the metadata lock on schema
            object, the CREATE FUNCTION waiting on metadata lock
            gets in it's code path and succeeds and writes to binlog.
    2783fc7d
sql_parse.cc 294 KB