MySQL 9.2.0
Source Code Documentation
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages Concepts
applier_metrics_service_imp.h
Go to the documentation of this file.
1/* Copyright (c) 2024, 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 designed to work 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 either included with
13 the program or referenced in the documentation.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License, version 2.0, for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
23
24#ifndef APPLIER_METRICS_SERVICE_IMP_H
25#define APPLIER_METRICS_SERVICE_IMP_H
26
27#include <mysql/components/service_implementation.h> // DEFINE_BOOL_METHOD
28#include <mysql/components/services/rpl_applier_metrics_service.h> // Applier_metrics_table
29
31 public:
32 /// @brief Get metrics for the replication applier.
33 /// @param[out] table pointer, whose value will be set to an array of arrays
34 /// of fields in which the metric values are stored.
35 /// @return
36 /// @retval FALSE Succeeded.
37 /// @retval TRUE Failed.
40
41 /// @brief Free memory for object holding metrics for the replication applier.
42 /// @param[out] table Pointer to object that was previously retrieved from
43 /// @c get_applier_metrics.
46
47 /// @brief Get metrics for replication workers.
48 /// @param[out] table pointer, whose value will be set to an array of arrays
49 /// of fields in which the metric values are stored.
50 /// @return
51 /// @retval FALSE Succeeded.
52 /// @retval TRUE Failed.
54
55 /// @brief Free memory for object holding metrics for the replication workers.
56 /// @param[out] table Pointer to object that was previously retrieved from
57 /// @c get_worker_metrics.
60
61 /// @brief Enables metric collection in the server for replication applier
62 /// components
63 /// @return
64 /// @retval FALSE Succeeded.
65 /// @retval TRUE Failed.
67
68 /// @brief Enables metric collection in the server for replication applier
69 /// components
70 /// @return
71 /// @retval FALSE Succeeded.
72 /// @retval TRUE Failed.
73
75};
76
77#endif /* APPLIER_METRICS_SERVICE_IMP_H */
Definition: applier_metrics_service_imp.h:30
static mysql_service_status_t enable_metric_collection() noexcept
Enables metric collection in the server for replication applier components.
Definition: applier_metrics_service_imp.cc:376
static mysql_service_status_t get_worker_metrics(Worker_metrics_table *table) noexcept
Get metrics for replication workers.
Definition: applier_metrics_service_imp.cc:267
static void free_worker_metrics(Worker_metrics_table *table) noexcept
Free memory for object holding metrics for the replication workers.
Definition: applier_metrics_service_imp.cc:367
static void free_applier_metrics(Applier_metrics_table *table) noexcept
Free memory for object holding metrics for the replication applier.
Definition: applier_metrics_service_imp.cc:258
static mysql_service_status_t disable_metric_collection() noexcept
Enables metric collection in the server for replication applier components.
Definition: applier_metrics_service_imp.cc:382
static mysql_service_status_t get_applier_metrics(Applier_metrics_table *table) noexcept
Get metrics for the replication applier.
Definition: applier_metrics_service_imp.cc:40
Ownership-agnostic array class, which is both trivial and standard-layout.
Definition: array_view.h:53
static PFS_engine_table_share_proxy table
Definition: pfs.cc:61
Specifies macros to define Service Implementations.
#define DEFINE_BOOL_METHOD(name, args)
A short macro to define method that returns bool, which is the most common case.
Definition: service_implementation.h:88
#define DEFINE_METHOD(retval, name, args)
A macro to ensure method implementation has required properties, that is it does not throw exceptions...
Definition: service_implementation.h:79