Unknown macro: {next_previous_links}
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

WSO2 DAS supports Apache HBase and Apache HDFS for its underlying Data Access Layer (DAL). To use this HBase DAL component, a pre-configured installation of Apache HBase (version 1.1.2 and upwards) running on top of Apache Hadoop (version 2.6.0 and upwards) is required. 

The HBase DAL component uses Apache HBase for storing events (Analytics Record Store), and HDFS (the distributed file system used by Apache Hadoop) for storing index information (Analytics File System). You  have the option of specifying either or both of these implementations in their deployment. For example, you can specify HBase for storing events, and use a relational storage solution for storing index-related information.

The following sections describe both implementations of the HBase DAL component.

The HBase datasource does not support pagination or record count.

It is required that all HBase/HDFS nodes and all DAS nodes are time synced. Utilities such as ntpd could be used for this purpose.

Enabling the HBase datasource provider

In order to use HBase as the record store, the HBase datasource provider should be enabled as follows.

  1. Open the <DAS_HOME>/repository/conf/datasources/analytics-datasources.xml file.  The HBase datasource provider is commented out by default as shown below.

    <!--<provider>org.wso2.carbon.datasource.reader.hadoop.HBaseDataSourceReader</provider>-->
  2. Uncomment the HBase datasource provider as shown below.

    <provider>org.wso2.carbon.datasource.reader.hadoop.HBaseDataSourceReader</provider>

Configurations for the Analytics Record Store

For configuring HBase as the underlying datasource implementation for the Analytics Record Store, specify the HBase configurations in the <DAS_HOME>repository/conf/analytics/analytics-config.xml file as shown in the below example. 

<analytics-record-store name="EVENT_STORE">
    <implementation>org.wso2.carbon.analytics.datasource.hbase.HBaseAnalyticsRecordStore</implementation>
    <properties>
		<!-- the data source name mentioned in data sources configuration -->
        <property name="datasource">WSO2_ANALYTICS_RS_DB_HBASE</property>
    </properties>
</analytics-record-store>

The properties of the above configurations are described below.

PropertyDescription
<implementation>
The implementation class of the Analytics Record Store relevant for HBase, which is org.wso2.carbon.analytics.datasource.hbase.HBaseAnalyticsRecordStore. 
<property name="datasource">
The Carbon datasource name of the type "HBASE", which is used to look up to find the associated HBase data source.

Configurations for the Analytics File System

For configuring HBase as the underlying datasource implementation for the Analytics File System, specify the HDFS configurations in the <DAS_HOME>repository/conf/analytics/analytics-config.xml file as shown in the below example.

<analytics-file-system>
    <implementation>org.wso2.carbon.analytics.datasource.hbase.HDFSAnalyticsFileSystem</implementation>
    <properties>
        <!-- the data source name mentioned in data sources configuration -->
        <property name="datasource">WSO2_ANALYTICS_FS_DB_HDFS</property>
    </properties>
</analytics-file-system>

The properties of the above configurations are described below.

PropertyDescription
<implementation>
The implementation class of the Analytics File System relevant for HDFS, which is org.wso2.carbon.analytics.datasource.hbase.HDFSAnalyticsFileSystem.
<property name="datasource">
The Carbon datasource name of the type "HDFS", which is used to look up to find the associated HDFS data source.

Configuring the datasources

You need to define datasources to connect to the above underlying HBase and HDFS implementations as described below. 

Configuring the datasource for the Analytics Record Store 

Change the configurations of the WSO2_ANALYTICS_EVENT_STORE_DB datasource in the <DAS_HOME>/repository/conf/datasources/analytics-datasources.xml file accordingly. For information on the datasource configurations, see Configuring a HBase Datasource.

Configuring the datasource for the Analytics File System datasource

Change the configurations of the WSO2_ANALYTICS_FS_DB datasource in the <DAS_HOME>/repository/conf/datasources/analytics-datasources.xml file accordinglyFor information on the datasource configurations, see Configuring a HDFS Datasource.

  • No labels