MySQL 8.4.2
Source Code Documentation
my_psi_config.h
Go to the documentation of this file.
1/*
2 Copyright (c) 2001, 2024, Oracle and/or its affiliates.
3
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License, version 2.0,
6 as published by the Free Software Foundation.
7
8 This program is designed to work with certain software (including
9 but not limited to OpenSSL) that is licensed under separate terms,
10 as designated in a particular file or component or in included license
11 documentation. The authors of MySQL hereby grant you an additional
12 permission to link the program and your derivative works with the
13 separately licensed software that they have either included with
14 the program or referenced in the documentation.
15
16 This program is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 GNU General Public License, version 2.0, for more details.
20
21 You should have received a copy of the GNU General Public License
22 along with this program; if not, write to the Free Software
23 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
24
25#ifndef MY_PSI_CONFIG_INCLUDED
26#define MY_PSI_CONFIG_INCLUDED
27
28/**
29 @file include/my_psi_config.h
30 Defines various enable/disable and HAVE_ macros related to the
31 performance schema instrumentation system, without pulling in
32 any system \#include files (which breaks the ABI checker).
33
34*/
35
36#include "my_config.h"
37
38#ifdef WITH_PERFSCHEMA_STORAGE_ENGINE
39#define HAVE_PSI_INTERFACE
40#endif /* WITH_PERFSCHEMA_STORAGE_ENGINE */
41
42#ifdef HAVE_PSI_INTERFACE
43
44/**
45 @def DISABLE_PSI_MUTEX
46 Compiling option to disable the mutex instrumentation.
47 This option is mostly intended to be used during development,
48 when doing special builds with only a subset of the performance schema
49 instrumentation, for code analysis / profiling / performance tuning of a
50 specific instrumentation alone.
51 @sa DISABLE_PSI_COND
52 @sa DISABLE_PSI_DATA_LOCK
53 @sa DISABLE_PSI_ERROR
54 @sa DISABLE_PSI_FILE
55 @sa DISABLE_PSI_IDLE
56 @sa DISABLE_PSI_MEMORY
57 @sa DISABLE_PSI_METADATA
58 @sa DISABLE_PSI_PS
59 @sa DISABLE_PSI_RWLOCK
60 @sa DISABLE_PSI_SOCKET
61 @sa DISABLE_PSI_SP
62 @sa DISABLE_PSI_STAGE
63 @sa DISABLE_PSI_STATEMENT
64 @sa DISABLE_PSI_STATEMENT_DIGEST
65 @sa DISABLE_PSI_SYSTEM
66 @sa DISABLE_PSI_TABLE
67 @sa DISABLE_PSI_THREAD
68 @sa DISABLE_PSI_TRANSACTION
69 @sa DISABLE_TLS_CHANNEL
70 @sa DISABLE_PSI_SERVER_TELEMETRY_TRACES
71 @sa DISABLE_PSI_METRICS
72 */
73
74#ifndef DISABLE_PSI_MUTEX
75#define HAVE_PSI_MUTEX_INTERFACE
76#endif /* DISABLE_PSI_MUTEX */
77
78/**
79 @def DISABLE_PSI_RWLOCK
80 Compiling option to disable the rwlock instrumentation.
81 @sa DISABLE_PSI_MUTEX
82*/
83
84#ifndef DISABLE_PSI_RWLOCK
85#define HAVE_PSI_RWLOCK_INTERFACE
86#endif /* DISABLE_PSI_RWLOCK */
87
88/**
89 @def DISABLE_PSI_COND
90 Compiling option to disable the cond instrumentation.
91 @sa DISABLE_PSI_MUTEX
92*/
93
94#ifndef DISABLE_PSI_COND
95#define HAVE_PSI_COND_INTERFACE
96#endif /* DISABLE_PSI_COND */
97
98/**
99 @def DISABLE_PSI_FILE
100 Compiling option to disable the file instrumentation.
101 @sa DISABLE_PSI_MUTEX
102*/
103
104#ifndef DISABLE_PSI_FILE
105#define HAVE_PSI_FILE_INTERFACE
106#endif /* DISABLE_PSI_FILE */
107
108/**
109 @def DISABLE_PSI_THREAD
110 Compiling option to disable the thread instrumentation.
111 @sa DISABLE_PSI_MUTEX
112*/
113
114#ifndef DISABLE_PSI_THREAD
115#define HAVE_PSI_THREAD_INTERFACE
116#endif /* DISABLE_PSI_THREAD */
117
118/**
119 @def DISABLE_PSI_TABLE
120 Compiling option to disable the table instrumentation.
121 @sa DISABLE_PSI_MUTEX
122*/
123
124#ifndef DISABLE_PSI_TABLE
125#define HAVE_PSI_TABLE_INTERFACE
126#endif /* DISABLE_PSI_TABLE */
127
128/**
129 @def DISABLE_PSI_STAGE
130 Compiling option to disable the stage instrumentation.
131 @sa DISABLE_PSI_MUTEX
132*/
133
134#ifndef DISABLE_PSI_STAGE
135#define HAVE_PSI_STAGE_INTERFACE
136#endif /* DISABLE_PSI_STAGE */
137
138/**
139 @def DISABLE_PSI_STATEMENT
140 Compiling option to disable the statement instrumentation.
141 @sa DISABLE_PSI_MUTEX
142*/
143
144#ifndef DISABLE_PSI_STATEMENT
145#define HAVE_PSI_STATEMENT_INTERFACE
146#endif /* DISABLE_PSI_STATEMENT */
147
148/**
149 @def DISABLE_PSI_SP
150 Compiling option to disable the stored program instrumentation.
151 @sa DISABLE_PSI_MUTEX
152*/
153
154#ifndef DISABLE_PSI_SP
155#define HAVE_PSI_SP_INTERFACE
156#endif /* DISABLE_PSI_SP */
157
158/**
159 @def DISABLE_PSI_PS
160 Compiling option to disable the prepared statement instrumentation.
161 @sa DISABLE_PSI_MUTEX
162*/
163
164#ifndef DISABLE_PSI_STATEMENT
165#ifndef DISABLE_PSI_PS
166#define HAVE_PSI_PS_INTERFACE
167#endif /* DISABLE_PSI_PS */
168#endif /* DISABLE_PSI_STATEMENT */
169
170/**
171 @def DISABLE_PSI_STATEMENT_DIGEST
172 Compiling option to disable the statement digest instrumentation.
173*/
174
175#ifndef DISABLE_PSI_STATEMENT
176#ifndef DISABLE_PSI_STATEMENT_DIGEST
177#define HAVE_PSI_STATEMENT_DIGEST_INTERFACE
178#endif /* DISABLE_PSI_STATEMENT_DIGEST */
179#endif /* DISABLE_PSI_STATEMENT */
180
181/**
182 @def DISABLE_PSI_TRANSACTION
183 Compiling option to disable the transaction instrumentation.
184 @sa DISABLE_PSI_MUTEX
185*/
186
187#ifndef DISABLE_PSI_TRANSACTION
188#define HAVE_PSI_TRANSACTION_INTERFACE
189#endif /* DISABLE_PSI_TRANSACTION */
190
191/**
192 @def DISABLE_PSI_SOCKET
193 Compiling option to disable the statement instrumentation.
194 @sa DISABLE_PSI_MUTEX
195*/
196
197#ifndef DISABLE_PSI_SOCKET
198#define HAVE_PSI_SOCKET_INTERFACE
199#endif /* DISABLE_PSI_SOCKET */
200
201/**
202 @def DISABLE_PSI_MEMORY
203 Compiling option to disable the memory instrumentation.
204 @sa DISABLE_PSI_MUTEX
205*/
206
207#ifndef DISABLE_PSI_MEMORY
208#define HAVE_PSI_MEMORY_INTERFACE
209#endif /* DISABLE_PSI_MEMORY */
210
211/**
212 @def DISABLE_PSI_ERROR
213 Compiling option to disable the error instrumentation.
214 @sa DISABLE_PSI_MUTEX
215*/
216
217#ifndef DISABLE_PSI_ERROR
218#define HAVE_PSI_ERROR_INTERFACE
219#endif /* DISABLE_PSI_ERROR */
220
221/**
222 @def DISABLE_PSI_IDLE
223 Compiling option to disable the idle instrumentation.
224 @sa DISABLE_PSI_MUTEX
225*/
226
227#ifndef DISABLE_PSI_IDLE
228#define HAVE_PSI_IDLE_INTERFACE
229#endif /* DISABLE_PSI_IDLE */
230
231/**
232 @def DISABLE_PSI_METADATA
233 Compiling option to disable the metadata instrumentation.
234 @sa DISABLE_PSI_MUTEX
235*/
236
237#ifndef DISABLE_PSI_METADATA
238#define HAVE_PSI_METADATA_INTERFACE
239#endif /* DISABLE_PSI_METADATA */
240
241/**
242 @def DISABLE_PSI_DATA_LOCK
243 Compiling option to disable the data lock instrumentation.
244 @sa DISABLE_PSI_MUTEX
245*/
246
247#ifndef DISABLE_PSI_DATA_LOCK
248#define HAVE_PSI_DATA_LOCK_INTERFACE
249#endif /* DISABLE_PSI_DATA_LOCK */
250
251/**
252 @def DISABLE_PSI_SYSTEM
253 Compiling option to disable the system instrumentation.
254 @sa DISABLE_PSI_MUTEX
255*/
256
257#ifndef DISABLE_PSI_SYSTEM
258#define HAVE_PSI_SYSTEM_INTERFACE
259#endif /* DISABLE_PSI_SYSTEM */
260
261/**
262 @def DISABLE_PSI_TLS_CHANNEL
263 Compiling option to disable TLS Channel instrumentation.
264 @sa DISABLE_PSI_MUTEX
265*/
266
267#ifndef DISABLE_PSI_TLS_CHANNEL
268#define HAVE_PSI_TLS_CHANNEL_INTERFACE
269#endif // !DISABLE_PSI_TLS_CHANNEL
270
271/**
272 @def DISABLE_PSI_SERVER_TELEMETRY_TRACES
273 Compiling option to disable MySQL Server Telemetry traces instrumentation.
274 @sa DISABLE_PSI_MUTEX
275*/
276
277#ifndef DISABLE_PSI_SERVER_TELEMETRY_TRACES
278#define HAVE_PSI_SERVER_TELEMETRY_TRACES_INTERFACE
279#endif // !DISABLE_PSI_SERVER_TELEMETRY_TRACES
280
281/**
282 @def DISABLE_PSI_METRICS
283 Compiling option to disable MySQL Server Telemetry metrics instrumentation.
284 @sa DISABLE_PSI_MUTEX
285*/
286
287#ifndef DISABLE_PSI_METRICS
288#define HAVE_PSI_METRICS_INTERFACE
289#endif // !DISABLE_PSI_METRICS
290
291#endif /* HAVE_PSI_INTERFACE */
292
293#endif // MY_PSI_CONFIG_INCLUDED