[Opsview-checkins] [opsview] [1757] Show message on Opsview …

Top Page
Delete this message
Reply to this message
Author: Commit messages for Opsview's subversion repository
Date:  
To: opsview-checkins
Subject: [Opsview-checkins] [opsview] [1757] Show message on Opsview reload page if rrd migration in progress



[opsview] [1757]
Show message on Opsview reload page if rrd migration in progress





Revision 1757
Author ton
Date 2008-12-03 11:44:24 +0000 (Wed, 03 Dec 2008)


Log Message
Show message on Opsview reload page if rrd migration in progress

Modified Paths

branches/DEV-opsview3/CHANGES
branches/DEV-opsview3/opsview-web/lib/Opsview/Web/Controller/Admin/Reload.pm
branches/DEV-opsview3/opsview-web/root/admin/reload/opsview




Modified: branches/DEV-opsview3/CHANGES
===================================================================
--- branches/DEV-opsview3/CHANGES    2008-12-03 11:31:47 UTC (rev 1756)
+++ branches/DEV-opsview3/CHANGES    2008-12-03 11:44:24 UTC (rev 1757)
@@ -3,7 +3,7 @@
3.0.beta1 ??
    Convert all mysql datetime fields into UTC
    nagiosgraph forked and now part of opsview-core package. Creates new style RRDs if the old ones do not exist
-    Old style RRDs are upgraded as part of the database upgrade process
+    Old style RRDs are upgraded as part of the database upgrade process. Opsview reload page will show message if migration is running
    Updated scriptaculous to 1.8.2

3.0.alpha1 24th November 2008

Modified: branches/DEV-opsview3/opsview-web/lib/Opsview/Web/Controller/Admin/Reload.pm
===================================================================
--- branches/DEV-opsview3/opsview-web/lib/Opsview/Web/Controller/Admin/Reload.pm    2008-12-03 11:31:47 UTC (rev 1756)
+++ branches/DEV-opsview3/opsview-web/lib/Opsview/Web/Controller/Admin/Reload.pm    2008-12-03 11:44:24 UTC (rev 1757)
@@ -32,6 +32,7 @@
use Fcntl;

my $reload_flag="/usr/local/nagios/var/rw/reload_flag";
+my $rrd_migration_flag="/usr/local/nagios/var/rrd_migration.flag";

sub auto :Private {
my ($self, $c) = @_;
@@ -50,6 +51,9 @@

sub opsview :Path {
my ($self, $c) = @_;
+ if (-e $rrd_migration_flag) {
+ $c->stash( rrd_migration_flag => 1 );
+ }
$c->stash( average_time => Opsview::Reloadtime->average_duration );
$c->stash(template => "opsview");
}

Modified: branches/DEV-opsview3/opsview-web/root/admin/reload/opsview
===================================================================
--- branches/DEV-opsview3/opsview-web/root/admin/reload/opsview    2008-12-03 11:31:47 UTC (rev 1756)
+++ branches/DEV-opsview3/opsview-web/root/admin/reload/opsview    2008-12-03 11:44:24 UTC (rev 1757)
@@ -196,6 +196,12 @@
<!--input type="button" name="[% c.loc("Restart Opsview") %]" value="[% c.loc("Restart Opsview") %]"
class="reload" onclick="Effect.Pulsate(this,{duration: 6}); restartOpsview()" /-->
</div>
+[% IF rrd_migration_flag %]
+<br/>
+<div class="warn_text">
+WARNING: RRD migration is in progress. See <a href="http://docs.opsview.org/doku.php?id=opsview3.0:upgrading_from_2.14#rrd_migration">documentation</a> for more details
+</div>
+[% END %]
<div id="warnings" class="warn_text" [% hide %]>
<h2>[% c.loc("Configuration errors detected during last reload") %]</h2>
<div id="config_errors"></div>