Source
void zbx_pb_discovery_write_service(zbx_pb_discovery_data_t *data, zbx_uint64_t druleid, zbx_uint64_t dcheckid,
/*
** Zabbix
** Copyright (C) 2001-2023 Zabbix SIA
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
** the Free Software Foundation; either version 2 of the License, or
** (at your option) any later version.
**
** This program is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not, write to the Free Software
** Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
**/
typedef struct
{
zbx_uint64_t mem_used;
zbx_uint64_t mem_total;
}
zbx_pb_mem_info_t;
typedef struct
{
int state;
zbx_uint64_t changes_num;
}
zbx_pb_state_info_t;
int zbx_pb_parse_mode(const char *str, int *mode);
int zbx_pb_create(int mode, zbx_uint64_t size, int age, int offline_buffer, char **error);
void zbx_pb_init(void);
void zbx_pb_destroy(void);
void zbx_pb_update_state(int more);
void zbx_pb_disable(void);
void zbx_pb_flush(void);
int zbx_pb_get_mem_info(zbx_pb_mem_info_t *info, char **error);
void zbx_pb_get_state_info(zbx_pb_state_info_t *info);
void zbx_pb_get_mem_stats(zbx_shmem_stats_t *stats);
/* discovery */
typedef struct zbx_pb_discovery_data zbx_pb_discovery_data_t;
zbx_pb_discovery_data_t *zbx_pb_discovery_open(void);