All declarative config parsing takes a long time

Bug #1550436 reported by Ilya Tyaptin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ceilometer
Fix Released
Undecided
Ilya Tyaptin

Bug Description

Currently the main user of our declarative config files is notification agent. So, it spends a lot of time to parse and init all declarative definitions which are defined in these config file. And the more workers the more spent time.

So, according to the profiling results the more time is spent to the parsing "fields" of traits and definitions in the ceilometer.declarative.Definition.__init__. It happens, because we parse all fields what are declared in the file and aren't paying attention to the fact what these files repeat many times.

From my PoV we can to cache parsing results for the next parsing if ExtentedJsonPathParser is not able to do it self.

Ilya Tyaptin (ityaptin)
Changed in ceilometer:
assignee: nobody → Ilya Tyaptin (ityaptin)
Changed in ceilometer:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ceilometer (master)

Reviewed: https://review.openstack.org/285431
Committed: https://git.openstack.org/cgit/openstack/ceilometer/commit/?id=024931b541f2c535dd2ca4f0deb300da47c801b0
Submitter: Jenkins
Branch: master

commit 024931b541f2c535dd2ca4f0deb300da47c801b0
Author: Ilya Tyaptin <email address hidden>
Date: Fri Feb 26 19:52:10 2016 +0300

    Cache getters for the decalarative definitions

    In the our declarative configs for the events and meters we use
    same fields for the many times. Despite this fact all fields are
    parsed by ExtentedJsonPathParser again and again.
    It affect time of notification agent starting and create additional
    cpu load.

    This patch is a trying to make this process faster and lighter.

    Change-Id: Ib190b5977688cdf48cc454ff133dd81ff5576310
    Closes-bug: #1550436

Changed in ceilometer:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.