out_forward: migrate to new flush callback prototype
out_forward: migrate to new flush callback prototype

In a recent change the prototype of the flush function (callback)
for output plugins has changed:

  --
  On this patch we change the callback prototype, before we used to pass
  different parameters as msgpack buffer, it size, tag, tag, len, input
  instance, output context and Fluent Bit context.

  While extending Fluent Bit some plugins might need access to other type
  of information, but changing the prototype of the function is very
  expensive in terms of maintenance; for simplicity reasons now we pass
  two new 'structure' arguments that consolidate the information (and also
  help us to add more info later without general plugins maintenance cost.

  The new prototype is:

  void (*cb_flush) (struct flb_event_chunk *,    // new struct flb_event_chunk
                    struct flb_output_flush *,   // new struct flb_output_flush
                    struct flb_input_instance *, // origin input instance
                    void *,                      // plugin custom context
                    struct flb_config *);        // Fluent Bit context

  The structure flb_event_chunk concentrate most of the chunk information plus
  other items such as counter for the number of events and a Tag in sds format.

  The other flb_output_flush argument is added and explained below.
  --

This patch modifies the current plugin flush callback prototype and adjust the
internals to use the new structure flb_event_chunk to gather message type,
buffer, size and tag.

Signed-off-by: Eduardo Silva <81f705dc2ce1a61a2621e0e4b442a9474e1d0c70@calyptia.com>

fluent/fluent-bit,fluent/fluent-bit,nokute78/fluent-bit,nokute78/fluent-bit,nokute78/fluent-bit,nokute78/fluent-bit,nokute78/fluent-bit,fluent/fluent-bit,fluent/fluent-bit,fluent/fluent-bit,nokute78/fluent-bit,fluent/fluent-bit,fluent/fluent-bit,fluent/fluent-bit,fluent/fluent-bit,nokute78/fluent-bit,fluent/fluent-bit,fluent/fluent-bit,nokute78/fluent-bit,nokute78/fluent-bit,nokute78/fluent-bit,nokute78/fluent-bit,fluent/fluent-bit,nokute78/fluent-bit