public class MigrateAggregateMetrics extends Object implements Step
Migrates aggregate metrics from the one_hour_metrics, six_hour_metrics, and twenty_four_hour_metrics tables to the new aggregate_metrics table. The failure to migrate data for a single measurement schedule will result in an exception being thrown that causes the upgrade to fail; however, all schedules will be processed even if there are failures. An exception is thrown only after going through data for all schedules.
When data for a measurement schedule is successfully migrated, the schedule id is recorded in a log. There are separate log files for each of the 1 hour, 6 hour, and 24 hour tables. They are stored in the server data directory. Each table log is read prior to starting the migration to determine what schedule ids have data to be migrated.
After all data has been successfully migrated, the one_hour_metrics, six_hour_metrics, and twenty_four_hour_metrics tables are dropped.
| Constructor and Description |
|---|
MigrateAggregateMetrics() |
| Modifier and Type | Method and Description |
|---|---|
void |
bind(Properties properties)
Bind the set of provided properties to the input step.
|
void |
execute()
Perform the actual work of the step.
|
void |
setSession(com.datastax.driver.core.Session session)
Invoked prior to
Step.execute(). |
String |
toString() |
public void setSession(com.datastax.driver.core.Session session)
StepStep.execute(). Note that this is the same session used by SchemaManager and it
should not be closed.setSession in interface Steppublic void bind(Properties properties)
StepBind the set of provided properties to the input step. The text should have all the variable to be bound in %variable_name% form.
This method should be called even if no properties are provided because it will throw a runtime exception if the text contains properties that are expected to be bound but the list of variable is either empty or does not contain them.
This method is invoked prior to Step.execute()
Copyright © 2008-2014 Red Hat, Inc.. All Rights Reserved.