1 /* Copyright (c) 2020, 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 MYSQL_PSI_TLS_CHANNEL_H 24 #define MYSQL_PSI_TLS_CHANNEL_H 25 26 /** 27 @file include/mysql/psi/psi_tls_channel.h 28 Performance schema instrumentation interface. 29 30 @defgroup psi_abi_tls_channel TLS Channel Instrumentation (ABI) 31 @ingroup psi_abi 32 @{ 33 */ 34 35 #include "my_inttypes.h" 36 #include "my_macros.h" 37 #include "my_psi_config.h" // IWYU pragma: keep 38 #include "my_sharedlib.h" 39 #include "mysql/components/services/psi_tls_channel_bits.h" 40 41 /** Entry point for the performance schema interface. */ 42 struct PSI_tls_channel_bootstrap { 43 /** 44 ABI interface finder. 45 Calling this method with an interface version number returns either 46 an instance of the ABI for this version, or NULL. 47 @sa PSI_TLS_CHANNEL_VERSION_1 48 @sa PSI_CURRENT_TLS_CHANNEL_VERSION 49 */ 50 void *(*get_interface)(int version); 51 }; 52 typedef struct PSI_tls_channel_bootstrap PSI_tls_channel_bootstrap; 53 54 #ifdef HAVE_PSI_TLS_CHANNEL_INTERFACE 55 56 /** 57 Performance schema TLS channel interface, version 1. 58 @since PSI_TLS_CHANNEL_VERSION_1 59 */ 60 struct PSI_tls_channel_service_v1 { 61 register_tls_channel_v1_t register_tls_channel; 62 unregister_tls_channel_v1_t unregister_tls_channel; 63 }; 64 65 typedef struct PSI_tls_channel_service_v1 PSI_tls_channel_service_t; 66 67 extern MYSQL_PLUGIN_IMPORT PSI_tls_channel_service_t *psi_tls_channel_service; 68 69 #endif // HAVE_PSI_TLS_CHANNEL_INTERFACE 70 71 /** @} (end of group psi_abi_tls_channel) */ 72 73 #endif // !MYSQL_PSI_TLS_CHANNEL_H 74