26#ifndef SERVICE_LOCKING_INCLUDED
27#define SERVICE_LOCKING_INCLUDED
35#ifndef MYSQL_ABI_CHECK
42#define MYSQL_THD THD *
44#define MYSQL_THD void *
76 MYSQL_THD opaque_thd,
const char *lock_namespace,
const char **lock_names,
78 uint64_t lock_timeout);
93 const char *lock_namespace);
113#ifdef MYSQL_DYNAMIC_PLUGIN
115#define mysql_acquire_locking_service_locks(_THD, _NAMESPACE, _NAMES, _NUM, \
117 mysql_locking_service->mysql_acquire_locks(_THD, _NAMESPACE, _NAMES, _NUM, \
119#define mysql_release_locking_service_locks(_THD, _NAMESPACE) \
120 mysql_locking_service->mysql_release_locks(_THD, _NAMESPACE)
125 MYSQL_THD opaque_thd,
const char *lock_namespace,
const char **lock_names,
127 uint64_t lock_timeout);
130 const char *lock_namespace);
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:36
struct mysql_locking_service_st * mysql_locking_service
#define MYSQL_THD
Definition: service_locking.h:42
enum_locking_service_lock_type
Types of locking service locks.
Definition: service_locking.h:52
@ LOCKING_SERVICE_READ
Definition: service_locking.h:53
@ LOCKING_SERVICE_WRITE
Definition: service_locking.h:54
int(* mysql_release_locks_t)(MYSQL_THD opaque_thd, const char *lock_namespace)
Release all lock service locks taken by the given connection in the given namespace.
Definition: service_locking.h:92
int mysql_acquire_locking_service_locks(MYSQL_THD opaque_thd, const char *lock_namespace, const char **lock_names, size_t lock_num, enum enum_locking_service_lock_type lock_type, uint64_t lock_timeout)
int(* mysql_acquire_locks_t)(MYSQL_THD opaque_thd, const char *lock_namespace, const char **lock_names, size_t lock_num, enum enum_locking_service_lock_type lock_type, uint64_t lock_timeout)
Acquire locking service locks.
Definition: service_locking.h:75
int mysql_release_locking_service_locks(MYSQL_THD opaque_thd, const char *lock_namespace)
Definition: locking_service.cc:186
This service provides support for taking read/write locks.
Definition: service_locking.h:108
mysql_acquire_locks_t mysql_acquire_locks
Definition: service_locking.h:109
mysql_release_locks_t mysql_release_locks
Definition: service_locking.h:110