Browse Source

Replace ceilometer-dbsync by ceilometer-upgrade

https://review.openstack.org/#/c/388688/ has removed ceilometer-dbsync
and ceilometer-upgrade must be used instead.

Additionally, ceilometer-dbsync enabled option --skip-gnocchi-resource-types
and ceilometer-upgrade doesn't, so i'm setting it by default to
ensure backwards compatibility.

Closes-Bug: #1641076

Change-Id: I383fb7922e7984b067742e10a370b0d2f574dbe9
changes/70/396570/7
Alfredo Moralejo 6 years ago
parent
commit
af4af189ea
  1. 2
      manifests/db.pp
  2. 4
      manifests/db/sync.pp
  3. 2
      manifests/params.pp
  4. 5
      releasenotes/notes/replace-deprecated-ceilometer-dbsync-ddf62d90341731d7.yaml
  5. 4
      spec/classes/ceilometer_db_sync_spec.rb

2
manifests/db.pp

@ -41,7 +41,7 @@
# Defaults to $::os_service_default.
#
# [*sync_db*]
# (Optional) enable dbsync.
# (Optional) enable database schema installation.
# Defaults to true.
#
class ceilometer::db (

4
manifests/db/sync.pp

@ -1,12 +1,12 @@
# == Class: ceilometer::db::sync
#
# Class to execute ceilometer dbsync
# Class to execute ceilometer database schema creation
#
# === Parameters:
#
# [*extra_params*]
# (Optional) String of extra command line parameters
# to append to the ceilometer-dbsync command.
# to append to the ceilometer-upgrade command.
# Defaults to undef.
#
class ceilometer::db::sync(

2
manifests/params.pp

@ -6,7 +6,7 @@
class ceilometer::params {
include ::openstacklib::defaults
$dbsync_command = 'ceilometer-dbsync --config-file=/etc/ceilometer/ceilometer.conf'
$dbsync_command = 'ceilometer-upgrade --config-file=/etc/ceilometer/ceilometer.conf --skip-gnocchi-resource-types'
$expirer_command = 'ceilometer-expirer'
$user = 'ceilometer'
$event_pipeline = '/etc/ceilometer/event_pipeline.yaml'

5
releasenotes/notes/replace-deprecated-ceilometer-dbsync-ddf62d90341731d7.yaml

@ -0,0 +1,5 @@
---
fixes:
- In ocata cycle, ceilometer-dbsync has been removed
and ceilometer-upgrade must be used to create or
upgrade database schema and gnocchi resource types.

4
spec/classes/ceilometer_db_sync_spec.rb

@ -6,7 +6,7 @@ describe 'ceilometer::db::sync' do
it 'runs ceilometer-dbsync' do
is_expected.to contain_exec('ceilometer-dbsync').with(
:command => 'ceilometer-dbsync --config-file=/etc/ceilometer/ceilometer.conf ',
:command => 'ceilometer-upgrade --config-file=/etc/ceilometer/ceilometer.conf --skip-gnocchi-resource-types ',
:path => '/usr/bin',
:refreshonly => 'true',
:user => 'ceilometer',
@ -22,7 +22,7 @@ describe 'ceilometer::db::sync' do
end
it { is_expected.to contain_exec('ceilometer-dbsync').with(
:command => 'ceilometer-dbsync --config-file=/etc/ceilometer/ceilometer.conf --config-file=/etc/ceilometer/ceilometer_01.conf',
:command => 'ceilometer-upgrade --config-file=/etc/ceilometer/ceilometer.conf --skip-gnocchi-resource-types --config-file=/etc/ceilometer/ceilometer_01.conf',
:path => '/usr/bin',
:user => 'ceilometer',
:refreshonly => 'true',

Loading…
Cancel
Save