[Newton] Nova notifications do not show the user which initiates the event.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Description
===========
Nova event notification does not show the actual user who initiated the event, instead show the owner of the VM.
Steps to reproduce
==================
1. Create a tenant "test-tenant".
2. Create two users; an admin "test-admin" and a SSO user "test-user"
3. Create a VM from "test-user"
4. Reboot the VM created in #3 from "test-admin"
Event notification show "test-user" in the events. It should rather show "test-user".
This is because while generating the event notification payload, information from instance is used instead of context information.
Code wise, in this line
https:/
Here we use:
user_id=
Should'nt we use, user that has come from context, something like
user_id=
Based on comment above the linked code it is intentional to send the user id and project id of the _owner_ of the instance. Still I understand the need to know which user initiated the reboot action. Therefore I opened a blueprint to do this as a new addition to the versioned instance action notifications https:/ /blueprints. launchpad. net/nova/ +spec/add- action- initiator- to-instance- action- notifications