diff options
| author | Steve Kemp <steve@steve.org.uk> | 2012-12-06 10:32:50 +0000 | 
|---|---|---|
| committer | Steve Kemp <steve@steve.org.uk> | 2012-12-06 10:32:50 +0000 | 
| commit | bddc6acb52bf5c7e0c4ed39c59f190b0acf2a706 (patch) | |
| tree | 359a5a344ca2e29e8dc2d61893ff7998fa1fccad /lib/custodian/alerts | |
| parent | 0eebd7294fabb999c809ae443d86a9a69d6364c4 (diff) | |
  We don't set the .detail field unless we're raising an alert.
  This will mean historically we can see what the failure reason was.
Diffstat (limited to 'lib/custodian/alerts')
| -rw-r--r-- | lib/custodian/alerts/mauve.rb | 17 | 
1 files changed, 9 insertions, 8 deletions
| diff --git a/lib/custodian/alerts/mauve.rb b/lib/custodian/alerts/mauve.rb index 300c90c..7c2c89d 100644 --- a/lib/custodian/alerts/mauve.rb +++ b/lib/custodian/alerts/mauve.rb @@ -175,13 +175,14 @@ module Custodian          alert.id      = "#{test_type}-#{test_host}"          alert.subject = subject          alert.summary = "The #{test_type} test failed against #{test_host}" -        alert.detail  = "<p>The #{test_type} test failed against #{test_host}.</p>"          #          #  If we're raising then add the error          #          if ( failure ) +          alert.detail  = "<p>The #{test_type} test failed against #{test_host}.</p>" +            #            #  The text from the job-defition            # @@ -196,14 +197,14 @@ module Custodian            # Add the test-failure message            #            alert.detail = "#{alert.detail}<p>#{test.error()}</p>" -        end -        # -        #  Determine if this is inside/outside the bytemark network -        # -        location = expand_inside_bytemark( test_host ) -        if ( !location.nil? && location.length ) -          alert.detail = "#{alert.detail}\n#{location}" +          # +          #  Determine if this is inside/outside the bytemark network +          # +          location = expand_inside_bytemark( test_host ) +          if ( !location.nil? && location.length ) +            alert.detail = "#{alert.detail}\n#{location}" +          end          end          # | 
