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

Commit

Permalink
Merge branch 'master' of github.com:rhq-project/rhq
Browse files Browse the repository at this point in the history
  • Loading branch information
jshaughn committed Apr 21, 2014
2 parents 7e9ce1d + a329de9 commit 1bc9904
Showing 1 changed file with 10 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -250,9 +250,10 @@ public String getInstallationResults() throws Exception {
}

// its possible the ear is not yet deployed (during server init/startup, it won't show up)
// but our extension should always show up and its one of the last things our installer deploys.
// if this doesn't exist, our installation isn't done yet
if (isExtensionDeployed()) {
// but our marker file should exist (since its the last thing the installer will write).
// If the marker file exists, we can assume the installer is done and we just have to wait.

if (getInstalledFileMarker().exists()) {
return ""; // installer has done all it could - just need to wait for the EAR to fully startup
}

Expand Down Expand Up @@ -1249,12 +1250,17 @@ private SchemaManager createStorageNodeSchemaManager(Map<String, String> serverP
return new SchemaManager(username, password, nodes, cqlPort);
}

private void writeInstalledFileMarker() throws Exception {
private File getInstalledFileMarker() throws Exception {
File datadir = new File(getAppServerDataDir());
if (!datadir.isDirectory()) {
throw new IOException("Directory Not Found: [" + datadir.getPath() + "]");
}
File markerFile = new File(datadir, "rhq.installed");
return markerFile;
}

private void writeInstalledFileMarker() throws Exception {
File markerFile = getInstalledFileMarker();
markerFile.createNewFile();
}
}

0 comments on commit 1bc9904

Please sign in to comment.