Skip to content
This repository has been archived by the owner on Jul 11, 2022. It is now read-only.

Commit

Permalink
[BZ 1082805] Simplify the upgrade options for the data migration. Onl…
Browse files Browse the repository at this point in the history
…y allow to run the data migration. For a fine control over the upgrade process prompt the users to the migration tool directly.
  • Loading branch information
Stefan Negrea committed Oct 1, 2014
1 parent d583b23 commit ba48a62
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .classpath
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@
<classpathentry kind="var" path="M2_REPO/com/fasterxml/jackson/core/jackson-databind/2.1.1/jackson-databind-2.1.1.jar"/>
<classpathentry kind="var" path="M2_REPO/com/fasterxml/jackson/core/jackson-core/2.1.1/jackson-core-2.1.1.jar"/>
<classpathentry kind="var" path="M2_REPO/com/codahale/metrics/metrics-core/3.0.1/metrics-core-3.0.1.jar"/>
<classpathentry kind="var" path="M2_REPO/com/datastax/cassandra/cassandra-driver-core/1.0.8/cassandra-driver-core-1.0.8.jar"/>
<classpathentry kind="var" path="M2_REPO/com/datastax/cassandra/cassandra-driver-core/1.0.8-jboss-1/cassandra-driver-core-1.0.8-jboss-1.jar"/>
<classpathentry kind="var" path="M2_REPO/com/jolbox/bonecp/0.8.0.RELEASE/bonecp-0.8.0.RELEASE.jar"/>
<classpathentry kind="var" path="M2_REPO/io/undertow/undertow-core/1.0.15.Final/undertow-core-1.0.15.Final.jar"/>
<classpathentry kind="var" path="M2_REPO/com/yammer/metrics/metrics-core/2.2.0/metrics-core-2.2.0.jar"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,11 @@ public Upgrade() {
.addOption(
null,
RUN_DATA_MIGRATION,
true,
false,
"This option is valid only when upgrading from older systems that did not have storage nodes. The existing metric data needs to migrate to "
+ "the metric storage. The upgrade process can trigger this or give you an estimate on the duration. If you want "
+ "to have fine control over the process, please run the migrator on the command line. Options are none (do "
+ "nothing), estimate (estimate the migration time only), print-command (print the command line for a manual run), "
+ "do-it (run the migration)");
+ "the metric storage. This option completes the data migration process as part of the upgrade. If you want "
+ "to have fine control over the process (eg: run it a later time, get an estimate first, purge data from the SQL database after migration), "
+ "please run the data migrator on the command line.");
}

@Override
Expand Down Expand Up @@ -247,10 +246,6 @@ private int runDataMigration(CommandLine rhqctlCommandLine) {
try {
org.apache.commons.exec.CommandLine commandLine = getCommandLine("rhq-data-migration");
commandLine.addArgument("-X");
if (migrationOption.equals("estimate")) {
commandLine.addArgument("--estimate-only");
}

int exitValue = ExecutorAssist.execute(new File(getBaseDir(), "bin"), commandLine);
log.info("The data migrator finished with exit value " + exitValue);
rValue = exitValue;
Expand Down

0 comments on commit ba48a62

Please sign in to comment.