* Copyright (c) 2020 Huawei Technologies Co.,Ltd.
*
* openGauss is licensed under Mulan PSL v2.
* You can use this software according to the terms and conditions of the Mulan PSL v2.
* You may obtain a copy of Mulan PSL v2 at:
*
* http://license.coscl.org.cn/MulanPSL2
*
* THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND,
* EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT,
* MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
* See the Mulan PSL v2 for more details.
* ---------------------------------------------------------------------------------------
*
* unique_sql_basic.h
*
*
* IDENTIFICATION
* src/include/instruments/unique_sql_basic.h
*
* ---------------------------------------------------------------------------------------
*/
#ifndef UNIQUE_SQL_BASIC_H
#define UNIQUE_SQL_BASIC_H
typedef struct {
uint32 cn_id;
* same with node_id in PGXC_NODE */
Oid user_id;
uint64 unique_sql_id;
} UniqueSQLKey;
typedef struct {
pg_atomic_uint64 soft_parse;
pg_atomic_uint64 hard_parse;
} UniqueSQLParse;
typedef struct {
pg_atomic_uint64 returned_rows;
pg_atomic_uint64 tuples_fetched;
pg_atomic_uint64 tuples_returned;
pg_atomic_uint64 tuples_inserted;
pg_atomic_uint64 tuples_updated;
pg_atomic_uint64 tuples_deleted;
} UniqueSQLRowActivity;
typedef struct {
pg_atomic_uint64 blocks_fetched;
pg_atomic_uint64 blocks_hit;
} UniqueSQLCacheIO;
#endif