Some suggestions:
Jorgen Loland wrote:
...
> +SET SESSION DEBUG='+d,backup_grl_fail';
> +--replace_column 1 #
> +--error ER_BACKUP_SYNCHRONIZE
> +BACKUP DATABASE db1 TO 'overwrite1.bak';
> +SET SESSION DEBUG='-d';
> +
> +--echo
> +
> +SET SESSION DEBUG='+d,backup_grl_block_commit_fail';
> +--replace_column 1 #
> +--error ER_BACKUP_SYNCHRONIZE
> +BACKUP DATABASE db1 TO 'overwrite1.bak';
> +SET SESSION DEBUG='-d';
> +
> +--echo
> +
I do not think --replace_column is necessary here since no table output
is expected.
...
> /*
> + Simulate an error condition for failure of the
> + make_global_read_lock_block_commit call.
> + */
> + DBUG_EXECUTE_IF("backup_grl_block_commit_fail",
> + /* Mimic behavior of a failing make_global_read_lock_block_commit */
> + unlock_global_read_lock(thd);
> + DBUG_RETURN(1);
> + );
It seems a bit redundant to have to comments about the same.
(I think I like having the comment within DBUG_EXECUTE_IF. It creates
less noise, and distinguishes it from the comments from the statements
that does real work.)
--
Øystein