diff options
author | Kim Hagen <kim.sidney@gmail.com> | 2018-10-25 22:26:25 +0200 |
---|---|---|
committer | Kim Hagen <kim.sidney@gmail.com> | 2018-10-25 22:26:25 +0200 |
commit | b120f4f7a670674779a93f8c882c81f44a993888 (patch) | |
tree | 906d15f6520751b5e8fbeb49b680e673a5cc6aa3 /cloudinit/reporting/__init__.py | |
parent | 838581d57c8765d3e487f58bc37ea103af39d26f (diff) | |
parent | 833adcdf6f85ec2305e62bea5a20f9363bf95507 (diff) | |
download | vyos-cloud-init-b120f4f7a670674779a93f8c882c81f44a993888.tar.gz vyos-cloud-init-b120f4f7a670674779a93f8c882c81f44a993888.zip |
Merge tag 'ubuntu/18.4-0ubuntu1_16.04.2' into current
Conflicts:
cloudinit/sources/DataSourceAzure.py
config/cloud.cfg.tmpl
integration-requirements.txt
tools/read-version
Diffstat (limited to 'cloudinit/reporting/__init__.py')
-rw-r--r-- | cloudinit/reporting/__init__.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/cloudinit/reporting/__init__.py b/cloudinit/reporting/__init__.py index 1ed2b487..ed5c7038 100644 --- a/cloudinit/reporting/__init__.py +++ b/cloudinit/reporting/__init__.py @@ -18,7 +18,7 @@ DEFAULT_CONFIG = { def update_configuration(config): - """Update the instanciated_handler_registry. + """Update the instantiated_handler_registry. :param config: The dictionary containing changes to apply. If a key is given @@ -37,6 +37,12 @@ def update_configuration(config): instantiated_handler_registry.register_item(handler_name, instance) +def flush_events(): + for _, handler in instantiated_handler_registry.registered_items.items(): + if hasattr(handler, 'flush'): + handler.flush() + + instantiated_handler_registry = DictRegistry() update_configuration(DEFAULT_CONFIG) |