23#ifndef SQL_LOCK_INCLUDED
24#define SQL_LOCK_INCLUDED
105 bool for_trx =
true);
Sql_cmd_lock_instance represents statement LOCK INSTANCE FOR BACKUP.
Definition: sql_backup_lock.h:37
bool execute(THD *thd) override
Execute LOCK INSTANCE statement once.
Definition: sql_backup_lock.cc:58
enum_sql_command sql_command_code() const override
Return the command code for this statement.
Definition: sql_backup_lock.h:49
Sql_cmd_unlock_instance represents statement UNLOCK INSTANCE.
Definition: sql_backup_lock.h:58
bool execute(THD *thd) override
Execute UNLOCK INSTANCE statement once.
Definition: sql_backup_lock.cc:71
enum_sql_command sql_command_code() const override
Return the command code for this statement.
Definition: sql_backup_lock.h:70
Representation of an SQL command.
Definition: sql_cmd.h:64
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:33
enum_sql_command
Definition: my_sqlcommand.h:45
@ SQLCOM_LOCK_INSTANCE
Definition: my_sqlcommand.h:200
@ SQLCOM_UNLOCK_INSTANCE
Definition: my_sqlcommand.h:201
Is_instance_backup_locked_result is_instance_backup_locked(THD *thd)
Check if this server instance is locked with Backup Lock.
Definition: sql_backup_lock.cc:148
bool acquire_shared_backup_lock(THD *thd, unsigned long lock_wait_timeout, bool for_trx=true)
Acquire shared Backup Lock.
bool acquire_exclusive_backup_lock(THD *thd, unsigned long lock_wait_timeout, bool for_trx)
Acquire exclusive Backup Lock.
void release_backup_lock(THD *thd)
Release Backup Lock if it was acquired.
Definition: sql_backup_lock.cc:117
Is_instance_backup_locked_result
There are three possible results while checking if the instance is locked for backup.
Definition: sql_backup_lock.h:120
Representation of an SQL command.