MySQL  8.0.19
Source Code Documentation
mysql_cond_service.h
Go to the documentation of this file.
1 /* Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved.
2 
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License, version 2.0,
5 as published by the Free Software Foundation.
6 
7 This program is also distributed with certain software (including
8 but not limited to OpenSSL) that is licensed under separate terms,
9 as designated in a particular file or component or in included license
10 documentation. The authors of MySQL hereby grant you an additional
11 permission to link the program and your derivative works with the
12 separately licensed software that they have included with MySQL.
13 
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License, version 2.0, for more details.
18 
19 You should have received a copy of the GNU General Public License
20 along with this program; if not, write to the Free Software
21 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
22 
23 #ifndef COMPONENTS_SERVICES_MYSQL_COND_SERVICE_H
24 #define COMPONENTS_SERVICES_MYSQL_COND_SERVICE_H
25 
30 
31 typedef void (*mysql_cond_register_t)(const char *category, PSI_cond_info *info,
32  int count);
33 
35  const char *src_file, unsigned int src_line);
36 
37 typedef int (*mysql_cond_destroy_t)(mysql_cond_t *that, const char *src_file,
38  unsigned int src_line);
39 
41  const char *src_file, unsigned int src_line);
42 
44  const struct timespec *abstime,
45  const char *src_file,
46  unsigned int src_line);
47 
48 typedef int (*mysql_cond_signal_t)(mysql_cond_t *that, const char *src_file,
49  unsigned int src_line);
50 
51 typedef int (*mysql_cond_broadcast)(mysql_cond_t *that, const char *src_file,
52  unsigned int src_line);
53 
55 mysql_cond_register_t register_info;
62 END_SERVICE_DEFINITION(mysql_cond_v1)
63 
64 #define REQUIRES_MYSQL_COND_SERVICE REQUIRES_SERVICE(mysql_cond_v1)
65 
66 #endif /* COMPONENTS_SERVICES_MYSQL_COND_SERVICE_H */
mutex
pthread_mutex_t mutex
Definition: memcached.c:384
END_SERVICE_DEFINITION
#define END_SERVICE_DEFINITION(name)
A macro to end the last Service definition started with the BEGIN_SERVICE_DEFINITION macro.
Definition: service.h:90
BEGIN_SERVICE_DEFINITION
#define BEGIN_SERVICE_DEFINITION(name)
Declares a new Service.
Definition: service.h:85
service.h
mysql_mutex_t
An instrumented mutex structure.
Definition: mysql_mutex_bits.h:49
mysql_cond_register_t
void(* mysql_cond_register_t)(const char *category, PSI_cond_info *info, int count)
Definition: mysql_cond_service.h:31
mysql_cond_signal_t
int(* mysql_cond_signal_t)(mysql_cond_t *that, const char *src_file, unsigned int src_line)
Definition: mysql_cond_service.h:48
mysql_cond_broadcast
int(* mysql_cond_broadcast)(mysql_cond_t *that, const char *src_file, unsigned int src_line)
Definition: mysql_cond_service.h:51
key
static const char * key
Definition: suite_stubs.c:14
mysql_cond_wait_t
int(* mysql_cond_wait_t)(mysql_cond_t *that, mysql_mutex_t *mutex, const char *src_file, unsigned int src_line)
Definition: mysql_cond_service.h:40
mysql_cond_init_t
int(* mysql_cond_init_t)(PSI_cond_key key, mysql_cond_t *that, const char *src_file, unsigned int src_line)
Definition: mysql_cond_service.h:34
abstime
static time_t abstime(const rel_time_t exptime)
Convert the relative time to an absolute time (relative to EPOC ;) )
Definition: memcached.c:271
PSI_cond_info_v1
Condition information.
Definition: psi_cond_bits.h:85
mysql_mutex_bits.h
PSI_cond_key
unsigned int PSI_cond_key
Instrumented cond key.
Definition: psi_cond_bits.h:41
sha2_password::category
static const char * category
Definition: sha2_password.cc:167
mysql_cond_timedwait_t
int(* mysql_cond_timedwait_t)(mysql_cond_t *that, mysql_mutex_t *mutex, const struct timespec *abstime, const char *src_file, unsigned int src_line)
Definition: mysql_cond_service.h:43
mysql_cond_destroy_t
int(* mysql_cond_destroy_t)(mysql_cond_t *that, const char *src_file, unsigned int src_line)
Definition: mysql_cond_service.h:37
psi_cond_bits.h
count
ssize_t count
Definition: memcached.c:386
init
static mysql_service_status_t init()
Component initialization.
Definition: audit_api_message_emit.cc:574
mysql_cond_t
An instrumented cond structure.
Definition: mysql_cond_bits.h:49
destroy
void destroy(T *ptr)
Definition: my_alloc.h:381
info
Log info(cout, "NOTE")
mysql_cond_bits.h