Emilien Macchi [Mon, 18 Jan 2016 17:30:34 +0000 (12:30 -0500)]
beaker: stop testing ceilometer-alarm
Ceilometer Alarm has been replaced by Aodh, and does not exist anymore
in Mitaka.
This change just stop testing the Puppet classes, but still allow to use
the classes.
Liao Penghui [Tue, 12 Jan 2016 16:34:27 +0000 (00:34 +0800)]
Move workers options into specific sections.
The notification_workers/api_workers/collector_workers options are
deprecated and should be set in [notification]/[api]/[collector]
sections separately.
Alex Schultz [Thu, 7 Jan 2016 04:28:00 +0000 (21:28 -0700)]
Add rspec-puppet-facts to the spec_helper
This change adds the rspec-puppet-facts gem to the spec helper so that
we can centralize the management of the base operating systems that we
support. rspec-puppet-facts allows us to simplify our unit tests and
provides a more complete list of Operating Systems and their associated
facts for the unit tests. With this change we can now loop over and
test CentOS, Debian, Fedora, RedHat, and Ubuntu by simply providing a
list of supported os to rspec-puppet-facts.
Additionally this change includes a central object for managing our
supported os list for rspec-puppet-facts and providing our default facts
like os_service_default. This central object should replace the usage of
@default_facts within the unit tests for each module.
Ben Kero [Fri, 8 Jan 2016 02:41:57 +0000 (18:41 -0800)]
Add required db subclass to README.md
This commit adds the ::ceilometer::db subclass to the example in README.md.
The README.md should contain a working pseudo-minimal example for basic
ceilometer installation. At some point the 'db' subclass was required
for basic usage.
Without this class applying the example in README.md is unusable,
erroring out with this:
> Error: Could not find dependency Class[Ceilometer::Db] for
> Service[ceilometer-api] at
> /etc/puppet/modules/ceilometer/manifests/api.pp:112
Emilien Macchi [Tue, 22 Dec 2015 15:41:03 +0000 (16:41 +0100)]
deprecate mongodb_replica_set parameter
mongodb_replica_set parameter has been dropped in Mitaka [1] and has no
effect anymore.
This patch deprecated our interface by sending a warning if the param is
set. If set, it has no effect though, since the param does not exist
anymore upstream.
Emilien Macchi [Mon, 21 Dec 2015 18:29:58 +0000 (19:29 +0100)]
unit tests: make Keystone_endpoint match service by name/type
Since a chance in puppet-keystone (1], we now match an endpoint with a
service name/type.
)
[1] http://git.openstack.org/cgit/openstack/puppet-keystone/commit/?id=0a4e06abb0f5b3f324464ff5219d2885816311ce
Ability to configure api, collector and notification workers
We've been missing ability to configure two options:
- collector_workers, number of workers for collector service.
- notification_workers, number of workers for notification service.
- api_workers, number of workers for api service.
Co-Authored-By: Ivan Berezovskiy <iberezovskiy@mirantis.com>
Change-Id: Ifc1f1623289560f873442a702a23a5cc1c831c72
iberezovskiy [Thu, 19 Nov 2015 12:17:03 +0000 (15:17 +0300)]
Support of PyMySQL driver for MySQL backend
Add ability to use python-pymysql library
as backend for MySQL connections.
Update acceptance tests to use pyMySQL.
Docs: https://wiki.openstack.org/wiki/PyMySQL_evaluation
The same implementation as it's done for keystone:
https://review.openstack.org/#/c/242134/
Emilien Macchi [Fri, 27 Nov 2015 11:11:01 +0000 (12:11 +0100)]
Implement Gnocchi dispatcher
* Add dispatcher options to ceilometer::collector.
* Create ceilometer::dispatcher::gnocchi class, with current upstream options.
* Add an example of manifest.
* Unit & functional tests.
Note:
This patch implement os_service_defaults only for the new class.
For collector, it will be updated in one patch in another patchset.
Sebastien Badia [Tue, 20 Oct 2015 13:37:09 +0000 (15:37 +0200)]
db: Use postgresql lib class for psycopg package
This patch introduce the same design than mysql for postgresql
by requiring dedicated lib::python class instead of declaring
a new resource package within ceilometer module.
compile and compile.with_all_deps rpsec matchers make
a call to all facts, and especially the ec2 one (this fact, try
to make a connection on the IPv4 link-local for ec2 metadata which
is incompatible with webmock restrictions), this seems to produce
random errors with puppet 3.{3,4}.x and facter 1.7.6.
Emilien Macchi [Thu, 8 Oct 2015 21:37:08 +0000 (14:37 -0700)]
Try to use zuul-cloner to prepare fixtures
In OpenStack Infra, we would like to run Puppet unit tests that
sometimes depends on other Puppet OpenStack modules.
Example: a patch in puppet-openstacklib that needs to be tested in puppet-nova.
This patch modifies the Rakefile to:
* clean spec_prep and spec_clean Rake tasks
* use openstack/puppet-openstack-integration/install_modules_unit.sh script
to clone modules.
* do not use .fixtures.yaml file to clone modules and rely on
zuul-cloner or git.
* Add openstack/ in gitignore so we never commit the
puppet-openstack-integration repository (can happen when spec_clean
did not run but you want to submit the patch anyway)
* Allow to run a custom Puppetfile if PUPPETFILE env is exported. It
will allow people to test the module with the dependencies they like,
feature we had with .fixtures.yaml.
Also add 'r10k' to Gemfile.
That way, we will be able to use zuul dependencies and run tests accross
modules like we do with functional testing.
Emilien Macchi [Fri, 2 Oct 2015 20:17:25 +0000 (16:17 -0400)]
auth: drop service dependency for Keystone_user_role
Drop service dependency for Keystone_user_role.
Without that patch, Ceilometer & Keystone running in WSGI will fail to compile
the catalog because a dependency cycle:
Anchor[keystone_started] => Keystone_user_role[ceilometer@services] =>
Service[ceilometer-api] => Service[httpd] => Anchor[keystone_started]
The dependency is not really useful because it does not prevent the
service to start.
wsgi: make sure eventlet process is stopped before httpd
When stopping Ceilometer API running eventlet (ceilometer-api service),
we need to make sure it's done *before* starting Apache.
Otherwise, there is a race condition where Apache could be started before
stopping the service, and what would lead to:
AH00072: make_sock: could not bind to address [::]:8777
AH00072: make_sock: could not bind to address 0.0.0.0:8777
no listening sockets available, shutting down
Apache fails to start.
This patch make sure we have the right orchestration in place.
This already exists in the db::sync class for all services tagged
with ceilometer-service. Removing it from here will allow the api
service on a HA controller where the dbsync isn't run.
Back in history, we tried to configure something in nova.conf which is
now managed by puppet-nova. It causes the module conflicting with
puppet-nova and makes Puppet runs not idempotent and nova.conf with
wrong parameters.
Update ceilometer::db class to match other module pattern
This review aims to update the ceilometer::db class to standardize it with the
other modules db classes[1][2]. It now offers the same parameters to customize database
connection behavior.
RDO:
This patch changes the repositories used to install OpenStack Liberty on
RDO by using CBS repositories and RDO trunk.
Here is the RDO roadmap that is suggested if we want to run Liberty:
From now until GA:
http://trunk.rdoproject.org/centos7-liberty/current/
http://cbs.centos.org/repos/cloud7-openstack-liberty-testing/x86_64/os/
http://cbs.centos.org/repos/cloud7-openstack-common-testing/x86_64/os/
After GA:
http://mirror.centos.org/centos/7/cloud/x86_64/openstack-liberty
Note about EPEL: deps from EPEL are rebuilt in CBS, so EPEL could be
disabled in the future.
UCA:
Since our recent discussion about Ubuntu packaging, we decided to bump
Ubuntu packaging to trusty-proposed/liberty so we can install Liberty in
a better shape than current situation (Staging repo). This patch
installs UCA liberty repository.
This variable is cast to a string to avoid validate_re() breaking, but
puppet-lint gives a warning for a string containing only a variable.
This disables the warning for this line only.
Emilien Macchi [Sun, 23 Aug 2015 14:36:58 +0000 (10:36 -0400)]
acceptance/eventlet: make sure apache is stopped
When testing upgrades, we have some cases where we apply the wsgi
manifest first and then eventlet. The problem is apache which is
started so ceilo-api cannot be started because ports are already in use.
So this patch installs Apache on eventlet manifest and makes sure
the service is stopped before trying to start ceilo-api with eventlet.
Yanis Guenane [Thu, 6 Aug 2015 11:05:21 +0000 (13:05 +0200)]
Reflect provider change in puppet-openstacklib
With the creation of the new openstack_config provider, some processing
that was done in ceilometer_config has been centralized in
openstack_config.
Impacted methods are :
* section
* setting
* separator
Also, this commit adds the fact that, when passing a specific string
(ensure_absent_val) the provider will behave as if ensure => absent was
specified. '<SERVICE DEFAULT>' is the default value for
ensure_absent_val.
The use case is the following :
ceilometer_config { 'DEFAULT/foo' : value => 'bar' } # will work as usual
ceilometer_config { 'DEFAULT/foo' : value => '<SERVICE DEFAULT>' } # will mean absent
Emilien Macchi [Sun, 16 Aug 2015 13:50:01 +0000 (09:50 -0400)]
acceptance: enable debug & verbosity for OpenStack logs
Enable debug & verbose when possible for OpenStack services logs, so we can read a maximum
of informations in Jenkins jobs logs and easily debug our eventual failures.
In order to standardize the way dbsync are run across our modules,
we create a new class ceilometer::db::sync.
This class will be included if sync_db is enabled.
By making this transition the ceilometer::db::sync can be returned
by the ENC.
A use case would be in an highly available environment, with 3 galera
nodes, include ceilometer::db on every node with sync_db set to false
and have the ENC return ceilometer::db::sync just for one node.
Emilien Macchi [Wed, 5 Aug 2015 02:36:47 +0000 (22:36 -0400)]
WSGI: make it work, and test it with acceptance
* Finalize httpd service name support in API class following
puppet-keystone model.
* Implement unit tests.
* Implement separated acceptance tests that deploy Ceilometer API in
WSGI.
This patch aims to finalize and validate we can deploy Ceilometer API in
WSGI with puppet-ceilometer.
Also that we can update from eventlet to WSGI (it's tested in our beaker jobs).
Yanis Guenane [Wed, 12 Aug 2015 07:45:38 +0000 (09:45 +0200)]
Rely on autorequire for config resource ordering
Currently we specify the ordering of config resources wherever it is
necessary based on the presence of the file it will write to, or the
presence of the package in charge of providing the file it will write
to.
Those kind of ordering can be specified directly at the resource level
using the autorequire mechanism. With this patch, any config resource
will make sure the package in charge of providing the file will be
installed first.
Sebastien Badia [Tue, 4 Aug 2015 13:37:05 +0000 (15:37 +0200)]
Initial msync run for all Puppet OpenStack modules
This patch is the initial modulesync run, it impact:
* gitignore: just a sync between projects
* gemfile:
- update and allow to setup facter version and gem source
- split beaker gems with a dedicated group
- switch to rspec-puppet 2.2.0
* rakefile:
- use the new syntax for lint configuration
- add a acceptance target
* acceptance:
- sync nodesets
* spec: added rspec coverage report