MySQL 8.2.0
Source Code Documentation
pfs_setup_object.h
Go to the documentation of this file.
1/* Copyright (c) 2010, 2023, Oracle and/or its affiliates.
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 PFS_SETUP_OBJECT_H
24#define PFS_SETUP_OBJECT_H
25
26/**
27 @file storage/perfschema/pfs_setup_object.h
28 Performance schema setup object (declarations).
29*/
30
31#include <sys/types.h>
32
33#include "lf.h"
39
40class String;
41struct PFS_global_param;
42class PFS_opaque_container_page;
43
44/**
45 @addtogroup performance_schema_buffers
46 @{
47*/
48
49/** Hash key for @sa PFS_setup_object. */
54};
55
56/** A setup_object record. */
58 /** Internal lock. */
60 /** Hash key. */
62 /** ENABLED flag. */
64 /** TIMED flag. */
65 bool m_timed;
66 /** Container page. */
67 PFS_opaque_container_page *m_page;
68};
69
70int init_setup_object(const PFS_global_param *param);
74
76 const PFS_schema_name *schema,
77 const PFS_object_name *object, bool enabled,
78 bool timed);
80 const PFS_schema_name *schema,
81 const PFS_object_name *object);
84
86 const PFS_schema_name *schema_name,
87 const PFS_table_name *table_name, bool *enabled,
88 bool *timed);
89
91 enum_object_type object_type,
92 const PFS_schema_name *schema,
93 const PFS_routine_name *routine_name,
94 bool *enabled, bool *timed);
95
96/* For show status. */
97
99
100/** @} */
101#endif
Using this class is fraught with peril, and you need to be very careful when doing so.
Definition: sql_string.h:166
int init_setup_object_hash(const PFS_global_param *param)
Initialize the setup objects hash.
Definition: pfs_setup_object.cc:154
LF_HASH setup_object_hash
Definition: pfs_setup_object.cc:51
int init_setup_object(const PFS_global_param *param)
Initialize the setup object buffers.
Definition: pfs_setup_object.cc:59
int delete_setup_object(enum_object_type object_type, const PFS_schema_name *schema, const PFS_object_name *object)
Definition: pfs_setup_object.cc:235
int reset_setup_object()
Definition: pfs_setup_object.cc:281
void lookup_setup_object_routine(PFS_thread *thread, enum_object_type object_type, const PFS_schema_name *schema_name, const PFS_routine_name *routine_name, bool *enabled, bool *timed)
Definition: pfs_setup_object.cc:386
void lookup_setup_object_table(PFS_thread *thread, enum_object_type object_type, const PFS_schema_name *schema_name, const PFS_table_name *table_name, bool *enabled, bool *timed)
Definition: pfs_setup_object.cc:376
long setup_object_count()
Definition: pfs_setup_object.cc:300
int insert_setup_object(enum_object_type object_type, const PFS_schema_name *schema, const PFS_object_name *object, bool enabled, bool timed)
Definition: pfs_setup_object.cc:192
void cleanup_setup_object()
Cleanup all the setup object buffers.
Definition: pfs_setup_object.cc:64
void cleanup_setup_object_hash()
Cleanup the setup objects hash.
Definition: pfs_setup_object.cc:166
const char * table_name
Definition: rules_table_service.cc:55
Data types for columns used in the performance schema tables (declarations)
enum_object_type
Enum values for the various OBJECT_TYPE columns.
Definition: pfs_column_types.h:221
Miscellaneous global dependencies (declarations).
#define PFS_ALIGNED
Definition: pfs_global.h:56
Performance schema instruments (declarations).
Performance schema internal locks (declarations).
Object names (declarations).
required bool enabled
Definition: replication_group_member_actions.proto:32
Definition: lf.h:186
Performance schema global sizing parameters.
Definition: pfs_server.h:118
Definition: pfs_name.h:184
Definition: pfs_name.h:161
Definition: pfs_name.h:117
Hash key for.
Definition: pfs_setup_object.h:50
PFS_schema_name m_schema_name
Definition: pfs_setup_object.h:52
PFS_object_name m_object_name
Definition: pfs_setup_object.h:53
enum_object_type m_object_type
Definition: pfs_setup_object.h:51
A setup_object record.
Definition: pfs_setup_object.h:57
PFS_opaque_container_page * m_page
Container page.
Definition: pfs_setup_object.h:67
bool m_enabled
ENABLED flag.
Definition: pfs_setup_object.h:63
PFS_setup_object_key m_key
Hash key.
Definition: pfs_setup_object.h:61
bool m_timed
TIMED flag.
Definition: pfs_setup_object.h:65
pfs_lock m_lock
Internal lock.
Definition: pfs_setup_object.h:59
Definition: pfs_name.h:138
Instrumented thread implementation.
Definition: pfs_instr.h:374
A 'lock' protecting performance schema internal buffers.
Definition: pfs_lock.h:153