MySQL 9.1.0
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_SERVER_TELEMETRY_LOGS
72 @sa DISABLE_PSI_METRICS
73 */
74
75#ifndef DISABLE_PSI_MUTEX
76#define HAVE_PSI_MUTEX_INTERFACE
77#endif /* DISABLE_PSI_MUTEX */
78
79/**
80 @def DISABLE_PSI_RWLOCK
81 Compiling option to disable the rwlock instrumentation.
82 @sa DISABLE_PSI_MUTEX
83*/
84
85#ifndef DISABLE_PSI_RWLOCK
86#define HAVE_PSI_RWLOCK_INTERFACE
87#endif /* DISABLE_PSI_RWLOCK */
88
89/**
90 @def DISABLE_PSI_COND
91 Compiling option to disable the cond instrumentation.
92 @sa DISABLE_PSI_MUTEX
93*/
94
95#ifndef DISABLE_PSI_COND
96#define HAVE_PSI_COND_INTERFACE
97#endif /* DISABLE_PSI_COND */
98
99/**
100 @def DISABLE_PSI_FILE
101 Compiling option to disable the file instrumentation.
102 @sa DISABLE_PSI_MUTEX
103*/
104
105#ifndef DISABLE_PSI_FILE
106#define HAVE_PSI_FILE_INTERFACE
107#endif /* DISABLE_PSI_FILE */
108
109/**
110 @def DISABLE_PSI_THREAD
111 Compiling option to disable the thread instrumentation.
112 @sa DISABLE_PSI_MUTEX
113*/
114
115#ifndef DISABLE_PSI_THREAD
116#define HAVE_PSI_THREAD_INTERFACE
117#endif /* DISABLE_PSI_THREAD */
118
119/**
120 @def DISABLE_PSI_TABLE
121 Compiling option to disable the table instrumentation.
122 @sa DISABLE_PSI_MUTEX
123*/
124
125#ifndef DISABLE_PSI_TABLE
126#define HAVE_PSI_TABLE_INTERFACE
127#endif /* DISABLE_PSI_TABLE */
128
129/**
130 @def DISABLE_PSI_STAGE
131 Compiling option to disable the stage instrumentation.
132 @sa DISABLE_PSI_MUTEX
133*/
134
135#ifndef DISABLE_PSI_STAGE
136#define HAVE_PSI_STAGE_INTERFACE
137#endif /* DISABLE_PSI_STAGE */
138
139/**
140 @def DISABLE_PSI_STATEMENT
141 Compiling option to disable the statement instrumentation.
142 @sa DISABLE_PSI_MUTEX
143*/
144
145#ifndef DISABLE_PSI_STATEMENT
146#define HAVE_PSI_STATEMENT_INTERFACE
147#endif /* DISABLE_PSI_STATEMENT */
148
149/**
150 @def DISABLE_PSI_SP
151 Compiling option to disable the stored program instrumentation.
152 @sa DISABLE_PSI_MUTEX
153*/
154
155#ifndef DISABLE_PSI_SP
156#define HAVE_PSI_SP_INTERFACE
157#endif /* DISABLE_PSI_SP */
158
159/**
160 @def DISABLE_PSI_PS
161 Compiling option to disable the prepared statement instrumentation.
162 @sa DISABLE_PSI_MUTEX
163*/
164
165#ifndef DISABLE_PSI_STATEMENT
166#ifndef DISABLE_PSI_PS
167#define HAVE_PSI_PS_INTERFACE
168#endif /* DISABLE_PSI_PS */
169#endif /* DISABLE_PSI_STATEMENT */
170
171/**
172 @def DISABLE_PSI_STATEMENT_DIGEST
173 Compiling option to disable the statement digest instrumentation.
174*/
175
176#ifndef DISABLE_PSI_STATEMENT
177#ifndef DISABLE_PSI_STATEMENT_DIGEST
178#define HAVE_PSI_STATEMENT_DIGEST_INTERFACE
179#endif /* DISABLE_PSI_STATEMENT_DIGEST */
180#endif /* DISABLE_PSI_STATEMENT */
181
182/**
183 @def DISABLE_PSI_TRANSACTION
184 Compiling option to disable the transaction instrumentation.
185 @sa DISABLE_PSI_MUTEX
186*/
187
188#ifndef DISABLE_PSI_TRANSACTION
189#define HAVE_PSI_TRANSACTION_INTERFACE
190#endif /* DISABLE_PSI_TRANSACTION */
191
192/**
193 @def DISABLE_PSI_SOCKET
194 Compiling option to disable the statement instrumentation.
195 @sa DISABLE_PSI_MUTEX
196*/
197
198#ifndef DISABLE_PSI_SOCKET
199#define HAVE_PSI_SOCKET_INTERFACE
200#endif /* DISABLE_PSI_SOCKET */
201
202/**
203 @def DISABLE_PSI_MEMORY
204 Compiling option to disable the memory instrumentation.
205 @sa DISABLE_PSI_MUTEX
206*/
207
208#ifndef DISABLE_PSI_MEMORY
209#define HAVE_PSI_MEMORY_INTERFACE
210#endif /* DISABLE_PSI_MEMORY */
211
212/**
213 @def DISABLE_PSI_ERROR
214 Compiling option to disable the error instrumentation.
215 @sa DISABLE_PSI_MUTEX
216*/
217
218#ifndef DISABLE_PSI_ERROR
219#define HAVE_PSI_ERROR_INTERFACE
220#endif /* DISABLE_PSI_ERROR */
221
222/**
223 @def DISABLE_PSI_IDLE
224 Compiling option to disable the idle instrumentation.
225 @sa DISABLE_PSI_MUTEX
226*/
227
228#ifndef DISABLE_PSI_IDLE
229#define HAVE_PSI_IDLE_INTERFACE
230#endif /* DISABLE_PSI_IDLE */
231
232/**
233 @def DISABLE_PSI_METADATA
234 Compiling option to disable the metadata instrumentation.
235 @sa DISABLE_PSI_MUTEX
236*/
237
238#ifndef DISABLE_PSI_METADATA
239#define HAVE_PSI_METADATA_INTERFACE
240#endif /* DISABLE_PSI_METADATA */
241
242/**
243 @def DISABLE_PSI_DATA_LOCK
244 Compiling option to disable the data lock instrumentation.
245 @sa DISABLE_PSI_MUTEX
246*/
247
248#ifndef DISABLE_PSI_DATA_LOCK
249#define HAVE_PSI_DATA_LOCK_INTERFACE
250#endif /* DISABLE_PSI_DATA_LOCK */
251
252/**
253 @def DISABLE_PSI_SYSTEM
254 Compiling option to disable the system instrumentation.
255 @sa DISABLE_PSI_MUTEX
256*/
257
258#ifndef DISABLE_PSI_SYSTEM
259#define HAVE_PSI_SYSTEM_INTERFACE
260#endif /* DISABLE_PSI_SYSTEM */
261
262/**
263 @def DISABLE_PSI_TLS_CHANNEL
264 Compiling option to disable TLS Channel instrumentation.
265 @sa DISABLE_PSI_MUTEX
266*/
267
268#ifndef DISABLE_PSI_TLS_CHANNEL
269#define HAVE_PSI_TLS_CHANNEL_INTERFACE
270#endif // !DISABLE_PSI_TLS_CHANNEL
271
272/**
273 @def DISABLE_PSI_SERVER_TELEMETRY_TRACES
274 Compiling option to disable MySQL Server Telemetry traces instrumentation.
275 @sa DISABLE_PSI_MUTEX
276*/
277
278#ifndef DISABLE_PSI_SERVER_TELEMETRY_TRACES
279#define HAVE_PSI_SERVER_TELEMETRY_TRACES_INTERFACE
280#endif // !DISABLE_PSI_SERVER_TELEMETRY_TRACES
281
282/**
283 @def DISABLE_PSI_SERVER_TELEMETRY_LOGS
284 Compiling option to disable MySQL Server Telemetry logs instrumentation.
285 @sa DISABLE_PSI_MUTEX
286 */
287
288#ifndef DISABLE_PSI_SERVER_TELEMETRY_LOGS
289#define HAVE_PSI_SERVER_TELEMETRY_LOGS_INTERFACE
290#endif // !DISABLE_PSI_SERVER_TELEMETRY_LOGS
291
292/**
293 @def DISABLE_PSI_METRICS
294 Compiling option to disable MySQL Server Telemetry metrics instrumentation.
295 @sa DISABLE_PSI_MUTEX
296*/
297
298#ifndef DISABLE_PSI_METRICS
299#define HAVE_PSI_METRICS_INTERFACE
300#endif // !DISABLE_PSI_METRICS
301
302#endif /* HAVE_PSI_INTERFACE */
303
304#endif // MY_PSI_CONFIG_INCLUDED