-
Notifications
You must be signed in to change notification settings - Fork 557
Description
I'm loading my rails structure.sql file via the mysql2 gem, but the query executes asynchronously, withoutasync: true being specified.
The sql file contains the typical rails content,with the exception of including trigger definitions, resulting in the sequence (CREATE TABLEs... CREATE TRIGGERs... INSERT INTO schema_migrations's).
The connection is established using Mysql2::Client::MULTI_STATEMENTS.
The problem is that when I execute Mysql2::Client#query(), nil is returned immediately, while I can see the sql being executed in the background.
Out of curiosity, I've tried adding async: true and waiting for client.async_result to return some value, but even when the background work was finished, such call was returning nil.
Based on what I see in the gem documentation, this should not happen.
My O/S is an Ubuntu 64 15.10, with the standard libmysqlclient packages installed.
I've tried with the 0.3.17 and 0.4.2, and the behavior is the same.