Project

General

Profile

« Previous | Next » 

Revision e54016da

Added by Marek Hulán over 8 years ago

Fixes #10782 - global host status

Introduce new global host status that is composed of host substatuses.
Each substatus defines a mapping to the global one which can result in
three values
  • OK
  • WARN
  • ERROR

Plugins can add their own substatuses. These are automatically
propagated also to API.

Thanks to Tomas Strachota who wrote the original code.

View differences:

app/controllers/application_controller.rb
# If the user has a fact_filter then we need to include :fact_values
# We do not include most associations unless we are processing a html page
def included_associations(include = [])
include += [:hostgroup, :compute_resource, :operatingsystem, :environment, :model ]
include
include + [ :hostgroup, :compute_resource, :operatingsystem, :environment, :model, :host_statuses ]
end
def errors_hash(errors)

Also available in: Unified diff