1 /*
2  * Copyright (c) 2018 Balabit
3  * Copyright (c) 2018 Kokan
4  *
5  * This program is free software; you can redistribute it and/or modify it
6  * under the terms of the GNU General Public License version 2 as published
7  * by the Free Software Foundation, or (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
17  *
18  * As an additional exemption you are allowed to compile & link against the
19  * OpenSSL libraries as published by the OpenSSL project. See the file
20  * COPYING for details.
21  *
22  */
23 
24 #include "afamqp-parser.h"
25 #include "plugin.h"
26 #include "plugin-types.h"
27 
28 extern CfgParser afamqp_dd_parser;
29 
30 static Plugin afamqp_plugins[] =
31 {
32   {
33     .type = LL_CONTEXT_DESTINATION,
34     .name = "amqp",
35     .parser = &afamqp_parser
36   }
37 };
38 
39 const ModuleInfo module_info =
40 {
41   .canonical_name = "afamqp",
42   .version = SYSLOG_NG_VERSION,
43   .description = "The afamqp module provides AMQP destination support for syslog-ng.",
44   .core_revision = SYSLOG_NG_SOURCE_REVISION,
45   .plugins = afamqp_plugins,
46   .plugins_len = G_N_ELEMENTS(afamqp_plugins),
47 };
48 
49 gboolean
afamqp_module_init(PluginContext * context,CfgArgs * args)50 afamqp_module_init(PluginContext *context, CfgArgs *args)
51 {
52   plugin_register(context, afamqp_plugins, G_N_ELEMENTS(afamqp_plugins));
53   return TRUE;
54 }
55 
56