output: moving function to the right place to fix warning of implicit declaration
@@ -766,6 +766,21 @@ void flb_output_net_default(const char *host, const int port,
}
}
+/* Add thread pool for output plugin if configured with workers */
+int flb_output_enable_multi_threading(struct flb_output_instance *ins, struct flb_config *config)
+{
+ /* Multi-threading enabled ? (through 'workers' property) */
+ if (ins->tp_workers > 0) {
+ if(flb_output_thread_pool_create(config, ins) != 0) {
+ flb_output_instance_destroy(ins);
+ return -1;
+ }
+ flb_output_thread_pool_start(ins);
+ }
+
+ return 0;
+}
+
/* Return an instance name or alias */
const char *flb_output_name(struct flb_output_instance *ins)
{
@@ -979,21 +994,6 @@ int flb_output_init_all(struct flb_config *config)
return 0;
}
-/* Add thread pool for output plugin if configured with workers */
-int flb_output_enable_multi_threading(struct flb_output_instance *ins, struct flb_config *config)
-{
- /* Multi-threading enabled ? (through 'workers' property) */
- if (ins->tp_workers > 0) {
- if(flb_output_thread_pool_create(config, ins) != 0) {
- flb_output_instance_destroy(ins);
- return -1;
- }
- flb_output_thread_pool_start(ins);
- }
-
- return 0;
-}
-
/* Assign an Configuration context to an Output */
void flb_output_set_context(struct flb_output_instance *ins, void *context)
{
