1 /*
2 ** Zabbix
3 ** Copyright (C) 2001-2021 Zabbix SIA
4 **
5 ** This program is free software; you can redistribute it and/or modify
6 ** it under the terms of the GNU General Public License as published by
7 ** the Free Software Foundation; either version 2 of the License, or
8 ** (at your option) any later version.
9 **
10 ** This program is distributed in the hope that it will be useful,
11 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
12 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 ** GNU General Public License for more details.
14 **
15 ** You should have received a copy of the GNU General Public License
16 ** along with this program; if not, write to the Free Software
17 ** Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
18 **/
19 
20 #include "common.h"
21 #include "zbxalgo.h"
22 #include "db.h"
23 #include "../zabbix_server/events.h"
24 
zbx_initialize_events(void)25 void	zbx_initialize_events(void)
26 {
27 	THIS_SHOULD_NEVER_HAPPEN;
28 }
29 
zbx_uninitialize_events(void)30 void	zbx_uninitialize_events(void)
31 {
32 	THIS_SHOULD_NEVER_HAPPEN;
33 }
34 
zbx_add_event(unsigned char source,unsigned char object,zbx_uint64_t objectid,const zbx_timespec_t * timespec,int value,const char * trigger_description,const char * trigger_expression,const char * trigger_recovery_expression,unsigned char trigger_priority,unsigned char trigger_type,const zbx_vector_ptr_t * trigger_tags,unsigned char trigger_correlation_mode,const char * trigger_correlation_tag,unsigned char trigger_value,const char * trigger_opdata,const char * error)35 DB_EVENT	*zbx_add_event(unsigned char source, unsigned char object, zbx_uint64_t objectid,
36 		const zbx_timespec_t *timespec, int value, const char *trigger_description,
37 		const char *trigger_expression, const char *trigger_recovery_expression, unsigned char trigger_priority,
38 		unsigned char trigger_type, const zbx_vector_ptr_t *trigger_tags,
39 		unsigned char trigger_correlation_mode, const char *trigger_correlation_tag,
40 		unsigned char trigger_value, const char *trigger_opdata, const char *error)
41 {
42 	ZBX_UNUSED(source);
43 	ZBX_UNUSED(object);
44 	ZBX_UNUSED(objectid);
45 	ZBX_UNUSED(timespec);
46 	ZBX_UNUSED(value);
47 	ZBX_UNUSED(trigger_description);
48 	ZBX_UNUSED(trigger_expression);
49 	ZBX_UNUSED(trigger_recovery_expression);
50 	ZBX_UNUSED(trigger_priority);
51 	ZBX_UNUSED(trigger_type);
52 	ZBX_UNUSED(trigger_tags);
53 	ZBX_UNUSED(trigger_correlation_mode);
54 	ZBX_UNUSED(trigger_correlation_tag);
55 	ZBX_UNUSED(trigger_value);
56 	ZBX_UNUSED(trigger_opdata);
57 	ZBX_UNUSED(error);
58 
59 	THIS_SHOULD_NEVER_HAPPEN;
60 
61 	return NULL;
62 }
63 
zbx_close_problem(zbx_uint64_t triggerid,zbx_uint64_t eventid,zbx_uint64_t userid)64 int	zbx_close_problem(zbx_uint64_t triggerid, zbx_uint64_t eventid, zbx_uint64_t userid)
65 {
66 	ZBX_UNUSED(triggerid);
67 	ZBX_UNUSED(eventid);
68 	ZBX_UNUSED(userid);
69 
70 	THIS_SHOULD_NEVER_HAPPEN;
71 	return 0;
72 }
73 
zbx_process_events(zbx_vector_ptr_t * trigger_diff,zbx_vector_uint64_t * triggerids_lock)74 int	zbx_process_events(zbx_vector_ptr_t *trigger_diff, zbx_vector_uint64_t *triggerids_lock)
75 {
76 	ZBX_UNUSED(trigger_diff);
77 	ZBX_UNUSED(triggerids_lock);
78 
79 	THIS_SHOULD_NEVER_HAPPEN;
80 	return 0;
81 }
82 
zbx_clean_events(void)83 void	zbx_clean_events(void)
84 {
85 	THIS_SHOULD_NEVER_HAPPEN;
86 }
87 
zbx_reset_event_recovery(void)88 void	zbx_reset_event_recovery(void)
89 {
90 	THIS_SHOULD_NEVER_HAPPEN;
91 }
92 
zbx_export_events(void)93 void	zbx_export_events(void)
94 {
95 	THIS_SHOULD_NEVER_HAPPEN;
96 }
97