flake8 new release 3.8.0 added new checks and gate pep8
job start failing. hacking 3.0.1 fix the pinning of flake8 to
avoid bringing in a new version with new checks.
Though it is fixed in latest hacking but 2.0 and 3.0 has cap for
flake8 as <4.0.0 which mean flake8 new version 3.9.0 can also
break the pep8 job if new check are added.
To avoid similar gate break in future, we need to bump the hacking min
version.
- http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014828.html
Change-Id: I4d54bfabc2faabd302b613378e49326de9a1cc8f
Now that we no longer support py27, we can use the standard library
unittest.mock module instead of the third party mock lib.
Change-Id: I8ac5e339700316b07b7c548f24ffc8dd83110df3
Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com>
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.
Fix problems found.
Change-Id: Ica99c9a4affd2b693ef74f1e3ef7c8ea2c6a46d6
As of Queens the Ceilometer V2 API has been removed. Storage
driver related code in monasca-ceilometer can thus be removed.
Backport some refactoring that came up in creating
https://review.openstack.org/#/c/562400/
Realized some class names could be clearer and fit better with
Ceilometer.
Update test-requirements.txt with Rocky release of
python-monascaclient. Also include more license info.
Specify py35 instead of py34 in tox.ini (gates already using py35).
Include updates to devstack configuration to keep up with master
ceilometer. These include adding values for the [monasca] section
in ceilometer.conf and refreshing setup.cfg as well as updating
how the connection url to Monasca API is configured.
Also include some testing notes in devstack/README.md
Change-Id: I9291dfc06d67f18109a0ff66184bd418c6361977
This commit is a follow-up of "switch to using stestr"
which was merged already [1].
After switch to using stestr, testrepository and .testr.conf
are unnecessary and should be removed.
[1] https://review.openstack.org/576862
Change-Id: I9f35e4f1341848a62a143b7f7150f2b845575861
Following changes are necessary to keep monasca-ceilometer
in sync with Ceilometer upstream
* Remove api/health.py (since ceilometer v2 api was removed)
* Remove storage/impl_monasca.py (since ceilometer storage drivers were removed)
* Updated opts.py and service.py (to keep in sync with ceilometer master)
* removed api, storage driver tests
* updated /etc/ceilometer/ceilometer.conf with new [monasca] options
Change-Id: I044f3e512db52a128bac8d5c5dcac76549a3b1c2
Ceilometer in Ocata made several changes to
move away from oslo config's global conf.
Instead ceilometer/service.py now creates a
oslo config object that gets passed to the
publisher.
To keep up with the changes had to make
the following changes in monasca-ceilometer
1.) Monasca Publisher now extends
ConfigPublisherBase, with conf as argument
2.) monasca_client now takes conf as an
argument during intialization.
3.) Added monasca_ceilometer_opts to
intialize all ConfigOpts. This will have
to be regiested in ceilometer/opts.py.
(will need a additional line in opts.py)
4.) Introduced three new properties
service_username, service_password and
service_auth_url since username, password
and auth_url were removed from
[service_credentials] section.
5.) Added api/health.py, service.py
and opts.py from ceilometer code base
which were modified to read
monasca ceilometer options via
monasca_ceilometer_opts.py
6.) Added ostestr to test requirements
and updated tox.ini to run tests in
serial (to avoid problems with
singleton mapping classes, stepping
on each other test values when
run in parallel)
List of Ceilometer changes to remove
global conf
[1] https://review.openstack.org/#/c/384834
[2] https://review.openstack.org/#/c/384624
[3] https://review.openstack.org/#/c/386025
This change also modifies test-requirements.txt
to bring this master branch up to the stable/pike
version of ceilometer, and python-monascaclient
up to 1.7.1 (pike).
Change-Id: Ieb7962a50fdb5d12ea6238c96ed116e8b2c83c48
Change the test-requirements to use the newton-eol branch, as
the stable/newton branch no longer exists in Ceilometer.
Also limit the oslotest to < 2.0.0 to avoid a mockpatch issue
in ceilometer's db.py unit test.
Note this change should soon be replaced by a move to Pike, but
want to update this as a solid starting point before further work.
Change-Id: I06b860bb72c3397e276311bd57291e9c3164a7e4
Since pbr already landed and the old version of hacking seems not
work very well with pbr>=2, we should update it to match global
requirement.
Partial-Bug: #1668848
Change-Id: Ib4989b9494ee8a4f2087f6986ee2dc0f798c1073
Adding capabilities to ceilosca to be able to query metrics that
are already being collected by monasca using mappings files
there are two types of mappings:
1. Static Mapping: Currently it is used to map any static info
about ceilometer meters like the type of meter or unit
2. Extensive monasca mapping: currently it is used to map any
monasca metric to a ceilometer meter example:
meter_metric_map:
- name: "disk.device.write.requests"
monasca_metric_name: "vm.io.write_ops"
resource_id: $.dimensions.resource_id
project_id: $.dimensions.tenant_id
user_id: $.dimensions.user_id
region: "NA"
type: "cumulative"
unit: "request"
source: "NA"
resource_metadata: $.measurement[0][2]
As you can see for this mapping fields on left side of ":"
are used to map ceilometer fields and fields on right side
for referring to monasca fields
Both of these mapping files are configurable and can be set in
ceilometer configuration file
cloud_name, cluster_name, and control plane fields
are now added as dimensions by monasca publisher when
publishing metrics to monasca api which is necessary
in multi-region deployment of notification agent.
monasca publisher does not use oslo.service LoopingCall
but instead uses futurist periodics library to enable
batching.
monasca client now pages through monasca api results
if enable_api_pagination is enabled in configuration.
This flag is disabled by default but should be enabled
if monasca api supports paging using "offsets"
parameter.
Tox testing is now targeting stable/newton branch of
ceilometer.
DocImpact
Change-Id: I83b96325cb79d82858cf529935e5d699a509f6c3
- Leverages monsaca devstack and uses new devstack plugin model
to setup ceilosca.
- Also some refactoring in directory structure
Change-Id: I097c86f92e1ec09ceeb3d0d4831ff8c51c3aa1a3
List of changes:
* Changed oslo-incubator imports to oslo-service
* Refactored tests to functional and unit packages
* Upgraded test requirement versions
* Added py34 test capability
* Upgraded hacking(pep8) version
* Added devstack plugin and settings to deploy Ceilosca
* Modified setup.cfg to use liberty entry points
* Refactored storage driver to compatible with v2 api liberty changes
Change-Id: Id6711e6661cde14df3decba6f56e52d391981f42
- Force pep8 to use correct python interpreter
- Add py27 checks
- Use smaller requirements file for pep8 checks
Change-Id: I4a2a642f60c17986739355187c67f403febb79fc