Project

General

Profile

Feature #7683

Collect ceph version per service. expose it through the API

Added by Christina Meno about 10 years ago. Updated about 10 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Backend (services)
Target version:
-
% Done:

0%

Source:
other
Tags:
Backport:
Reviewed:
Affected Versions:

Description

This information is useful to determine what version of ceph the processes are running.

History

#1 Updated by Christina Meno about 10 years ago

  • Tracker changed from Bug to Feature

#2 Updated by John Spray about 10 years ago

  • Target version deleted (v1.2 Backlog)

#3 Updated by John Spray about 10 years ago

How to implement

  1. The persistence.servers.service class has the attributes for services that we persist. Add one for version.
  2. The server_monitor.ServiceState class has the in-memory attributes for services. Add one setting version to None in init.
  3. The ceph.server messages from the ceph salt module include a 'version' attribute in each service.
  4. ServerMonitor.on_server_heartbeat iterates over the data from each service and calls _register_service for each one
  5. Add a version argument to register_service
  6. Where register_service calls persister.create_service for new services, add the version to the Service() instance passed in
  7. Add a conditional similar to those for 'status' and 'running' for the version attribute, so that it makes persister.update_service calls when the version changes, and sets the attribute on the ServiceState instance too.
  8. In ServerMonitor's dump and dump_cluster methods, add 'version' to the attributes we output for each service in the 'services' attribute of servers. Maybe pull this out to a "dump" method on ServerState to avoid duplication.
  9. In ServiceSerializer, add a field for 'version'.

Also available in: Atom PDF