#At file:///home/msvensson/mysql/7.0/ based on revid:ole.john.aske@stripped
4120 Magnus Blåudd 2011-01-17
ndb
- backport patch from 5.5 for printing the error message and warning list
when the schema distribution fails to discover
modified:
sql/ha_ndbcluster_binlog.cc
=== modified file 'sql/ha_ndbcluster_binlog.cc'
--- a/sql/ha_ndbcluster_binlog.cc 2011-01-14 14:37:28 +0000
+++ b/sql/ha_ndbcluster_binlog.cc 2011-01-17 13:02:03 +0000
@@ -1650,6 +1650,19 @@ struct Cluster_schema
uint32 any_value;
};
+static void
+print_could_not_discover_error(THD *thd,
+ const Cluster_schema *schema)
+{
+ sql_print_error("NDB Binlog: Could not discover table '%s.%s' from "
+ "binlog schema event '%s' from node %d. "
+ "my_errno: %d",
+ schema->db, schema->name, schema->query,
+ schema->node_id, my_errno);
+ print_warning_list("NDB Binlog", thd_warn_list(thd));
+}
+
+
/*
Transfer schema table data into corresponding struct
*/
@@ -2803,12 +2816,7 @@ ndb_binlog_thread_handle_schema_event(TH
}
else if (ndb_create_table_from_engine(thd, schema->db, schema->name))
{
- sql_print_error("NDB Binlog: Could not discover table '%s.%s' from "
- "binlog schema event '%s' from node %d. "
- "my_errno: %d",
- schema->db, schema->name, schema->query,
- schema->node_id, my_errno);
- print_warning_list("NDB Binlog", thd_warn_list(thd));
+ print_could_not_discover_error(thd, schema);
}
mysql_mutex_unlock(&LOCK_open);
log_query= 1;
@@ -3181,11 +3189,7 @@ ndb_binlog_thread_handle_schema_event_po
}
else if (ndb_create_table_from_engine(thd, schema->db, schema->name))
{
- sql_print_error("NDB Binlog: Could not discover table '%s.%s' from "
- "binlog schema event '%s' from node %d. my_errno: %d",
- schema->db, schema->name, schema->query,
- schema->node_id, my_errno);
- print_warning_list("NDB Binlog", thd_warn_list(thd));
+ print_could_not_discover_error(thd, schema);
}
mysql_mutex_unlock(&LOCK_open);
}
@@ -3360,11 +3364,7 @@ ndb_binlog_thread_handle_schema_event_po
}
else if (ndb_create_table_from_engine(thd, schema->db, schema->name))
{
- sql_print_error("NDB Binlog: Could not discover table '%s.%s' from "
- "binlog schema event '%s' from node %d. my_errno: %d",
- schema->db, schema->name, schema->query,
- schema->node_id, my_errno);
- print_warning_list("NDB Binlog", thd_warn_list(thd));
+ print_could_not_discover_error(thd, schema);
}
mysql_mutex_unlock(&LOCK_open);
}
Attachment: [text/bzr-bundle] bzr/magnus.blaudd@oracle.com-20110117130203-0zirrd5m5fdfy0mx.bundle
| Thread |
|---|
| • bzr commit into mysql-5.1-telco-7.0 branch (magnus.blaudd:4120) | Magnus Blåudd | 17 Jan |