Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set generic metric names from moonshot exporter #107

Merged
merged 1 commit into from
Nov 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ log is based on the [Keep a CHANGELOG](http://keepachangelog.com/) project.
## Updated

- increase security context for kubernetes helm chart deployment [#102](https://github.com/Comcast/fishymetrics/issues/102)
- metric names in moonshot exporter to generic names as seen in other models [#106](https://github.com/Comcast/fishymetrics/issues/106)

## [0.12.1]

Expand Down
24 changes: 12 additions & 12 deletions exporter/moonshot/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,30 +40,30 @@ func NewDeviceMetrics() *map[string]*metrics {
}

ThermalMetrics = &metrics{
"fanSpeed": newServerMetric("thermal_fan_speed", "Current fan speed in the unit of percentage, possible values are 0 - 100", nil, []string{"name"}),
"fanStatus": newServerMetric("thermal_fan_status", "Current fan status 1 = OK, 0 = BAD", nil, []string{"name"}),
"sensorTemperature": newServerMetric("thermal_sensor_temperature", "Current sensor temperature reading in Celsius", nil, []string{"name"}),
"sensorStatus": newServerMetric("thermal_sensor_status", "Current sensor status 1 = OK, 0 = BAD", nil, []string{"name"}),
"fanSpeed": newServerMetric("redfish_thermal_fan_speed", "Current fan speed in the unit of percentage, possible values are 0 - 100", nil, []string{"name"}),
"fanStatus": newServerMetric("redfish_thermal_fan_status", "Current fan status 1 = OK, 0 = BAD", nil, []string{"name"}),
"sensorTemperature": newServerMetric("redfish_thermal_sensor_temperature", "Current sensor temperature reading in Celsius", nil, []string{"name"}),
"sensorStatus": newServerMetric("redfish_thermal_sensor_status", "Current sensor status 1 = OK, 0 = BAD", nil, []string{"name"}),
}

PowerMetrics = &metrics{
"supplyOutput": newServerMetric("power_supply_output", "Power supply output in watts", nil, []string{"name", "sparePartNumber"}),
"supplyStatus": newServerMetric("power_supply_status", "Current power supply status 1 = OK, 0 = BAD", nil, []string{"name", "sparePartNumber"}),
"supplyTotalConsumed": newServerMetric("power_supply_total_consumed", "Total output of all power supplies in watts", nil, []string{}),
"supplyTotalCapacity": newServerMetric("power_supply_total_capacity", "Total output capacity of all the power supplies", nil, []string{}),
"supplyOutput": newServerMetric("redfish_power_supply_output", "Power supply output in watts", nil, []string{"name", "sparePartNumber"}),
"supplyStatus": newServerMetric("redfish_power_supply_status", "Current power supply status 1 = OK, 0 = BAD", nil, []string{"name", "sparePartNumber"}),
"supplyTotalConsumed": newServerMetric("redfish_power_supply_total_consumed", "Total output of all power supplies in watts", nil, []string{}),
"supplyTotalCapacity": newServerMetric("redfish_power_supply_total_capacity", "Total output capacity of all the power supplies", nil, []string{}),
}

SwitchMetrics = &metrics{
"moonshotSwitchStatus": newServerMetric("moonshot_switch_status", "Current Moonshot switch status 1 = OK, 0 = BAD", nil, []string{"name", "serialNumber"}),
"moonshotSwitchStatus": newServerMetric("redfish_moonshot_switch_status", "Current Moonshot switch status 1 = OK, 0 = BAD", nil, []string{"name", "serialNumber"}),
}

SwitchThermalMetrics = &metrics{
"moonshotSwitchSensorTemperature": newServerMetric("moonshot_switch_thermal_sensor_temperature", "Current sensor temperature reading in Celsius", nil, []string{"name"}),
"moonshotSwitchSensorStatus": newServerMetric("moonshot_switch_thermal_sensor_status", "Current sensor status 1 = OK, 0 = BAD", nil, []string{"name"}),
"moonshotSwitchSensorTemperature": newServerMetric("redfish_moonshot_switch_thermal_sensor_temperature", "Current sensor temperature reading in Celsius", nil, []string{"name"}),
"moonshotSwitchSensorStatus": newServerMetric("redfish_moonshot_switch_thermal_sensor_status", "Current sensor status 1 = OK, 0 = BAD", nil, []string{"name"}),
}

SwitchPowerMetrics = &metrics{
"moonshotSwitchSupplyOutput": newServerMetric("moonshot_switch_power_supply_output", "Power supply output in watts", nil, []string{"name"}),
"moonshotSwitchSupplyOutput": newServerMetric("redfish_moonshot_switch_power_supply_output", "Power supply output in watts", nil, []string{"name"}),
}

Metrics = &map[string]*metrics{
Expand Down
Loading