diff --git a/nova/conductor/manager.py b/nova/conductor/manager.py index ce29fbb64e0d..7531a2eacdd1 100644 --- a/nova/conductor/manager.py +++ b/nova/conductor/manager.py @@ -1660,7 +1660,7 @@ class ComputeTaskManager(base.Base): hosts_by_cell[hmap.cell_mapping.uuid].append(hostname) LOG.info('Preparing to request pre-caching of image(s) %(image_ids)s ' - 'on %(hosts)i hosts across %(cells)s cells.', + 'on %(hosts)i hosts across %(cells)i cells.', {'image_ids': ','.join(image_ids), 'hosts': len(aggregate.hosts), 'cells': len(hosts_by_cell)}) @@ -1688,6 +1688,8 @@ class ComputeTaskManager(base.Base): fetch_pool.waitall() clock.stop() + # FIXME(danms): Calculate some interesting statistics about the image + # download process to log for the admin. LOG.info('Image pre-cache operation for image(s) %(image_ids)s ' 'completed in %(time).2f seconds', {'image_ids': ','.join(image_ids), diff --git a/nova/tests/unit/virt/libvirt/test_driver.py b/nova/tests/unit/virt/libvirt/test_driver.py index a6353de8c22c..e9a95c3a7db8 100644 --- a/nova/tests/unit/virt/libvirt/test_driver.py +++ b/nova/tests/unit/virt/libvirt/test_driver.py @@ -23561,7 +23561,10 @@ class LibvirtDriverTestCase(test.NoDBTestCase, TraitsComparisonMixin): else: mock_et.assert_not_called() - def test_cache_image_existing_first_time(self): + def test_cache_image_uncached_first_time(self): + # Test the case where we do need to download the image, + # and this is the first time an image cache operation has ever + # been performed, so the directory structure has to be created. self.test_cache_image_uncached(first_time=True) @mock.patch('oslo_utils.fileutils.ensure_tree')