[ 
https://issues.apache.org/jira/browse/CLOUDSTACK-6467?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jeff Hair updated CLOUDSTACK-6467:
----------------------------------

    Fix Version/s: 4.5.0

> User VM state listener publishes to event bus incompletely
> ----------------------------------------------------------
>
>                 Key: CLOUDSTACK-6467
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-6467
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the 
> default.) 
>          Components: Management Server
>    Affects Versions: 4.2.0, 4.3.0, 4.4.0, 4.5.0
>         Environment: CentOS 6.5
>            Reporter: Jeff Hair
>              Labels: easyfix, patch
>             Fix For: 4.5.0
>
>
> The UserVMStateListener is responsible for publishing resource state 
> transition events and usage events for virtual machines. It has an issue 
> where, from the point of view of any listener bound on the event bus, it 
> publishes resource state transition events for user VMs twice and only 
> publishes events for system VMs (e.g. virtual routers) once, but before the 
> state transition happens. Usage events are unaffected.
> This is because of two issues:
> 1. The publishOnEventBusMethod receives a status parameter to determine 
> whether the event is pre- or post-transition. It ignores this parameter when 
> publishing.
> 2. Only pre-transition events are published for system VMs like routers. This 
> means there is no reliable way to act on a state transition event for system 
> VMs if we are interested in doing something AFTER they have changed the state.
> The easiest solution to these issues is to move the the publishOnEventBus 
> call in postStateTransitionEvent to before it returns for non-user VMs, and 
> then also add the status string into the event description map when 
> publishing to the event bus.
> I've also submitted a patch for this change to review board.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to