WSO2 DAS introduces the ability to have a pluggable Data Access Layer (DAL).
Analytics Record Store
The Analytics Record Store is the section that handles the storing of records that are received by WSO2 DAS in the form of events. This store contains raw data relating to events in a tabular form to be retrieved later.
The following record stores are configured in the
<DAS_HOME>/repository/conf/analytics/analytics-config.xml file by default.
|Record Store Type||Default Name||Description|
|Primary Store||This record store is used to store the persisted incoming events of WSO2 DAS. It contains raw data in a tabular structure which can be used later.|
|Processed Data Store||This record store is used to store summarized event data.|
Configuring a record store
The following is a sample configuration of a record store.
The following needs to be specified for each record store.
- Name: A unique name for the record store.
- Implementation: This specifies the implementation for the record store, this class should be implementing the interface "org.wso2.carbon.analytics.datasource.core.rs.AnalyticsRecordStore". For the record store to function, the provider for the datasource type mentioned in this implementation should be enabled in the
Record store specific properties: The properties that are defined per record store are described in the table below.
The name of the datasource used to connect to the database used by the record store.
Once a record store is configured in the
analytics-config.xml file, you can select it as the record store for the required event streams. For more information, see Persisting Data for Interactive Analytics.
By default, WSO2 DAS executes indexing operation when the server is started. The following system property can be used to disable the indexing operations if required.
- For Windows:
- Fow Linux:
This option allows you to create servers that are dedicated for specific operations such as event receiving, analytics, indexing, etc.
Configuring common parameters
Data purging parameters
|This parameter specifies whether the functionality to purge data from event tables is enabled or not.|
|A regex expression to select the tables from which data should be purged.|
|A list of event tables from which data should be purged can be defined as subelements of this element.|
|The number of days for which the data should be retained in the event tables that were selected to have their data purged. All the data in these tables are cleared once the number of days that equal the value specified for this parameter have elapsed.|
The implementation of the Analytics Lucene Analyzer is defined as a subelement of this parameter.
|The index data replication factor to be used in clustered mode. This tells how many replicas that should be kept when indexing operations are done. 0 means, no replication. It should be set to 1 or higher to have high availability.||1|
The number of index shards the server should maintain per cluster. This fine tunes the scaling nature of the indexing cluster.
This parameter can only be set once for the lifetime of the cluster, and cannot be changed later on.
|The amount of index data (in bytes) to be processed at a time by a shard index worker. Minimum value is 1000.|
The interval in milliseconds during which a shard index processing worker thread will sleep during index processing operations. This parameter together with the
The number of index workers to operate in the current node. This basically results in the number of execution threads created to do the indexing operations of the local shards. When this value is increased, the parallel I/O operations being done on the system grows larger. So a system which can handle parallel I/O operation could increase this, e.g. SSDs.
Removing persisted data
The following two methods can be used to clear all the event data (both processed and unprocessed events) from the database.
- Run the Analytics Data Backup / Restore Tool with the
-deleteTablesargument, specifying the list of event tables for which you want to clear data. For more information, see Analytics Data Backup / Restore Tool.
Clean your database, and remove the contents in the
<DAS_HOME>/repository/datadirectory at the same time.
Cleaning a database while retaining data in the
<DAS_HOME>/repository/datadirectory does not result in permanently removing the persisted data.
If you want to clear only index data, see Configuring Indexes - Removing index data.