The ceilometer.publisher.file Module

class ceilometer.publisher.file.FilePublisher(parsed_url)[source]

Bases: ceilometer.publisher.PublisherBase

Publisher metering data to file.

The publisher which records metering data into a file. The file name and location should be configured in ceilometer pipeline configuration file. If a file name and location is not specified, this File Publisher will not log any meters other than log a warning in Ceilometer log file.

To enable this publisher, add the following section to the /etc/ceilometer/publisher.yaml file or simply add it to an existing pipeline:

    name: meter_file
    interval: 600
        - "*"
        - file:///var/test?max_bytes=10000000&backup_count=5

File path is required for this publisher to work properly. If max_bytes or backup_count is missing, FileHandler will be used to save the metering data. If max_bytes and backup_count are present, RotatingFileHandler will be used to save the metering data.


Send an event message for publishing

Parameters:events – events from pipeline after transformation

Send a metering message for publishing

Parameters:samples – Samples from pipeline after transformation

Previous topic

The Module

Next topic

The ceilometer.publisher.http Module

Project Source

This Page