MySQL 8.4.2
Source Code Documentation
secondary_engine.h
Go to the documentation of this file.
1#ifndef SECONDARY_ENGINE_INCLUDED
2#define SECONDARY_ENGINE_INCLUDED
3
4// Copyright (c) 2018, 2024, Oracle and/or its affiliates.
5//
6// This program is free software; you can redistribute it and/or modify
7// it under the terms of the GNU General Public License, version 2.0,
8// as published by the Free Software Foundation.
9//
10// This program is designed to work with certain software (including
11// but not limited to OpenSSL) that is licensed under separate terms,
12// as designated in a particular file or component or in included license
13// documentation. The authors of MySQL hereby grant you an additional
14// permission to link the program and your derivative works with the
15// separately licensed software that they have either included with
16// the program or referenced in the documentation.
17//
18// This program is distributed in the hope that it will be useful,
19// but WITHOUT ANY WARRANTY; without even the implied warranty of
20// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21// GNU General Public License, version 2.0, for more details.
22//
23// You should have received a copy of the GNU General Public License
24// along with this program; if not, write to the Free Software
25// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
26
27#include <string>
28#include <vector>
29
30#include "mysql.h"
31
33 public:
34 Secondary_engine() = default;
35 ~Secondary_engine() = default;
36
37 /// Get the secondary engine execution count value.
38 ///
39 /// @param mysql mysql handle
40 /// @param mode Mode value (either "after" or "before")
41 ///
42 /// @retval True if the query fails, false otherwise.
43 bool offload_count(MYSQL *mysql, const char *mode);
44
45 /// Report secondary engine execution count value.
46 ///
47 /// @param filename File to store the count value
48 void report_offload_count(const char *filename);
49};
50
51#endif // SECONDARY_ENGINE_INCLUDED
Definition: secondary_engine.h:32
Secondary_engine()=default
~Secondary_engine()=default
void report_offload_count(const char *filename)
Report secondary engine execution count value.
Definition: secondary_engine.cc:78
bool offload_count(MYSQL *mysql, const char *mode)
Get the secondary engine execution count value.
Definition: secondary_engine.cc:46
This file defines the client API to MySQL and also the ABI of the dynamically linked libmysqlclient.
Definition: instrumented_condition_variable.h:32
mode
Definition: file_handle.h:61
const char * filename
Definition: pfs_example_component_population.cc:67
Definition: mysql.h:300