Public bug reported:

Description
===========
After a vm moves from state 'building' to 'error' an unversioned notification 
is no longer sent if CONF.notifications.notification_format is set to 
'unversioned'.

Steps to reproduce
==================
In nova.conf set
[notifications]
notification_format = unversioned

Setup environment so VM deploy fails.
To reproduce easily in my environment I raised a generic Exception just after 
the call to spawn in orchestrator's start_deploy_simple()
Attempt to deploy VM.
Wait for deploy to fail.

Expected result
===============
When the vm_state changes to 'error' an unversioned notification should be sent.

Actual result
=============
The unversioned notification is not sent.

Environment
===========
(pike)nova-compute/now 10:16.0.0-201710030907


Additional Info:
================
Problem seems to stem from this change: 
https://github.com/openstack/nova/commit/29cb8f1c459e6d23dd9303fb570cee773d9c4d02
 at:
        if (NOTIFIER.is_enabled() and
                CONF.notifications.notification_format in ('both',
                                                           'versioned')):
Because 'unversioned' is not in the list, the @rpc.if_notifications_enabled 
decorator causes send_instance_update_notification() as well as 
_send_versioned_instance_update() to effectively be skipped. The name of the 
decorator and the comment describing it's functionality make it hard to 
determine is precise intended purpose. The decorator name implies it's checking 
if notifications are enabled at all. The comment in the decorator states it's 
specificly checking if versioned notifications are enabled and is in fact what 
it appears to be doing. Since the decorator was applied to 
send_instance_update_notification it's effectively blocking unversioned 
notifications if versioned notifications are not enabled.

** Affects: nova
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1721843

Title:
  Unversioned notifications not being sent.

Status in OpenStack Compute (nova):
  New

Bug description:
  Description
  ===========
  After a vm moves from state 'building' to 'error' an unversioned notification 
is no longer sent if CONF.notifications.notification_format is set to 
'unversioned'.

  Steps to reproduce
  ==================
  In nova.conf set
  [notifications]
  notification_format = unversioned

  Setup environment so VM deploy fails.
  To reproduce easily in my environment I raised a generic Exception just after 
the call to spawn in orchestrator's start_deploy_simple()
  Attempt to deploy VM.
  Wait for deploy to fail.

  Expected result
  ===============
  When the vm_state changes to 'error' an unversioned notification should be 
sent.

  Actual result
  =============
  The unversioned notification is not sent.

  Environment
  ===========
  (pike)nova-compute/now 10:16.0.0-201710030907

  
  Additional Info:
  ================
  Problem seems to stem from this change: 
https://github.com/openstack/nova/commit/29cb8f1c459e6d23dd9303fb570cee773d9c4d02
 at:
          if (NOTIFIER.is_enabled() and
                  CONF.notifications.notification_format in ('both',
                                                             'versioned')):
  Because 'unversioned' is not in the list, the @rpc.if_notifications_enabled 
decorator causes send_instance_update_notification() as well as 
_send_versioned_instance_update() to effectively be skipped. The name of the 
decorator and the comment describing it's functionality make it hard to 
determine is precise intended purpose. The decorator name implies it's checking 
if notifications are enabled at all. The comment in the decorator states it's 
specificly checking if versioned notifications are enabled and is in fact what 
it appears to be doing. Since the decorator was applied to 
send_instance_update_notification it's effectively blocking unversioned 
notifications if versioned notifications are not enabled.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1721843/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to