Wednesday, October 14, 2015

Purging Cassandra data in WSO2 BAM 2.5.0


WSO2 BAM is capable of monitoring a wide range of business activities. BAM allows users to perform following operations to the data.
  • Aggregate
  • Analyze
  • Present
  • Purge

In this post I am going to talk about data purging task performed by BAM. It is really simple to schedule a data purging/deleting task in BAM 2.5.0. Follow the below steps to create a data deletion task.

Step 01

Download WSO2 BAM 2.5.0. navigate to <BAM_HOME>/bin and start the server using wso2server.sh script. Login using admin:admin credentials.

Step 02

Go to Configure tab in the left bar and you will get the following .


Add Archive/Purge Data.


Add the stream name and version which you need to delete data from. I have given the retention period as 1 day.

And here we can specify a cron expression which schedules the task. In my cron expression the task will trigger for each minute.
Please refer to the following table to get more information on cron expressions. And also please note that the we are using quartz scheduler cron expressions.

Field Name Allowed Values Allowed Special Characters
Seconds 0-59 , - * /
Minutes 0-59 , - * /
Hours 0-23 , - * /
Day of month 1-31 , - * ? / L W
Month 1-12 or JAN-DEC , - * /
Day of week 1-7 or SUN-SAT , - * ? / L #
Year empty, 1970-2099 , - * /

0 comments:

Post a Comment