org.apache.flume.sink.hbase

## Interface HbaseEventSerializer

- All Superinterfaces:
    Configurable, ConfigurableComponent
  All Known Implementing Classes:
    RegexHbaseEventSerializer, SimpleHbaseEventSerializer

      public interface HbaseEventSerializer
      extends Configurable, ConfigurableComponent

  Interface for an event serializer which serializes the headers and body of an event to write them to hbase. This is configurable, so any config params required should be taken through this. Only the column family is passed in. The columns should exist in the table and column family specified in the configuration for the HbaseSink.

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()`
    `List<org.apache.hadoop.hbase.client.Row>` | `getActions()` Get the actions that should be written out to hbase as a result of this event.
    `List<org.apache.hadoop.hbase.client.Increment>` | `getIncrements()`
    `void` | `initialize(Event event, byte[] columnFamily)` Initialize the event serializer.

    - ### Methods inherited from interface org.apache.flume.conf.Configurable

      `configure`

    - ### Methods inherited from interface org.apache.flume.conf.ConfigurableComponent

      `configure`

- - ### Method Detail

    - #### initialize

          void initialize(Event event,
                        byte[] columnFamily)

      Initialize the event serializer.
      Parameters:
        `event` - Event to be written to HBase
        `columnFamily` - Column family to write to

    - #### getActions

          List<org.apache.hadoop.hbase.client.Row> getActions()

      Get the actions that should be written out to hbase as a result of this event. This list is written to hbase using the HBase batch API.
      Returns:
        List of `Row` which are written as such to HBase. 0.92 increments do not implement Row, so this is not generic.

    - #### getIncrements

          List<org.apache.hadoop.hbase.client.Increment> getIncrements()

    - #### close

          void close()

Copyright © 2009-2016 Apache Software Foundation. All Rights Reserved.