Currently, specifying a cells_config file in nova.conf causes
CellStateManager to fail and in turn stops the nova-cells service from
starting. The reason is that CellsManager creates an instance of
CellStateManager with no arguments. CellStateManager __new__ runs and
creates an instance of CellStateManagerFile which runs __new__ and
__init__ with cell_state_cls and cells_config_path set. At this point
__new__ returns CellStateManagerFile and the new instance's __init__
method is invoked (CellStateManagerFile.__init__) with the original
arguments (there weren't any) which then results in:
2014-04-29 11:52:05.240 16759 TRACE nova self.state_manager =
cell_state_manager()
2014-04-29 11:52:05.240 16759 TRACE nova TypeError: __init__() takes
exactly 3 arguments (1 given)
It seems reasonable for CellStateManagerFile to derive the
cells_config_path info for itself so I have updated the code with that
change and added unit tests to catch this bug and to check that the
correct managers are still returned
Closes-Bug: #1314677
(cherry picked from commit 695191fa89387d96e60120ff32965493c844e7f5)
Reviewed: https:/ /review. openstack. org/124811 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=bfeae680bc0 632e0129b647d45 e4b80328a33535
Committed: https:/
Submitter: Jenkins
Branch: stable/icehouse
commit bfeae680bc0632e 0129b647d45e4b8 0328a33535
Author: Liam Young <email address hidden>
Date: Tue Jul 22 16:25:00 2014 +0100
Fix CellStateManage rFile init to failure
Currently, specifying a cells_config file in nova.conf causes nager to fail and in turn stops the nova-cells service from nager with no arguments. CellStateManager __new__ runs and rFile which runs __new__ and rFile and the new instance's __init__ erFile. __init_ _) with the original state_manager( )
CellStateMa
starting. The reason is that CellsManager creates an instance of
CellStateMa
creates an instance of CellStateManage
__init__ with cell_state_cls and cells_config_path set. At this point
__new__ returns CellStateManage
method is invoked (CellStateManag
arguments (there weren't any) which then results in:
2014-04-29 11:52:05.240 16759 TRACE nova self.state_manager =
cell_
2014-04-29 11:52:05.240 16759 TRACE nova TypeError: __init__() takes
exactly 3 arguments (1 given)
It seems reasonable for CellStateManage rFile to derive the config_ path info for itself so I have updated the code with that
cells_
change and added unit tests to catch this bug and to check that the
correct managers are still returned
Closes-Bug: #1314677 6e60120ff329654 93c844e7f5)
(cherry picked from commit 695191fa89387d9
Conflicts: tests/cells/ test_cells_ state_manager. py
nova/
Change-Id: I9021640515142a 3ca95c2d9e7b03e 19b529bc175