)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cc888a033fe91e730cac77de0cff55838a6be715","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"doc: Add guidline about notification payload"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"To help adding new notification to nova we shall have a guideline"},{"line_number":10,"context_line":"what should and what should not be in the notification payload."},{"line_number":11,"context_line":""},{"line_number":12,"context_line":"Change-Id: Ic85d304974bbfa7e02999ec3d6c9bba1d1aed3c8"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"7a77a97e_b3010109","line":9,"updated":"2016-11-22 17:43:22.000000000","message":"s/notification/notifications/","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"}],"doc/source/notifications.rst":[{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"e811c3c851da144d181aa917b299add889ef564b","unresolved":false,"context_lines":[{"line_number":277,"context_line":"  the entity triggers an update notification then you should include the field"},{"line_number":278,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":279,"context_line":"  consumer."},{"line_number":280,"context_line":"* You should not include those parts of the entity that is unchanged or static"},{"line_number":281,"context_line":"  in relations with the change you are sending the notification about. So that"},{"line_number":282,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":283,"context_line":"* You shall never include a nova internal object to the payload. Create a new"}],"source_content_type":"text/x-rst","patch_set":1,"id":"1a122d0e_03200cf6","line":280,"updated":"2016-04-20 16:08:04.000000000","message":"s/is/are","commit_id":"dd790294bdccd7cf7cbe56620d5679588db51ba0"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"06807274c85d84e63872a5456bbf2148b4d63580","unresolved":false,"context_lines":[{"line_number":277,"context_line":"  the entity triggers an update notification then you should include the field"},{"line_number":278,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":279,"context_line":"  consumer."},{"line_number":280,"context_line":"* You should not include those parts of the entity that is unchanged or static"},{"line_number":281,"context_line":"  in relations with the change you are sending the notification about. So that"},{"line_number":282,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":283,"context_line":"* You shall never include a nova internal object to the payload. Create a new"}],"source_content_type":"text/x-rst","patch_set":1,"id":"1a122d0e_81db06ed","line":280,"in_reply_to":"1a122d0e_03200cf6","updated":"2016-04-22 15:50:32.000000000","message":"Done","commit_id":"dd790294bdccd7cf7cbe56620d5679588db51ba0"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"e811c3c851da144d181aa917b299add889ef564b","unresolved":false,"context_lines":[{"line_number":278,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":279,"context_line":"  consumer."},{"line_number":280,"context_line":"* You should not include those parts of the entity that is unchanged or static"},{"line_number":281,"context_line":"  in relations with the change you are sending the notification about. So that"},{"line_number":282,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":283,"context_line":"* You shall never include a nova internal object to the payload. Create a new"},{"line_number":284,"context_line":"  object and use the SCHEMA field to map the internal object to the"}],"source_content_type":"text/x-rst","patch_set":1,"id":"1a122d0e_a36b181d","line":281,"updated":"2016-04-20 16:08:04.000000000","message":"\"in relation to the\"\n\nand maybe s/change/event/ ?","commit_id":"dd790294bdccd7cf7cbe56620d5679588db51ba0"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"06807274c85d84e63872a5456bbf2148b4d63580","unresolved":false,"context_lines":[{"line_number":278,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":279,"context_line":"  consumer."},{"line_number":280,"context_line":"* You should not include those parts of the entity that is unchanged or static"},{"line_number":281,"context_line":"  in relations with the change you are sending the notification about. So that"},{"line_number":282,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":283,"context_line":"* You shall never include a nova internal object to the payload. Create a new"},{"line_number":284,"context_line":"  object and use the SCHEMA field to map the internal object to the"}],"source_content_type":"text/x-rst","patch_set":1,"id":"1a122d0e_8102e63c","line":281,"in_reply_to":"1a122d0e_a36b181d","updated":"2016-04-22 15:50:32.000000000","message":"Done","commit_id":"dd790294bdccd7cf7cbe56620d5679588db51ba0"},{"author":{"_account_id":20873,"name":"Laszlo Hegedus","email":"hegedues.laszlo@gmail.com","username":"laszloh"},"change_message_id":"1d0db8a795a54157be053600ac01df72387c3b61","unresolved":false,"context_lines":[{"line_number":280,"context_line":"* You should not include those parts of the entity that is unchanged or static"},{"line_number":281,"context_line":"  in relations with the change you are sending the notification about. So that"},{"line_number":282,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":283,"context_line":"* You shall never include a nova internal object to the payload. Create a new"},{"line_number":284,"context_line":"  object and use the SCHEMA field to map the internal object to the"},{"line_number":285,"context_line":"  notification payload. This way the evolution of the internal object model"},{"line_number":286,"context_line":"  can be decoupled from the evolution of the notification payload."}],"source_content_type":"text/x-rst","patch_set":1,"id":"1a122d0e_5508edd9","line":283,"range":{"start_line":283,"start_character":49,"end_line":283,"end_character":51},"updated":"2016-04-20 19:44:32.000000000","message":"s/to/in/","commit_id":"dd790294bdccd7cf7cbe56620d5679588db51ba0"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"06807274c85d84e63872a5456bbf2148b4d63580","unresolved":false,"context_lines":[{"line_number":280,"context_line":"* You should not include those parts of the entity that is unchanged or static"},{"line_number":281,"context_line":"  in relations with the change you are sending the notification about. So that"},{"line_number":282,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":283,"context_line":"* You shall never include a nova internal object to the payload. Create a new"},{"line_number":284,"context_line":"  object and use the SCHEMA field to map the internal object to the"},{"line_number":285,"context_line":"  notification payload. This way the evolution of the internal object model"},{"line_number":286,"context_line":"  can be decoupled from the evolution of the notification payload."}],"source_content_type":"text/x-rst","patch_set":1,"id":"1a122d0e_0163761b","line":283,"range":{"start_line":283,"start_character":49,"end_line":283,"end_character":51},"in_reply_to":"1a122d0e_5508edd9","updated":"2016-04-22 15:50:32.000000000","message":"Done","commit_id":"dd790294bdccd7cf7cbe56620d5679588db51ba0"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cc888a033fe91e730cac77de0cff55838a6be715","unresolved":false,"context_lines":[{"line_number":269,"context_line":"`doc/sample_notifications/service-update.json` and the"},{"line_number":270,"context_line":"ServiceUpdateNotification class is decorated accordingly."},{"line_number":271,"context_line":""},{"line_number":272,"context_line":"What shall be in the notification payload"},{"line_number":273,"context_line":"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"},{"line_number":274,"context_line":"This is just a guideline you shall always consider the actual use case that"},{"line_number":275,"context_line":"requires the notification."}],"source_content_type":"text/x-rst","patch_set":4,"id":"7a77a97e_36231fa9","line":272,"updated":"2016-11-22 17:43:22.000000000","message":"s/shall/should :)","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"77acf8bb34b9b5c3752d593d8e8819f1d8ee5f48","unresolved":false,"context_lines":[{"line_number":269,"context_line":"`doc/sample_notifications/service-update.json` and the"},{"line_number":270,"context_line":"ServiceUpdateNotification class is decorated accordingly."},{"line_number":271,"context_line":""},{"line_number":272,"context_line":"What shall be in the notification payload"},{"line_number":273,"context_line":"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"},{"line_number":274,"context_line":"This is just a guideline you shall always consider the actual use case that"},{"line_number":275,"context_line":"requires the notification."}],"source_content_type":"text/x-rst","patch_set":4,"id":"5a74a57a_ac93a5f9","line":272,"in_reply_to":"7a77a97e_36231fa9","updated":"2016-11-23 14:05:35.000000000","message":"Done","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cc888a033fe91e730cac77de0cff55838a6be715","unresolved":false,"context_lines":[{"line_number":271,"context_line":""},{"line_number":272,"context_line":"What shall be in the notification payload"},{"line_number":273,"context_line":"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"},{"line_number":274,"context_line":"This is just a guideline you shall always consider the actual use case that"},{"line_number":275,"context_line":"requires the notification."},{"line_number":276,"context_line":""},{"line_number":277,"context_line":"* Always include the identifier (e.g. uuid) of the entity that can be used to"}],"source_content_type":"text/x-rst","patch_set":4,"id":"7a77a97e_961dd368","line":274,"updated":"2016-11-22 17:43:22.000000000","message":"s/guideline you shall/guideline. You should/","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"77acf8bb34b9b5c3752d593d8e8819f1d8ee5f48","unresolved":false,"context_lines":[{"line_number":271,"context_line":""},{"line_number":272,"context_line":"What shall be in the notification payload"},{"line_number":273,"context_line":"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"},{"line_number":274,"context_line":"This is just a guideline you shall always consider the actual use case that"},{"line_number":275,"context_line":"requires the notification."},{"line_number":276,"context_line":""},{"line_number":277,"context_line":"* Always include the identifier (e.g. uuid) of the entity that can be used to"}],"source_content_type":"text/x-rst","patch_set":4,"id":"5a74a57a_6c77cdd4","line":274,"in_reply_to":"7a77a97e_961dd368","updated":"2016-11-23 14:05:35.000000000","message":"Done","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cc888a033fe91e730cac77de0cff55838a6be715","unresolved":false,"context_lines":[{"line_number":280,"context_line":"* You should consider including those fields that are related to the event"},{"line_number":281,"context_line":"  you are sending the notification about. For example if a change of a field of"},{"line_number":282,"context_line":"  the entity triggers an update notification then you should include the field"},{"line_number":283,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":284,"context_line":"  consumer."},{"line_number":285,"context_line":"* You should not include those parts of the entity that are unchanged or static"},{"line_number":286,"context_line":"  in relations to the event you are sending the notification about. So that"}],"source_content_type":"text/x-rst","patch_set":4,"id":"7a77a97e_167c6371","line":283,"updated":"2016-11-22 17:43:22.000000000","message":"I think you can probably remove the last sentence. It\u0027s a repeat of the first sentence :)\n\nAlso, for update-type notifications, would it be best practice to send the before and after representation of the entity?","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"77acf8bb34b9b5c3752d593d8e8819f1d8ee5f48","unresolved":false,"context_lines":[{"line_number":280,"context_line":"* You should consider including those fields that are related to the event"},{"line_number":281,"context_line":"  you are sending the notification about. For example if a change of a field of"},{"line_number":282,"context_line":"  the entity triggers an update notification then you should include the field"},{"line_number":283,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":284,"context_line":"  consumer."},{"line_number":285,"context_line":"* You should not include those parts of the entity that are unchanged or static"},{"line_number":286,"context_line":"  in relations to the event you are sending the notification about. So that"}],"source_content_type":"text/x-rst","patch_set":4,"id":"5a74a57a_a0f56184","line":283,"in_reply_to":"7a77a97e_167c6371","updated":"2016-11-23 14:05:35.000000000","message":"I\u0027ve removed the last sentence.\n\nYeah, the best would be to send the update type notification with a content that describes what was changed. \nIn some cases this is not even hard to do. For example in service.update [1] the code sending the notification has the information about what changes triggered the notification sending.\nIn case of instance.update the code is lot more convoluted so it is hard to figure out what is exactly changed in the instance. (See the code path from [2] to [3])\n\nI think the next step towards this direction could be to start filling the \"nova_object.changes\" field of the notification payload to signal what field was changed. This is good for the statefull clients as they know the previous state of the entity but of course this does not help the stateless clients. If we want to help the stateless clients as well then we really have to send both the old and the new version of the entity in the update notification payload.\n\nI\u0027ve tried to put this into a separate bullet point but I would like to hear your opinion about the possibilities we have.\n\n\n[1]https://github.com/openstack/nova/blob/master/nova/objects/service.py#L319\n[2]https://github.com/openstack/nova/blob/master/nova/notifications/base.py#L98\n[3]https://github.com/openstack/nova/blob/master/nova/notifications/base.py#L264","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cc888a033fe91e730cac77de0cff55838a6be715","unresolved":false,"context_lines":[{"line_number":283,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":284,"context_line":"  consumer."},{"line_number":285,"context_line":"* You should not include those parts of the entity that are unchanged or static"},{"line_number":286,"context_line":"  in relations to the event you are sending the notification about. So that"},{"line_number":287,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":288,"context_line":"* You shall never include a nova internal object in the payload. Create a new"},{"line_number":289,"context_line":"  object and use the SCHEMA field to map the internal object to the"}],"source_content_type":"text/x-rst","patch_set":4,"id":"7a77a97e_d6e82b19","line":286,"updated":"2016-11-22 17:43:22.000000000","message":"s/relations/relation","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"77acf8bb34b9b5c3752d593d8e8819f1d8ee5f48","unresolved":false,"context_lines":[{"line_number":283,"context_line":"  to the payload. So that the notification payload is meaningful for the"},{"line_number":284,"context_line":"  consumer."},{"line_number":285,"context_line":"* You should not include those parts of the entity that are unchanged or static"},{"line_number":286,"context_line":"  in relations to the event you are sending the notification about. So that"},{"line_number":287,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":288,"context_line":"* You shall never include a nova internal object in the payload. Create a new"},{"line_number":289,"context_line":"  object and use the SCHEMA field to map the internal object to the"}],"source_content_type":"text/x-rst","patch_set":4,"id":"5a74a57a_59948736","line":286,"in_reply_to":"7a77a97e_d6e82b19","updated":"2016-11-23 14:05:35.000000000","message":"Done","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cc888a033fe91e730cac77de0cff55838a6be715","unresolved":false,"context_lines":[{"line_number":285,"context_line":"* You should not include those parts of the entity that are unchanged or static"},{"line_number":286,"context_line":"  in relations to the event you are sending the notification about. So that"},{"line_number":287,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":288,"context_line":"* You shall never include a nova internal object in the payload. Create a new"},{"line_number":289,"context_line":"  object and use the SCHEMA field to map the internal object to the"},{"line_number":290,"context_line":"  notification payload. This way the evolution of the internal object model"},{"line_number":291,"context_line":"  can be decoupled from the evolution of the notification payload."}],"source_content_type":"text/x-rst","patch_set":4,"id":"7a77a97e_76d83780","line":288,"updated":"2016-11-22 17:43:22.000000000","message":"s/shall/should/","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"77acf8bb34b9b5c3752d593d8e8819f1d8ee5f48","unresolved":false,"context_lines":[{"line_number":285,"context_line":"* You should not include those parts of the entity that are unchanged or static"},{"line_number":286,"context_line":"  in relations to the event you are sending the notification about. So that"},{"line_number":287,"context_line":"  you can limit the size of the payload and avoid unnecessary repetition."},{"line_number":288,"context_line":"* You shall never include a nova internal object in the payload. Create a new"},{"line_number":289,"context_line":"  object and use the SCHEMA field to map the internal object to the"},{"line_number":290,"context_line":"  notification payload. This way the evolution of the internal object model"},{"line_number":291,"context_line":"  can be decoupled from the evolution of the notification payload."}],"source_content_type":"text/x-rst","patch_set":4,"id":"5a74a57a_99ec5fc9","line":288,"in_reply_to":"7a77a97e_76d83780","updated":"2016-11-23 14:05:35.000000000","message":"Done","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"cc888a033fe91e730cac77de0cff55838a6be715","unresolved":false,"context_lines":[{"line_number":288,"context_line":"* You shall never include a nova internal object in the payload. Create a new"},{"line_number":289,"context_line":"  object and use the SCHEMA field to map the internal object to the"},{"line_number":290,"context_line":"  notification payload. This way the evolution of the internal object model"},{"line_number":291,"context_line":"  can be decoupled from the evolution of the notification payload."},{"line_number":292,"context_line":""},{"line_number":293,"context_line":"Existing versioned notifications"},{"line_number":294,"context_line":"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"}],"source_content_type":"text/x-rst","patch_set":4,"id":"7a77a97e_16caa3a1","line":291,"updated":"2016-11-22 17:43:22.000000000","message":"++","commit_id":"29a7218a5a8f789a3145c9a2191560b87f58c7f9"}]}
