oslo_reports.generators package

Submodules

oslo_reports.generators.conf module

Provides OpenStack config generators

This module defines a class for configuration generators for generating the model in oslo_reports.models.conf.

class oslo_reports.generators.conf.ConfigReportGenerator(cnf=<oslo_config.cfg.ConfigOpts object>)

Bases: object

A Configuration Data Generator

This generator returns oslo_reports.models.conf.ConfigModel, by default using the configuration options stored in oslo_config.cfg.CONF, which is where OpenStack stores everything.

Parameters:

cnf (oslo_config.cfg.ConfigOpts) – the configuration option object

oslo_reports.generators.process module

Provides process-data generators

This modules defines a class for generating process data by way of the psutil package.

class oslo_reports.generators.process.ProcessReportGenerator

Bases: object

A Process Data Generator

This generator returns a oslo_reports.models.process.ProcessModel based on the current process (which will also include all subprocesses, recursively) using the psutil.Process class`.

oslo_reports.generators.threading module

Provides thread-related generators

This module defines classes for threading-related generators for generating the models in oslo_reports.models.threading.

class oslo_reports.generators.threading.GreenThreadReportGenerator

Bases: object

A Green Thread Data Generator

This generator returns a collection of oslo_reports.models.threading.GreenThreadModel objects by introspecting the current python garbage collection state, and sifting through for greenlet.greenlet objects.

See also

Function _find_objects()

class oslo_reports.generators.threading.ThreadReportGenerator(curr_thread_traceback=None)

Bases: object

A Thread Data Generator

This generator returns a collection of oslo_reports.models.threading.ThreadModel objects by introspecting the current python state using sys._current_frames() . Its constructor may optionally be passed a frame object. This frame object will be interpreted as the actual stack trace for the current thread, and, come generation time, will be used to replace the stack trace of the thread in which this code is running.

oslo_reports.generators.version module

Provides OpenStack version generators

This module defines a class for OpenStack version and package information generators for generating the model in oslo_reports.models.version.

class oslo_reports.generators.version.PackageReportGenerator(version_obj)

Bases: object

A Package Information Data Generator

This generator returns oslo_reports.models.version.PackageModel, extracting data from the given version object, which should follow the general format defined in Nova’s version information (i.e. it should contain the methods vendor_string, product_string, and version_string_with_package).

Parameters:

version_object – the version information object

Module contents

Provides Data Model Generators

This module defines classes for generating data models ( oslo_reports.models.base.ReportModel ). A generator is any object which is callable with no parameters and returns a data model.