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
This commit is contained in:
Alfredo Moralejo 2016-11-11 06:28:35 -05:00
parent 7c34dbff35
commit af4af189ea
5 changed files with 11 additions and 6 deletions

View File

@ -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 (

View File

@ -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(

View File

@ -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'

View File

@ -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.

View File

@ -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',