)]}'
{"doc/source/EXTENSIONS_HOWTO.rst":[{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"d558df9a7d3688c72cd1123d76808a35514a2c30","unresolved":false,"context_lines":[{"line_number":260,"context_line":"Event Notifications"},{"line_number":261,"context_line":"-------------------"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"In order to subscribe to event notifications, the extension must provide the list of it is events its interested and their corresponding callbacks."},{"line_number":264,"context_line":"In the ``routers.py`` file add a dictionary listing as keys the events of interest"},{"line_number":265,"context_line":"and as values the callbacks."},{"line_number":266,"context_line":""}],"source_content_type":"text/x-rst","patch_set":15,"id":"AAAATn%2F9GY4%3D","line":263,"updated":"2013-12-16 21:03:08.000000000","message":"Typos in this line (list of it is events its...) . Also it is too long","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"4b8383d7986eda4a53a39acd4077773a02fa0940","unresolved":false,"context_lines":[{"line_number":260,"context_line":"Event Notifications"},{"line_number":261,"context_line":"-------------------"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"In order to subscribe to event notifications, the extension must provide the list of it is events its interested and their corresponding callbacks."},{"line_number":264,"context_line":"In the ``routers.py`` file add a dictionary listing as keys the events of interest"},{"line_number":265,"context_line":"and as values the callbacks."},{"line_number":266,"context_line":""}],"source_content_type":"text/x-rst","patch_set":15,"id":"AAAATn%2F9Fos%3D","line":263,"in_reply_to":"AAAATn%2F9GY4%3D","updated":"2013-12-16 22:12:43.000000000","message":"re-phrased","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"d558df9a7d3688c72cd1123d76808a35514a2c30","unresolved":false,"context_lines":[{"line_number":261,"context_line":"-------------------"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"In order to subscribe to event notifications, the extension must provide the list of it is events its interested and their corresponding callbacks."},{"line_number":264,"context_line":"In the ``routers.py`` file add a dictionary listing as keys the events of interest"},{"line_number":265,"context_line":"and as values the callbacks."},{"line_number":266,"context_line":""},{"line_number":267,"context_line":"Example:"}],"source_content_type":"text/x-rst","patch_set":15,"id":"AAAATn%2F9GYI%3D","line":264,"updated":"2013-12-16 21:03:08.000000000","message":"change to \"listing as keys those events that are of interest and the values should be the respective callbacks\"","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"4b8383d7986eda4a53a39acd4077773a02fa0940","unresolved":false,"context_lines":[{"line_number":261,"context_line":"-------------------"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"In order to subscribe to event notifications, the extension must provide the list of it is events its interested and their corresponding callbacks."},{"line_number":264,"context_line":"In the ``routers.py`` file add a dictionary listing as keys the events of interest"},{"line_number":265,"context_line":"and as values the callbacks."},{"line_number":266,"context_line":""},{"line_number":267,"context_line":"Example:"}],"source_content_type":"text/x-rst","patch_set":15,"id":"AAAATn%2F9Foc%3D","line":264,"in_reply_to":"AAAATn%2F9GYI%3D","updated":"2013-12-16 22:12:43.000000000","message":"Done","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"d558df9a7d3688c72cd1123d76808a35514a2c30","unresolved":false,"context_lines":[{"line_number":264,"context_line":"In the ``routers.py`` file add a dictionary listing as keys the events of interest"},{"line_number":265,"context_line":"and as values the callbacks."},{"line_number":266,"context_line":""},{"line_number":267,"context_line":"Example:"},{"line_number":268,"context_line":""},{"line_number":269,"context_line":".. code:: python"},{"line_number":270,"context_line":"       from keystone.contrib.example import controllers"}],"source_content_type":"text/x-rst","patch_set":15,"id":"AAAATn%2F9GW8%3D","line":267,"updated":"2013-12-16 21:03:08.000000000","message":"Great example!","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":45,"context_line":"- If configuration changes are required/introduced in the `keystone-paste.ini`,"},{"line_number":46,"context_line":"  the new filter must be declared."},{"line_number":47,"context_line":"- If the configuration is listening to core notifications the events list and"},{"line_number":48,"context_line":"  corresponding callbacks must be declared in the ``__init__.py`` file."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"`keystone.conf.sample` File"}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F845g%3D","line":48,"updated":"2013-12-19 06:24:26.000000000","message":"you mean the extension\u0027s ``router.py`` file?","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":45,"context_line":"- If configuration changes are required/introduced in the `keystone-paste.ini`,"},{"line_number":46,"context_line":"  the new filter must be declared."},{"line_number":47,"context_line":"- If the configuration is listening to core notifications the events list and"},{"line_number":48,"context_line":"  corresponding callbacks must be declared in the ``__init__.py`` file."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"`keystone.conf.sample` File"}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F81yY%3D","line":48,"in_reply_to":"AAAATn%2F845g%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":273,"context_line":""},{"line_number":274,"context_line":""},{"line_number":275,"context_line":"In the ``routers.py`` file add a dictionary listing as keys those events that"},{"line_number":276,"context_line":"are of interest and the values should be the respective callbacks."},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"Example:"},{"line_number":279,"context_line":""}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F84wA%3D","line":276,"updated":"2013-12-19 06:24:26.000000000","message":"Perhaps worth mentioning that the callback must be expecting the following parameters:\n\n    - `context` - the session context\n    - `message` - the notification message\n\nExample::\n\n    callback(context, message)","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":273,"context_line":""},{"line_number":274,"context_line":""},{"line_number":275,"context_line":"In the ``routers.py`` file add a dictionary listing as keys those events that"},{"line_number":276,"context_line":"are of interest and the values should be the respective callbacks."},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"Example:"},{"line_number":279,"context_line":""}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F81xg%3D","line":276,"in_reply_to":"AAAATn%2F84wA%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":284,"context_line":""},{"line_number":285,"context_line":"       subscribed_events \u003d {"},{"line_number":286,"context_line":"          \u0027identity.project.deleted\u0027:"},{"line_number":287,"context_line":"          core.Manager().project_deleted_notification,"},{"line_number":288,"context_line":"          \u0027identity.project.created\u0027:"},{"line_number":289,"context_line":"          core.Manager().project_created_notification"},{"line_number":290,"context_line":"       }"}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F84xc%3D","line":287,"updated":"2013-12-19 06:24:26.000000000","message":"core.ExampleManager()","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":284,"context_line":""},{"line_number":285,"context_line":"       subscribed_events \u003d {"},{"line_number":286,"context_line":"          \u0027identity.project.deleted\u0027:"},{"line_number":287,"context_line":"          core.Manager().project_deleted_notification,"},{"line_number":288,"context_line":"          \u0027identity.project.created\u0027:"},{"line_number":289,"context_line":"          core.Manager().project_created_notification"},{"line_number":290,"context_line":"       }"}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F81z4%3D","line":287,"in_reply_to":"AAAATn%2F84xc%3D","updated":"2013-12-19 17:22:24.000000000","message":"No this is a generic instructions, the one for the Example extensions are in the example folder.","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":292,"context_line":""},{"line_number":293,"context_line":"Events in Keystone follow this format: identity.\u003cresource\u003e.\u003coperation\u003e where"},{"line_number":294,"context_line":"the operations are ``created``, ``updated`` and ``deleted``. Please refers to"},{"line_number":295,"context_line":"the event_notifications.rst file for more information on notifications."},{"line_number":296,"context_line":""},{"line_number":297,"context_line":"Lastly the extension has to register the dictionary of events with the"},{"line_number":298,"context_line":"``extension_notifier`` notification driver."}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F845o%3D","line":295,"updated":"2013-12-19 06:24:26.000000000","message":"Please refer to :doc:`event_notifications` for more information on notifications.","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":292,"context_line":""},{"line_number":293,"context_line":"Events in Keystone follow this format: identity.\u003cresource\u003e.\u003coperation\u003e where"},{"line_number":294,"context_line":"the operations are ``created``, ``updated`` and ``deleted``. Please refers to"},{"line_number":295,"context_line":"the event_notifications.rst file for more information on notifications."},{"line_number":296,"context_line":""},{"line_number":297,"context_line":"Lastly the extension has to register the dictionary of events with the"},{"line_number":298,"context_line":"``extension_notifier`` notification driver."}],"source_content_type":"text/x-rst","patch_set":19,"id":"AAAATn%2F81xQ%3D","line":295,"in_reply_to":"AAAATn%2F845o%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"a8f56ad9dffc807b49c884387093c922d3a76655","unresolved":false,"context_lines":[{"line_number":44,"context_line":"  file, these should be kept disabled as default and have their own element."},{"line_number":45,"context_line":"- If configuration changes are required/introduced in the `keystone-paste.ini`,"},{"line_number":46,"context_line":"  the new filter must be declared."},{"line_number":47,"context_line":"- If the configuration is listening to core notifications the events list and"},{"line_number":48,"context_line":"  corresponding callbacks must be declared in the ``routers.py`` file."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAATn%2F8peA%3D","line":47,"updated":"2013-12-23 21:15:02.000000000","message":"Need a comma after notifications","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":44,"context_line":"  file, these should be kept disabled as default and have their own element."},{"line_number":45,"context_line":"- If configuration changes are required/introduced in the `keystone-paste.ini`,"},{"line_number":46,"context_line":"  the new filter must be declared."},{"line_number":47,"context_line":"- If the configuration is listening to core notifications the events list and"},{"line_number":48,"context_line":"  corresponding callbacks must be declared in the ``routers.py`` file."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAAUH%2F%2F5yU%3D","line":47,"in_reply_to":"AAAATn%2F8peA%3D","updated":"2014-01-07 01:33:31.000000000","message":"++","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":266,"context_line":"the following Keystone resources:"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":""},{"line_number":269,"context_line":"    - ``group``"},{"line_number":270,"context_line":"    - ``project``"},{"line_number":271,"context_line":"    - ``role``"},{"line_number":272,"context_line":"    - ``user``"}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAAUH%2F%2F5yM%3D","line":269,"updated":"2014-01-07 01:33:31.000000000","message":"lists don\u0027t need to be indented like this, i don\u0027t think. i\u0027m actually not sure how this will render","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":275,"context_line":"In the ``routers.py`` file add a dictionary listing as keys those events that"},{"line_number":276,"context_line":"are of interest and the values should be the respective callbacks."},{"line_number":277,"context_line":""},{"line_number":278,"context_line":""},{"line_number":279,"context_line":"Example:"},{"line_number":280,"context_line":""},{"line_number":281,"context_line":".. code:: python"}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAAUH%2F%2F5yI%3D","line":278,"updated":"2014-01-07 01:33:31.000000000","message":"replace the triple line breaks with double line breaks","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":303,"context_line":"      project_created_notification(context, message)"},{"line_number":304,"context_line":""},{"line_number":305,"context_line":""},{"line_number":306,"context_line":"Events in Keystone follow this format: identity.\u003cresource\u003e.\u003coperation\u003e where"},{"line_number":307,"context_line":"the operations are ``created``, ``updated`` and ``deleted``. Please refer to"},{"line_number":308,"context_line":"the :doc:`event_notifications` for more information on notifications."},{"line_number":309,"context_line":""}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAAUH%2F%2F5yE%3D","line":306,"updated":"2014-01-07 01:33:31.000000000","message":"``double backticks`` around the literal","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":307,"context_line":"the operations are ``created``, ``updated`` and ``deleted``. Please refer to"},{"line_number":308,"context_line":"the :doc:`event_notifications` for more information on notifications."},{"line_number":309,"context_line":""},{"line_number":310,"context_line":"Lastly the extension has to register the dictionary of events with the"},{"line_number":311,"context_line":"``extension_notifier`` notification driver."},{"line_number":312,"context_line":""},{"line_number":313,"context_line":"Example:"}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAAUH%2F%2F5yA%3D","line":310,"updated":"2014-01-07 01:33:31.000000000","message":"... dictionary of ``subscribed_events`` above with the... ?","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"184b5a9c74115584eca475b22bd99a98cf2bd8ea","unresolved":false,"context_lines":[{"line_number":262,"context_line":""},{"line_number":263,"context_line":"Extensions can subscribe to Keystone (Identity) event notifications."},{"line_number":264,"context_line":"Extensions must provide the list of events of interest and the corresponding"},{"line_number":265,"context_line":"callbacks. Events are fired upon successful creation, modification, and"},{"line_number":266,"context_line":"deletion of the following Keystone resources:"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"* ``group``"}],"source_content_type":"text/x-rst","patch_set":21,"id":"AAAAUH%2F%2FsBA%3D","line":265,"updated":"2014-01-09 16:14:58.000000000","message":"s/fired/issued to seem less pew pew","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"924e689784b175c945d214273b453bda683567f5","unresolved":false,"context_lines":[{"line_number":262,"context_line":""},{"line_number":263,"context_line":"Extensions can subscribe to Keystone (Identity) event notifications."},{"line_number":264,"context_line":"Extensions must provide the list of events of interest and the corresponding"},{"line_number":265,"context_line":"callbacks. Events are fired upon successful creation, modification, and"},{"line_number":266,"context_line":"deletion of the following Keystone resources:"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"* ``group``"}],"source_content_type":"text/x-rst","patch_set":21,"id":"AAAAUH%2F%2Frrs%3D","line":265,"in_reply_to":"AAAAUH%2F%2FsBA%3D","updated":"2014-01-09 16:55:36.000000000","message":"I think the initial draft was written by Donald Trump. :D","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":44,"context_line":"  file, these should be kept disabled as default and have their own element."},{"line_number":45,"context_line":"- If configuration changes are required/introduced in the `keystone-paste.ini`,"},{"line_number":46,"context_line":"  the new filter must be declared."},{"line_number":47,"context_line":"- If the configuration is listening to core notifications, the events list and"},{"line_number":48,"context_line":"  corresponding callbacks must be declared in the ``core.py`` file."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"`keystone.conf.sample` File"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FK8M%3D","line":47,"updated":"2014-01-16 19:31:22.000000000","message":"is configuration the right word?  perhaps you mean If the extension\u0027s configuration or just extension?","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":44,"context_line":"  file, these should be kept disabled as default and have their own element."},{"line_number":45,"context_line":"- If configuration changes are required/introduced in the `keystone-paste.ini`,"},{"line_number":46,"context_line":"  the new filter must be declared."},{"line_number":47,"context_line":"- If the configuration is listening to core notifications, the events list and"},{"line_number":48,"context_line":"  corresponding callbacks must be declared in the ``core.py`` file."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"`keystone.conf.sample` File"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FKnc%3D","line":47,"in_reply_to":"AAAAUH%2F%2FK8M%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":263,"context_line":"callbacks. Event callback registration is done via the"},{"line_number":264,"context_line":"dependency injection mechanism. During dependency provider registration, the"},{"line_number":265,"context_line":"``dependency.provider`` decorator looks for the ``event_callbacks``"},{"line_number":266,"context_line":"class attribute. If it exist the event callbacks are registered"},{"line_number":267,"context_line":"accordingly. Needless to say, in order to enable event callbacks, the"},{"line_number":268,"context_line":"extension\u0027s ``Manager`` class must also be a dependency provider."},{"line_number":269,"context_line":""}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FK7k%3D","line":266,"updated":"2014-01-16 19:31:22.000000000","message":"exist should be exists","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":263,"context_line":"callbacks. Event callback registration is done via the"},{"line_number":264,"context_line":"dependency injection mechanism. During dependency provider registration, the"},{"line_number":265,"context_line":"``dependency.provider`` decorator looks for the ``event_callbacks``"},{"line_number":266,"context_line":"class attribute. If it exist the event callbacks are registered"},{"line_number":267,"context_line":"accordingly. Needless to say, in order to enable event callbacks, the"},{"line_number":268,"context_line":"extension\u0027s ``Manager`` class must also be a dependency provider."},{"line_number":269,"context_line":""}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FKnY%3D","line":266,"in_reply_to":"AAAAUH%2F%2FK7k%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":264,"context_line":"dependency injection mechanism. During dependency provider registration, the"},{"line_number":265,"context_line":"``dependency.provider`` decorator looks for the ``event_callbacks``"},{"line_number":266,"context_line":"class attribute. If it exist the event callbacks are registered"},{"line_number":267,"context_line":"accordingly. Needless to say, in order to enable event callbacks, the"},{"line_number":268,"context_line":"extension\u0027s ``Manager`` class must also be a dependency provider."},{"line_number":269,"context_line":""},{"line_number":270,"context_line":"Example:"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FK7I%3D","line":267,"updated":"2014-01-16 19:31:22.000000000","message":"Remove Needless to say and just start as \"In order...\"","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":264,"context_line":"dependency injection mechanism. During dependency provider registration, the"},{"line_number":265,"context_line":"``dependency.provider`` decorator looks for the ``event_callbacks``"},{"line_number":266,"context_line":"class attribute. If it exist the event callbacks are registered"},{"line_number":267,"context_line":"accordingly. Needless to say, in order to enable event callbacks, the"},{"line_number":268,"context_line":"extension\u0027s ``Manager`` class must also be a dependency provider."},{"line_number":269,"context_line":""},{"line_number":270,"context_line":"Example:"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FKnU%3D","line":267,"in_reply_to":"AAAAUH%2F%2FK7I%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":280,"context_line":"        \"\"\""},{"line_number":281,"context_line":""},{"line_number":282,"context_line":"        def __init__(self):"},{"line_number":283,"context_line":"            self.event_callbacks \u003d {"},{"line_number":284,"context_line":"                \u0027deleted\u0027: {"},{"line_number":285,"context_line":"                    \u0027project\u0027: ["},{"line_number":286,"context_line":"                        self.project_deleted_callback]}}"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FK10%3D","line":283,"updated":"2014-01-16 19:31:22.000000000","message":"put a comment in the example saying, \"Here we add the the event_callbacks class attribute that calls project_deleted_callback when a project is deleted\"\n\nAlso does this have to go before the superclass init? Could it go after and that be okay???","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":280,"context_line":"        \"\"\""},{"line_number":281,"context_line":""},{"line_number":282,"context_line":"        def __init__(self):"},{"line_number":283,"context_line":"            self.event_callbacks \u003d {"},{"line_number":284,"context_line":"                \u0027deleted\u0027: {"},{"line_number":285,"context_line":"                    \u0027project\u0027: ["},{"line_number":286,"context_line":"                        self.project_deleted_callback]}}"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FKnQ%3D","line":283,"in_reply_to":"AAAAUH%2F%2FK10%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":282,"context_line":"        def __init__(self):"},{"line_number":283,"context_line":"            self.event_callbacks \u003d {"},{"line_number":284,"context_line":"                \u0027deleted\u0027: {"},{"line_number":285,"context_line":"                    \u0027project\u0027: ["},{"line_number":286,"context_line":"                        self.project_deleted_callback]}}"},{"line_number":287,"context_line":"            super(ExampleManager, self).__init__("},{"line_number":288,"context_line":"                \u0027keystone.contrib.example.core.ExampleDriver\u0027)"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FKxc%3D","line":285,"updated":"2014-01-16 19:31:22.000000000","message":"How do I know what the exhaustive list of options are that I can use.  projects, domains...  what else?  Is it all crud or just deleted???","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":282,"context_line":"        def __init__(self):"},{"line_number":283,"context_line":"            self.event_callbacks \u003d {"},{"line_number":284,"context_line":"                \u0027deleted\u0027: {"},{"line_number":285,"context_line":"                    \u0027project\u0027: ["},{"line_number":286,"context_line":"                        self.project_deleted_callback]}}"},{"line_number":287,"context_line":"            super(ExampleManager, self).__init__("},{"line_number":288,"context_line":"                \u0027keystone.contrib.example.core.ExampleDriver\u0027)"}],"source_content_type":"text/x-rst","patch_set":28,"id":"AAAAUH%2F%2FKnE%3D","line":285,"in_reply_to":"AAAAUH%2F%2FKxc%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"9e65f0fd3d200adc5d9a31e26d5863a005b0a305","unresolved":false,"context_lines":[{"line_number":270,"context_line":"Example:"},{"line_number":271,"context_line":""},{"line_number":272,"context_line":".. code:: python"},{"line_number":273,"context_line":"    @dependency.provider(\u0027example_api\u0027)"},{"line_number":274,"context_line":"    class ExampleManager(manager.Manager):"},{"line_number":275,"context_line":"        \"\"\"Example Manager."},{"line_number":276,"context_line":""}],"source_content_type":"text/x-rst","patch_set":29,"id":"AAAAUH%2F%2FKvM%3D","line":273,"updated":"2014-01-16 19:38:49.000000000","message":"Add comment:  Since this is a dependency provider.   Any code module using this or any other dependency provider will be enabled for the attribute based notification","commit_id":"d0c5920e67edcfc957ab62e0be925c39587559d0"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"ebb94500bc69808c3309b8a30eace828f4f7e602","unresolved":false,"context_lines":[{"line_number":270,"context_line":"Example:"},{"line_number":271,"context_line":""},{"line_number":272,"context_line":".. code:: python"},{"line_number":273,"context_line":"    @dependency.provider(\u0027example_api\u0027)"},{"line_number":274,"context_line":"    class ExampleManager(manager.Manager):"},{"line_number":275,"context_line":"        \"\"\"Example Manager."},{"line_number":276,"context_line":""}],"source_content_type":"text/x-rst","patch_set":29,"id":"AAAAUH%2F%2FKno%3D","line":273,"in_reply_to":"AAAAUH%2F%2FKvM%3D","updated":"2014-01-16 19:57:26.000000000","message":"Done","commit_id":"d0c5920e67edcfc957ab62e0be925c39587559d0"}],"etc/keystone-paste.ini":[{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"19afedb9cfe66fddfaf8fa3b8789ab3c2cde34b8","unresolved":false,"context_lines":[{"line_number":34,"context_line":"paste.filter_factory \u003d keystone.contrib.endpoint_filter.routers:EndpointFilterExtension.factory"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"[filter:example_extension]"},{"line_number":37,"context_line":"paste.filter_factory \u003d keystone.contrib.example.routers:ExampleRouter.factory"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"[filter:url_normalize]"},{"line_number":40,"context_line":"paste.filter_factory \u003d keystone.middleware:NormalizingFilter.factory"}],"source_content_type":"text/x-properties","patch_set":9,"id":"AAAATn%2F9k0o%3D","line":37,"updated":"2013-12-10 02:45:53.000000000","message":"Likely this shouldn\u0027t be added, as the example extension isn\u0027t really meant to be used.","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"ce160d1898247d75092f081fb738f7c96c985afa","unresolved":false,"context_lines":[{"line_number":34,"context_line":"paste.filter_factory \u003d keystone.contrib.endpoint_filter.routers:EndpointFilterExtension.factory"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"[filter:example_extension]"},{"line_number":37,"context_line":"paste.filter_factory \u003d keystone.contrib.example.routers:ExampleRouter.factory"},{"line_number":38,"context_line":""},{"line_number":39,"context_line":"[filter:url_normalize]"},{"line_number":40,"context_line":"paste.filter_factory \u003d keystone.middleware:NormalizingFilter.factory"}],"source_content_type":"text/x-properties","patch_set":9,"id":"AAAATn%2F9ku4%3D","line":37,"in_reply_to":"AAAATn%2F9k0o%3D","updated":"2013-12-10 03:56:32.000000000","message":"Actually I didn\u0027t find any mechanism to inject a new filter dynamically in the paste.ini. I did in the past with the keystone.conf but I could not find an equivalent method to change the past ini, any thoughts?","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"19afedb9cfe66fddfaf8fa3b8789ab3c2cde34b8","unresolved":false,"context_lines":[{"line_number":67,"context_line":"pipeline \u003d access_log sizelimit url_normalize token_auth admin_token_auth xml_body json_body ec2_extension s3_extension crud_extension admin_service"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"[pipeline:api_v3]"},{"line_number":70,"context_line":"pipeline \u003d access_log sizelimit url_normalize token_auth admin_token_auth xml_body json_body ec2_extension s3_extension example_extension service_v3"},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"[app:public_version_service]"},{"line_number":73,"context_line":"paste.app_factory \u003d keystone.service:public_version_app_factory"}],"source_content_type":"text/x-properties","patch_set":9,"id":"AAAATn%2F9k1Y%3D","line":70,"updated":"2013-12-10 02:45:53.000000000","message":"Why are we adding the example_extension to the pipeline here?  This doesn\u0027t seem correct as it\u0027s not meant to actually be used.  If this is needed for a test use the ini-generation mechanism (see how the oauth extension does it\u0027s testing)","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"ce160d1898247d75092f081fb738f7c96c985afa","unresolved":false,"context_lines":[{"line_number":67,"context_line":"pipeline \u003d access_log sizelimit url_normalize token_auth admin_token_auth xml_body json_body ec2_extension s3_extension crud_extension admin_service"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"[pipeline:api_v3]"},{"line_number":70,"context_line":"pipeline \u003d access_log sizelimit url_normalize token_auth admin_token_auth xml_body json_body ec2_extension s3_extension example_extension service_v3"},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"[app:public_version_service]"},{"line_number":73,"context_line":"paste.app_factory \u003d keystone.service:public_version_app_factory"}],"source_content_type":"text/x-properties","patch_set":9,"id":"AAAATn%2F9ku0%3D","line":70,"in_reply_to":"AAAATn%2F9k1Y%3D","updated":"2013-12-10 03:56:32.000000000","message":"Done.\nI just forgot to take it out during the commit ;-)","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"}],"etc/keystone.conf.sample":[{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"19afedb9cfe66fddfaf8fa3b8789ab3c2cde34b8","unresolved":false,"context_lines":[{"line_number":146,"context_line":"[extension_notifications]"},{"line_number":147,"context_line":"# List of extensions that are enrolled in notifications for status change"},{"line_number":148,"context_line":"# during the creation, update and deletion of Keystone main entities."},{"line_number":149,"context_line":"# extensions \u003d keystone.contrib.example.controllers.ExampleV3Controller"},{"line_number":150,"context_line":""},{"line_number":151,"context_line":"[sql]"},{"line_number":152,"context_line":"# The SQLAlchemy connection string used to connect to the database"}],"source_content_type":"application/octet-stream","patch_set":9,"id":"AAAATn%2F9k1A%3D","line":149,"updated":"2013-12-10 02:45:53.000000000","message":"This configuration option does not seem to be defined.  typically, configuration options (for keystone) are defined in keystone/common/config.py","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"ce160d1898247d75092f081fb738f7c96c985afa","unresolved":false,"context_lines":[{"line_number":146,"context_line":"[extension_notifications]"},{"line_number":147,"context_line":"# List of extensions that are enrolled in notifications for status change"},{"line_number":148,"context_line":"# during the creation, update and deletion of Keystone main entities."},{"line_number":149,"context_line":"# extensions \u003d keystone.contrib.example.controllers.ExampleV3Controller"},{"line_number":150,"context_line":""},{"line_number":151,"context_line":"[sql]"},{"line_number":152,"context_line":"# The SQLAlchemy connection string used to connect to the database"}],"source_content_type":"application/octet-stream","patch_set":9,"id":"AAAATn%2F9kus%3D","line":149,"in_reply_to":"AAAATn%2F9k1A%3D","updated":"2013-12-10 03:56:32.000000000","message":"This is actually not necessary anymore. I will take it out alltogether","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"21d34f52b7b9f58216d76fb2e9e869e6e69f5aef","unresolved":false,"context_lines":[{"line_number":100,"context_line":"# Logging driver example (not enabled by default)"},{"line_number":101,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.log_notifier"},{"line_number":102,"context_line":"# RPC driver example (not enabled by default)"},{"line_number":103,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"# Default notification level for outgoing notifications"},{"line_number":106,"context_line":"# default_notification_level \u003d INFO"}],"source_content_type":"application/octet-stream","patch_set":12,"id":"AAAATn%2F9U2w%3D","line":103,"updated":"2013-12-12 16:37:00.000000000","message":"You should not remove the example RPC notification line, add a comment and this line instead of replacing the other line.","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"190039906140960855f6a01e19f147001f6a41aa","unresolved":false,"context_lines":[{"line_number":100,"context_line":"# Logging driver example (not enabled by default)"},{"line_number":101,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.log_notifier"},{"line_number":102,"context_line":"# RPC driver example (not enabled by default)"},{"line_number":103,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":104,"context_line":""},{"line_number":105,"context_line":"# Default notification level for outgoing notifications"},{"line_number":106,"context_line":"# default_notification_level \u003d INFO"}],"source_content_type":"application/octet-stream","patch_set":12,"id":"AAAATn%2F9S%2BM%3D","line":103,"in_reply_to":"AAAATn%2F9U2w%3D","updated":"2013-12-13 20:45:29.000000000","message":"Done","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":101,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.log_notifier"},{"line_number":102,"context_line":"# RPC driver example (not enabled by default)"},{"line_number":103,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.rpc_notifier"},{"line_number":104,"context_line":"# Keystone Extensions Notification Driver (not enabled by default)"},{"line_number":105,"context_line":"# notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":106,"context_line":""},{"line_number":107,"context_line":"# Default notification level for outgoing notifications"}],"source_content_type":"application/octet-stream","patch_set":20,"id":"AAAAUH%2F%2F5x8%3D","line":104,"updated":"2014-01-07 01:33:31.000000000","message":"why wouldn\u0027t this be enabled by default?","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"184b5a9c74115584eca475b22bd99a98cf2bd8ea","unresolved":false,"context_lines":[{"line_number":111,"context_line":"# RPC driver example (not enabled by default)"},{"line_number":112,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.rpc_notifier"},{"line_number":113,"context_line":"# Keystone Extensions Notification Driver (enabled by default)"},{"line_number":114,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"# Default notification level for outgoing notifications"},{"line_number":117,"context_line":"# default_notification_level \u003d INFO"}],"source_content_type":"application/octet-stream","patch_set":21,"id":"AAAAUH%2F%2FsIA%3D","line":114,"updated":"2014-01-09 16:14:58.000000000","message":"probably should be disabled by default","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"924e689784b175c945d214273b453bda683567f5","unresolved":false,"context_lines":[{"line_number":111,"context_line":"# RPC driver example (not enabled by default)"},{"line_number":112,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.rpc_notifier"},{"line_number":113,"context_line":"# Keystone Extensions Notification Driver (enabled by default)"},{"line_number":114,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"# Default notification level for outgoing notifications"},{"line_number":117,"context_line":"# default_notification_level \u003d INFO"}],"source_content_type":"application/octet-stream","patch_set":21,"id":"AAAAUH%2F%2Frr4%3D","line":114,"in_reply_to":"AAAAUH%2F%2FsIA%3D","updated":"2014-01-09 16:55:36.000000000","message":"I think we should be enabling it by default. It is part of the extension framework itself. Extensions which does not care about notifications, it is essentially a no-op for them.","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":104,"context_line":"# sent, the default)"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"# notification_driver can be defined multiple times"},{"line_number":107,"context_line":"# Do nothing driver (the default)"},{"line_number":108,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.no_op_notifier"},{"line_number":109,"context_line":"# Logging driver example (not enabled by default)"},{"line_number":110,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.log_notifier"}],"source_content_type":"application/octet-stream","patch_set":22,"id":"AAAAUH%2F%2FWdw%3D","line":107,"updated":"2014-01-14 19:16:58.000000000","message":"this conflicts with the \"enabled by default\" below","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"0c1383f62b69a14afd676b7aff4418535bf327a9","unresolved":false,"context_lines":[{"line_number":104,"context_line":"# sent, the default)"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"# notification_driver can be defined multiple times"},{"line_number":107,"context_line":"# Do nothing driver (the default)"},{"line_number":108,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.no_op_notifier"},{"line_number":109,"context_line":"# Logging driver example (not enabled by default)"},{"line_number":110,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.log_notifier"}],"source_content_type":"application/octet-stream","patch_set":22,"id":"AAAAUH%2F%2FQ0Q%3D","line":107,"in_reply_to":"AAAAUH%2F%2FWdw%3D","updated":"2014-01-15 19:00:55.000000000","message":"looking at the code, seem like nothing is enabled by default\n\nhttps://github.com/openstack/keystone/blob/master/keystone/openstack/common/notifier/api.py#L33","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":111,"context_line":"# RPC driver example (not enabled by default)"},{"line_number":112,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.rpc_notifier"},{"line_number":113,"context_line":"# Keystone Extensions Notification Driver (enabled by default)"},{"line_number":114,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"# Default notification level for outgoing notifications"},{"line_number":117,"context_line":"# default_notification_level \u003d INFO"}],"source_content_type":"application/octet-stream","patch_set":22,"id":"AAAAUH%2F%2FWd8%3D","line":114,"updated":"2014-01-14 19:16:58.000000000","message":"the value should be commented out regardless, and indicate the default","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"0c1383f62b69a14afd676b7aff4418535bf327a9","unresolved":false,"context_lines":[{"line_number":111,"context_line":"# RPC driver example (not enabled by default)"},{"line_number":112,"context_line":"# notification_driver \u003d keystone.openstack.common.notifier.rpc_notifier"},{"line_number":113,"context_line":"# Keystone Extensions Notification Driver (enabled by default)"},{"line_number":114,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"# Default notification level for outgoing notifications"},{"line_number":117,"context_line":"# default_notification_level \u003d INFO"}],"source_content_type":"application/octet-stream","patch_set":22,"id":"AAAAUH%2F%2FQzo%3D","line":114,"in_reply_to":"AAAAUH%2F%2FWd8%3D","updated":"2014-01-15 19:00:55.000000000","message":"sure I can commented it out. But it doesn\u0027t appear any drivers are enabled by default.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"}],"keystone/common/dependency.py":[{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"184b5a9c74115584eca475b22bd99a98cf2bd8ea","unresolved":false,"context_lines":[{"line_number":75,"context_line":"                    for resource_type in event:"},{"line_number":76,"context_line":"                        # Make sure we register the provider for each event it"},{"line_number":77,"context_line":"                        # cares to be notified about."},{"line_number":78,"context_line":"                        cb \u003d event[resource_type]"},{"line_number":79,"context_line":"                        if not cb:"},{"line_number":80,"context_line":"                            continue"},{"line_number":81,"context_line":"                        if not hasattr(cb, \u0027__iter__\u0027):"}],"source_content_type":"text/x-python","patch_set":21,"id":"AAAAUH%2F%2Fr%2BE%3D","line":78,"updated":"2014-01-09 16:14:58.000000000","message":"nit: can we write you cb as callback","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"924e689784b175c945d214273b453bda683567f5","unresolved":false,"context_lines":[{"line_number":75,"context_line":"                    for resource_type in event:"},{"line_number":76,"context_line":"                        # Make sure we register the provider for each event it"},{"line_number":77,"context_line":"                        # cares to be notified about."},{"line_number":78,"context_line":"                        cb \u003d event[resource_type]"},{"line_number":79,"context_line":"                        if not cb:"},{"line_number":80,"context_line":"                            continue"},{"line_number":81,"context_line":"                        if not hasattr(cb, \u0027__iter__\u0027):"}],"source_content_type":"text/x-python","patch_set":21,"id":"AAAAUH%2F%2Frrk%3D","line":78,"in_reply_to":"AAAAUH%2F%2Fr%2BE%3D","updated":"2014-01-09 16:55:36.000000000","message":"will do","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":67,"context_line":"    \"\"\""},{"line_number":68,"context_line":"    def wrapper(cls):"},{"line_number":69,"context_line":"        def wrapped(init):"},{"line_number":70,"context_line":"            def __register_event_notifications(self):"},{"line_number":71,"context_line":"                for event in getattr(self, \u0027notification_subscriptions\u0027, {}):"},{"line_number":72,"context_line":"                    if not isinstance(event, dict):"},{"line_number":73,"context_line":"                        msg \u003d _(\u0027notification_subscriptions must be a dict\u0027)"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWdE%3D","line":70,"updated":"2014-01-14 19:16:58.000000000","message":"this is a counter-intuitive place to put this... shouldn\u0027t it be it\u0027s own decorator?","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"0c1383f62b69a14afd676b7aff4418535bf327a9","unresolved":false,"context_lines":[{"line_number":67,"context_line":"    \"\"\""},{"line_number":68,"context_line":"    def wrapper(cls):"},{"line_number":69,"context_line":"        def wrapped(init):"},{"line_number":70,"context_line":"            def __register_event_notifications(self):"},{"line_number":71,"context_line":"                for event in getattr(self, \u0027notification_subscriptions\u0027, {}):"},{"line_number":72,"context_line":"                    if not isinstance(event, dict):"},{"line_number":73,"context_line":"                        msg \u003d _(\u0027notification_subscriptions must be a dict\u0027)"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FQsk%3D","line":70,"in_reply_to":"AAAAUH%2F%2FReU%3D","updated":"2014-01-15 19:00:55.000000000","message":"Agree with Morgan. The main use case for notifications subscription is to update the corresponding data when the related data has changed as we are further decoupling relational data to support other backends (i.e. non-relational data stores). Providers are responsible for data manipulation so this is the right place for it.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":67,"context_line":"    \"\"\""},{"line_number":68,"context_line":"    def wrapper(cls):"},{"line_number":69,"context_line":"        def wrapped(init):"},{"line_number":70,"context_line":"            def __register_event_notifications(self):"},{"line_number":71,"context_line":"                for event in getattr(self, \u0027notification_subscriptions\u0027, {}):"},{"line_number":72,"context_line":"                    if not isinstance(event, dict):"},{"line_number":73,"context_line":"                        msg \u003d _(\u0027notification_subscriptions must be a dict\u0027)"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FReU%3D","line":70,"in_reply_to":"AAAAUH%2F%2FWdE%3D","updated":"2014-01-15 16:19:47.000000000","message":"This is the right place to do the registration, but this need a large comment block explaining why it is here.  Also the there is no reason to use the prefix \u0027__\u0027 this is a private function isolated to the \"wrapped\" method.\n\nSo, suggest fixing the \"name\" of the function and make sure this is well documented here in-line so it is clear why it\u0027s implemented here.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b510e2fee70ec2c21a5673b2432903ac8c3f6b75","unresolved":false,"context_lines":[{"line_number":99,"context_line":"                        def project_deleted_callback(self,"},{"line_number":100,"context_line":"                                                     context,"},{"line_number":101,"context_line":"                                                     message):"},{"line_number":102,"context_line":"                        # cleanup data related to the deleted project here"},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"                A callback must accept the following arguments:"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":24,"id":"AAAAUH%2F%2FLX4%3D","line":102,"updated":"2014-01-16 18:18:41.000000000","message":"this example should be simplified quite a bit","commit_id":"04e2c987a924cdaba69f566d55ae1183efd19cf6"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b510e2fee70ec2c21a5673b2432903ac8c3f6b75","unresolved":false,"context_lines":[{"line_number":115,"context_line":""},{"line_number":116,"context_line":"                for event in self.event_callbacks:"},{"line_number":117,"context_line":"                    if not isinstance(self.event_callbacks[event], dict):"},{"line_number":118,"context_line":"                        msg \u003d _(\u0027event_callbacks[%s] must be a dict\u0027) % ("},{"line_number":119,"context_line":"                            event)"},{"line_number":120,"context_line":"                        raise ValueError(msg)"},{"line_number":121,"context_line":"                    for resource_type in self.event_callbacks[event]:"}],"source_content_type":"text/x-python","patch_set":24,"id":"AAAAUH%2F%2FLXY%3D","line":118,"updated":"2014-01-16 18:18:41.000000000","message":"pep8: add more parens","commit_id":"04e2c987a924cdaba69f566d55ae1183efd19cf6"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"3d23ad6e3762b61f1b6e7daf98d8b64cbd355caf","unresolved":false,"context_lines":[{"line_number":68,"context_line":"    def wrapper(cls):"},{"line_number":69,"context_line":"        def wrapped(init):"},{"line_number":70,"context_line":"            def register_event_callbacks(self):"},{"line_number":71,"context_line":"                # NOTE(morganfainberg): #A provider who has an implicit"},{"line_number":72,"context_line":"                # dependency on other providers may utilize the event callback"},{"line_number":73,"context_line":"                # mechanism to react to any changes in those providers. This is"},{"line_number":74,"context_line":"                # performed at the .provider() mechanism so that we can ensure"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FLDI%3D","line":71,"updated":"2014-01-16 18:59:02.000000000","message":"s/#A/a/","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":68,"context_line":"    def wrapper(cls):"},{"line_number":69,"context_line":"        def wrapped(init):"},{"line_number":70,"context_line":"            def register_event_callbacks(self):"},{"line_number":71,"context_line":"                # NOTE(morganfainberg): #A provider who has an implicit"},{"line_number":72,"context_line":"                # dependency on other providers may utilize the event callback"},{"line_number":73,"context_line":"                # mechanism to react to any changes in those providers. This is"},{"line_number":74,"context_line":"                # performed at the .provider() mechanism so that we can ensure"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FKnA%3D","line":71,"in_reply_to":"AAAAUH%2F%2FLDI%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"}],"keystone/common/extensions_notifier.py":[{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":26,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":27,"context_line":"    global subscribers"},{"line_number":28,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":29,"context_line":"        if not hasattr(subscription_callback, \u0027__call__\u0027):"},{"line_number":30,"context_line":"            msg \u003d _(\u0027Method not callable: %(method)s for \u0027"},{"line_number":31,"context_line":"                    \u0027%(event)s.\u0027)"},{"line_number":32,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback.__name__,"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kJc%3D","line":29,"updated":"2013-12-10 07:29:50.000000000","message":"suggest change this if-check to \"if not callable(subscription_callback):\"","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":26,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":27,"context_line":"    global subscribers"},{"line_number":28,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":29,"context_line":"        if not hasattr(subscription_callback, \u0027__call__\u0027):"},{"line_number":30,"context_line":"            msg \u003d _(\u0027Method not callable: %(method)s for \u0027"},{"line_number":31,"context_line":"                    \u0027%(event)s.\u0027)"},{"line_number":32,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback.__name__,"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9gwg%3D","line":29,"in_reply_to":"AAAATn%2F9kJc%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":32,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback.__name__,"},{"line_number":33,"context_line":"                            \u0027event\u0027: subscription_event})"},{"line_number":34,"context_line":"        else:"},{"line_number":35,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":36,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":37,"context_line":"                subscription_callback)"},{"line_number":38,"context_line":"            msg \u003d _(\u0027Callback: %(method)s of module %(module)s, subscribed \u0027"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kHU%3D","line":35,"updated":"2013-12-10 07:29:50.000000000","message":"Suggest validating the event is a \"valid\" event to subscribe to (if this validation is added, a test should also be added to make sure invalid events cannot be subscribed to).","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":32,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback.__name__,"},{"line_number":33,"context_line":"                            \u0027event\u0027: subscription_event})"},{"line_number":34,"context_line":"        else:"},{"line_number":35,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":36,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":37,"context_line":"                subscription_callback)"},{"line_number":38,"context_line":"            msg \u003d _(\u0027Callback: %(method)s of module %(module)s, subscribed \u0027"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fTI%3D","line":35,"in_reply_to":"AAAATn%2F9kHU%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":38,"context_line":"            msg \u003d _(\u0027Callback: %(method)s of module %(module)s, subscribed \u0027"},{"line_number":39,"context_line":"                    \u0027to event %(event)s.\u0027)"},{"line_number":40,"context_line":"            LOG.info(msg, {\u0027method\u0027: subscription_callback.__name__,"},{"line_number":41,"context_line":"                           \u0027module\u0027: subscription_callback.__module__,"},{"line_number":42,"context_line":"                           \u0027event\u0027: subscription_event})"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kIM%3D","line":41,"updated":"2013-12-10 07:29:50.000000000","message":"This log call would miss the class the method is defined on in the case of a bound method/classmethod/staticmethod as you\u0027re only extracting __name__ and __module__.\nExample: if callback is `example_module.ExampleClass.callback`, this would log \"method: callback\", \"module: example_module\", \"Event: \u003cevent\u003e\".\n\nIt wont miss any data on module-level functions.","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":38,"context_line":"            msg \u003d _(\u0027Callback: %(method)s of module %(module)s, subscribed \u0027"},{"line_number":39,"context_line":"                    \u0027to event %(event)s.\u0027)"},{"line_number":40,"context_line":"            LOG.info(msg, {\u0027method\u0027: subscription_callback.__name__,"},{"line_number":41,"context_line":"                           \u0027module\u0027: subscription_callback.__module__,"},{"line_number":42,"context_line":"                           \u0027event\u0027: subscription_event})"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fRo%3D","line":41,"in_reply_to":"AAAATn%2F9kIM%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":53,"context_line":"                    \u0027%(message)s.\u0027)"},{"line_number":54,"context_line":"            LOG.info(msg, {\u0027method\u0027: extension.__name__,"},{"line_number":55,"context_line":"                           \u0027module\u0027: extension.__module__,"},{"line_number":56,"context_line":"                           \u0027message\u0027: message.get(\u0027message_id\u0027)})"},{"line_number":57,"context_line":"            extension(context, message)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kGY%3D","line":56,"updated":"2013-12-10 07:29:50.000000000","message":"Recommend remove this logline completely, the callback can log if desired.  As it stands, this will get very spammy in the logs (each event logging N times, where N is the number of registrations on top of the normal logging).","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":53,"context_line":"                    \u0027%(message)s.\u0027)"},{"line_number":54,"context_line":"            LOG.info(msg, {\u0027method\u0027: extension.__name__,"},{"line_number":55,"context_line":"                           \u0027module\u0027: extension.__module__,"},{"line_number":56,"context_line":"                           \u0027message\u0027: message.get(\u0027message_id\u0027)})"},{"line_number":57,"context_line":"            extension(context, message)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fSw%3D","line":56,"in_reply_to":"AAAATn%2F9kGY%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"21d34f52b7b9f58216d76fb2e9e869e6e69f5aef","unresolved":false,"context_lines":[{"line_number":27,"context_line":"def register(subscriptions):"},{"line_number":28,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":29,"context_line":"    global subscribers"},{"line_number":30,"context_line":"    pattern \u003d \u0027(identity.(group|project|role|user).(created|updated|deleted))\u0027"},{"line_number":31,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":32,"context_line":"        if (callable(subscription_callback) and"},{"line_number":33,"context_line":"                re.match(pattern, subscription_event)):"}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F9U4M%3D","line":30,"updated":"2013-12-12 16:37:00.000000000","message":"suggest pre-compiling this as an instance variable.  It has lower over head to do re.compile and use the returned object instead of forcing a compile of the regex each time.","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"190039906140960855f6a01e19f147001f6a41aa","unresolved":false,"context_lines":[{"line_number":27,"context_line":"def register(subscriptions):"},{"line_number":28,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":29,"context_line":"    global subscribers"},{"line_number":30,"context_line":"    pattern \u003d \u0027(identity.(group|project|role|user).(created|updated|deleted))\u0027"},{"line_number":31,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":32,"context_line":"        if (callable(subscription_callback) and"},{"line_number":33,"context_line":"                re.match(pattern, subscription_event)):"}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F9OLg%3D","line":30,"in_reply_to":"AAAATn%2F9U4M%3D","updated":"2013-12-13 20:45:29.000000000","message":"Done","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"21d34f52b7b9f58216d76fb2e9e869e6e69f5aef","unresolved":false,"context_lines":[{"line_number":44,"context_line":"                           \u0027event\u0027: subscription_event})"},{"line_number":45,"context_line":"        else:"},{"line_number":46,"context_line":"            msg \u003d _(\u0027Method not callable: %(method)s or %(event)s.\u0027"},{"line_number":47,"context_line":"                    \u0027not recognized.\u0027)"},{"line_number":48,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback,"},{"line_number":49,"context_line":"                            \u0027event\u0027: subscription_event})"},{"line_number":50,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F9U3s%3D","line":47,"updated":"2013-12-12 16:37:00.000000000","message":"Suggest splitting this out to two distinct errors, either method is not callable or unrecognized event.","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"190039906140960855f6a01e19f147001f6a41aa","unresolved":false,"context_lines":[{"line_number":44,"context_line":"                           \u0027event\u0027: subscription_event})"},{"line_number":45,"context_line":"        else:"},{"line_number":46,"context_line":"            msg \u003d _(\u0027Method not callable: %(method)s or %(event)s.\u0027"},{"line_number":47,"context_line":"                    \u0027not recognized.\u0027)"},{"line_number":48,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback,"},{"line_number":49,"context_line":"                            \u0027event\u0027: subscription_event})"},{"line_number":50,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F9OLc%3D","line":47,"in_reply_to":"AAAATn%2F9U3s%3D","updated":"2013-12-13 20:45:29.000000000","message":"Done","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":36,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KD4%3D","line":33,"updated":"2013-12-16 08:15:00.000000000","message":"might be better to have pattern and p\u003dre.compile just outside the for loop, but not at the class level. I don\u0027t think they are used outside of it anyway","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":36,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HR8%3D","line":33,"in_reply_to":"AAAATn%2F9KD4%3D","updated":"2013-12-16 17:36:37.000000000","message":"Actually no, because when an extension registers it will invoke the method and a new compilation will be performed. Being outside I make sure it will be executed only once.","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"d558df9a7d3688c72cd1123d76808a35514a2c30","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":36,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAATn%2F9GDw%3D","line":33,"updated":"2013-12-16 21:03:08.000000000","message":"Why are the extensions limited to only registering  keystone events\n i.e. identity.(group|project|role|user).created|updated|deleted) ? \nAre there not use cases where the extensions would be\n interested in other events outside of keystone?  Or are they \nexpected to register for non-keystone events in a different way?","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"efe66af003b90c29c238d97566df9d9c14cb00a2","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":36,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAATn%2F9A4c%3D","line":33,"in_reply_to":"AAAATn%2F9FjQ%3D","updated":"2013-12-17 17:35:40.000000000","message":"Brad, I made the changes in the Extensions_howto docs.\nI specifically mentioned that the code only notifies on specific events for selected resources. Hope this is good to go now ...","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"9a5af9f5b8b1c7923833d7b28440a47a22bde498","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":36,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAATn%2F9FjQ%3D","line":33,"in_reply_to":"AAAATn%2F9Fps%3D","updated":"2013-12-16 22:28:43.000000000","message":"I think it is worth adding a sentence to the Event Notification section of the how to explain this scope clarification","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"4b8383d7986eda4a53a39acd4077773a02fa0940","unresolved":false,"context_lines":[{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":36,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":15,"id":"AAAATn%2F9Fps%3D","line":33,"in_reply_to":"AAAATn%2F9GDw%3D","updated":"2013-12-16 22:12:43.000000000","message":"Brad, this patch is to notify the extensions of keystone data changes with the main aim to maintain the different data sets in sync. If you want a global event notification you can leverage the queue mechanism or any other that may make sense.","commit_id":"6a6ba5c88cfa058b39ccba54535076372535b742"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":22,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"subscribers \u003d {}"},{"line_number":25,"context_line":"pattern \u003d \u0027(identity.(group|project|role|user).(created|updated|deleted))\u0027"},{"line_number":26,"context_line":"p \u003d re.compile(pattern)"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F84x4%3D","line":25,"updated":"2013-12-19 06:24:26.000000000","message":"don\u0027t think this is correct. Should be\n\npattern \u003d \u0027^identity\\.(group|project|role|user)\\.(created|updated|deleted)$\u0027","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":22,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"subscribers \u003d {}"},{"line_number":25,"context_line":"pattern \u003d \u0027(identity.(group|project|role|user).(created|updated|deleted))\u0027"},{"line_number":26,"context_line":"p \u003d re.compile(pattern)"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F81wI%3D","line":25,"in_reply_to":"AAAATn%2F84x4%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":29,"context_line":"def register(subscriptions):"},{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F84xo%3D","line":32,"updated":"2013-12-19 06:24:26.000000000","message":"make sure the string is clean before doing the match\n\nsubscription_event \u003d subscription_event.strip()","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":29,"context_line":"def register(subscriptions):"},{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"},{"line_number":34,"context_line":"            subscribers.setdefault(subscription_event, {\u0027subscribers\u0027: []})"},{"line_number":35,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F81v8%3D","line":32,"in_reply_to":"AAAATn%2F84xo%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":26,"context_line":"p \u003d re.compile(pattern)"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"def register(subscriptions):"},{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5xw%3D","line":29,"updated":"2014-01-07 01:33:31.000000000","message":"this is a really dense method... a bit of whitespace where appropriate would be appreciated","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":28,"context_line":""},{"line_number":29,"context_line":"def register(subscriptions):"},{"line_number":30,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":31,"context_line":"    global subscribers"},{"line_number":32,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":33,"context_line":"        subscription_event \u003d subscription_event.strip()"},{"line_number":34,"context_line":"        if (callable(subscription_callback) and p.match(subscription_event)):"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5x4%3D","line":31,"updated":"2014-01-07 01:33:31.000000000","message":"this doesn\u0027t look like it needs to be declared as a global in this scope","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":54,"context_line":"def notify(context, message):"},{"line_number":55,"context_line":"    \"\"\"Sends a notification to registered extensions.\"\"\""},{"line_number":56,"context_line":"    if not context:"},{"line_number":57,"context_line":"        context \u003d req_context.get_admin_context()"},{"line_number":58,"context_line":"    event \u003d message.get(\u0027event_type\u0027)"},{"line_number":59,"context_line":"    if event in subscribers.keys():"},{"line_number":60,"context_line":"        for extension in subscribers[event][\u0027subscribers\u0027]:"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5v8%3D","line":57,"updated":"2014-01-07 01:33:31.000000000","message":"why get_admin_context() ?","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"subscribers \u003d {}"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def register(event, resource_type, callbacks):"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWWA%3D","line":23,"updated":"2014-01-14 19:16:58.000000000","message":"module level CONSTANTS should appear in all caps","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"0c1383f62b69a14afd676b7aff4418535bf327a9","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"subscribers \u003d {}"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def register(event, resource_type, callbacks):"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FQr8%3D","line":23,"in_reply_to":"AAAAUH%2F%2FReM%3D","updated":"2014-01-15 19:00:55.000000000","message":"sure. Will use the ALL CAPS convention.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":20,"context_line":""},{"line_number":21,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"subscribers \u003d {}"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def register(event, resource_type, callbacks):"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FReM%3D","line":23,"in_reply_to":"AAAAUH%2F%2FWWA%3D","updated":"2014-01-15 16:19:47.000000000","message":"++","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":25,"context_line":""},{"line_number":26,"context_line":"def register(event, resource_type, callbacks):"},{"line_number":27,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":28,"context_line":"    global subscribers"},{"line_number":29,"context_line":"    if event not in notifications.ACTIONS:"},{"line_number":30,"context_line":"        raise ValueError(_(\u0027%(event)s is not a valid notification event, \u0027"},{"line_number":31,"context_line":"                           \u0027must be one of: %(actions)s\u0027),"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWV8%3D","line":28,"updated":"2014-01-14 19:16:58.000000000","message":"remove - you\u0027re not writing to this as a global","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    \"\"\"Registers all the extensions listening to a specific event.\"\"\""},{"line_number":28,"context_line":"    global subscribers"},{"line_number":29,"context_line":"    if event not in notifications.ACTIONS:"},{"line_number":30,"context_line":"        raise ValueError(_(\u0027%(event)s is not a valid notification event, \u0027"},{"line_number":31,"context_line":"                           \u0027must be one of: %(actions)s\u0027),"},{"line_number":32,"context_line":"                         {\u0027event\u0027: event,"},{"line_number":33,"context_line":"                          \u0027actions\u0027: \u0027, \u0027.join(notifications.ACTIONS)})"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWUc%3D","line":30,"updated":"2014-01-14 19:16:58.000000000","message":"it\u0027d be nice to raise a custom exception here","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":32,"context_line":"                         {\u0027event\u0027: event,"},{"line_number":33,"context_line":"                          \u0027actions\u0027: \u0027, \u0027.join(notifications.ACTIONS)})"},{"line_number":34,"context_line":"    if resource_type not in notifications.RESOURCE_TYPES:"},{"line_number":35,"context_line":"        raise ValueError(_(\u0027%(resource_type)s is not a valid notification \u0027"},{"line_number":36,"context_line":"                           \u0027resource, must be one of: %(types)s\u0027),"},{"line_number":37,"context_line":"                         {\u0027resource_type\u0027: resource_type,"},{"line_number":38,"context_line":"                          \u0027types\u0027: \u0027, \u0027.join(notifications.RESOURCE_TYPES)})"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWUY%3D","line":35,"updated":"2014-01-14 19:16:58.000000000","message":"and here","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":44,"context_line":"        if not callable(cb):"},{"line_number":45,"context_line":"            LOG.error(_(\u0027Method not callable: %s\u0027), cb)"},{"line_number":46,"context_line":"            continue"},{"line_number":47,"context_line":"        subscribers.setdefault(event, {}).setdefault(resource_type, set())"},{"line_number":48,"context_line":"        subscribers[event][resource_type].add(cb)"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"        msg \u003d _(\u0027Callback: `%(callback)s` subscribed to event `%(event)s`.\u0027)"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWVc%3D","line":47,"updated":"2014-01-14 19:16:58.000000000","message":"SUBSCRIBERS","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":55,"context_line":"            cb_info \u003d [getattr(cb, \u0027__module__\u0027, None), cb.__name__]"},{"line_number":56,"context_line":"        cb_str \u003d \u0027.\u0027.join(filter(lambda i: i is not None, cb_info))"},{"line_number":57,"context_line":"        event_str \u003d \u0027.\u0027.join([\u0027identity\u0027, resource_type, event])"},{"line_number":58,"context_line":"        LOG.info(msg, {\u0027callback\u0027: cb_str, \u0027event\u0027: event_str})"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"def notify(context, message):"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWTs%3D","line":58,"updated":"2014-01-14 19:16:58.000000000","message":"this is doing a lot of work to produce an info message.. wrap all the extraneous work in a conditional block that won\u0027t be executed if it\u0027s not going to appear in the log anyway","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":65,"context_line":"    event \u003d message.get(\u0027event_type\u0027)"},{"line_number":66,"context_line":"    event_type, resource_type, operation \u003d event.split(\u0027.\u0027)"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"    if operation in subscribers:"},{"line_number":69,"context_line":"        if resource_type in subscribers[operation]:"},{"line_number":70,"context_line":"            for cb in subscribers[operation][resource_type]:"},{"line_number":71,"context_line":"                LOG.debug(\u0027invoking callback %(cb_name)s for event %(event)s\u0027,"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWVg%3D","line":68,"updated":"2014-01-14 19:16:58.000000000","message":"SUBSCRIBERS","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"}],"keystone/contrib/example/__init__.py":[{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from keystone.contrib.example import controllers"},{"line_number":19,"context_line":"from keystone.openstack.common.notifier import extensions_notifier"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"controller \u003d controllers.ExampleV3Controller()"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"subscribed_events \u003d {"},{"line_number":24,"context_line":"    \u0027identity.project.deleted\u0027: controller.project_deleted_notification,"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9lEc%3D","line":21,"updated":"2013-12-10 01:21:24.000000000","message":"don\u0027t need to instantiate in order to call the static class methods","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from keystone.contrib.example import controllers"},{"line_number":19,"context_line":"from keystone.openstack.common.notifier import extensions_notifier"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"controller \u003d controllers.ExampleV3Controller()"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"subscribed_events \u003d {"},{"line_number":24,"context_line":"    \u0027identity.project.deleted\u0027: controller.project_deleted_notification,"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9k3k%3D","line":21,"in_reply_to":"AAAATn%2F9lEc%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":21,"context_line":"controller \u003d controllers.ExampleV3Controller()"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"subscribed_events \u003d {"},{"line_number":24,"context_line":"    \u0027identity.project.deleted\u0027: controller.project_deleted_notification,"},{"line_number":25,"context_line":"    \u0027identity.project.created\u0027: controller.project_created_notification"},{"line_number":26,"context_line":"}"},{"line_number":27,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9lEU%3D","line":24,"updated":"2013-12-10 01:21:24.000000000","message":"you can just do this\n\ncontrollers.ExampleV3Controller.project_deleted_notification","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":21,"context_line":"controller \u003d controllers.ExampleV3Controller()"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"subscribed_events \u003d {"},{"line_number":24,"context_line":"    \u0027identity.project.deleted\u0027: controller.project_deleted_notification,"},{"line_number":25,"context_line":"    \u0027identity.project.created\u0027: controller.project_created_notification"},{"line_number":26,"context_line":"}"},{"line_number":27,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9k3Y%3D","line":24,"in_reply_to":"AAAATn%2F9lEU%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"}],"keystone/contrib/example/configuration.rst":[{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    ./bin/keystone-manage db_sync --extension example"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"4. Optional: subscribe to ``core entities`` notification events"},{"line_number":34,"context_line":"   In order to subscribe to event notifications, the extension must provide the list of it is events its interested and their corresponding callbacks."},{"line_number":35,"context_line":"   In the main ``__init__.py`` file the following dictionary has to be created:"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"AAAATn%2F9lDw%3D","line":34,"updated":"2013-12-10 01:21:24.000000000","message":"s/list of it is events its interested/list of events it is interested in/","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    ./bin/keystone-manage db_sync --extension example"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"4. Optional: subscribe to ``core entities`` notification events"},{"line_number":34,"context_line":"   In order to subscribe to event notifications, the extension must provide the list of it is events its interested and their corresponding callbacks."},{"line_number":35,"context_line":"   In the main ``__init__.py`` file the following dictionary has to be created:"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"AAAATn%2F9k3U%3D","line":34,"in_reply_to":"AAAATn%2F9lDw%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":37,"context_line":""},{"line_number":38,"context_line":".. code:: python"},{"line_number":39,"context_line":"       subscribed_events \u003d {"},{"line_number":40,"context_line":"          \u0027identity.project.deleted\u0027: controllers.ExampleV3Controller().project_deleted_notification,"},{"line_number":41,"context_line":"          \u0027identity.project.created\u0027: controllers.ExampleV3Controller().project_created_notification"},{"line_number":42,"context_line":"       }"},{"line_number":43,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"AAAATn%2F9lDY%3D","line":40,"updated":"2013-12-10 01:21:24.000000000","message":"those are static methods, no need to instantiate the class\n\ncontrollers.ExampleV3Controller.project_deleted_notification","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":37,"context_line":""},{"line_number":38,"context_line":".. code:: python"},{"line_number":39,"context_line":"       subscribed_events \u003d {"},{"line_number":40,"context_line":"          \u0027identity.project.deleted\u0027: controllers.ExampleV3Controller().project_deleted_notification,"},{"line_number":41,"context_line":"          \u0027identity.project.created\u0027: controllers.ExampleV3Controller().project_created_notification"},{"line_number":42,"context_line":"       }"},{"line_number":43,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"AAAATn%2F9k2Y%3D","line":40,"in_reply_to":"AAAATn%2F9lDY%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    ./bin/keystone-manage db_sync --extension example"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"4. Optional: subscribe to ``core entities`` notification events"},{"line_number":34,"context_line":"   In order to subscribe to event notifications, the extension must provide the list of events it is interested in and their corresponding callbacks."},{"line_number":35,"context_line":"   In the main ``__init__.py`` file the following dictionary has to be created:"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"AAAATn%2F9kHk%3D","line":33,"updated":"2013-12-10 07:29:50.000000000","message":"What is a \"core entity\"?  Please provide some more context on this documentation.","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    ./bin/keystone-manage db_sync --extension example"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"4. Optional: subscribe to ``core entities`` notification events"},{"line_number":34,"context_line":"   In order to subscribe to event notifications, the extension must provide the list of events it is interested in and their corresponding callbacks."},{"line_number":35,"context_line":"   In the main ``__init__.py`` file the following dictionary has to be created:"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-rst","patch_set":10,"id":"AAAATn%2F9fPs%3D","line":33,"in_reply_to":"AAAATn%2F9kHk%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done. I changed to resources which is more appropriate and listed the current supported set.","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    - ``group``"},{"line_number":38,"context_line":"    - ``project`` (i.e. \"tenant\")"},{"line_number":39,"context_line":"    - ``role``"},{"line_number":40,"context_line":"    - ``user``"},{"line_number":41,"context_line":""}],"source_content_type":"text/x-rst","patch_set":14,"id":"AAAATn%2F9KDg%3D","line":38,"updated":"2013-12-16 08:15:00.000000000","message":"at this point, we should remove the word tenant, it\u0027s only in the notifications docs because end-users might read it, but for *new* extensions lets just use projects.","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    - ``group``"},{"line_number":38,"context_line":"    - ``project`` (i.e. \"tenant\")"},{"line_number":39,"context_line":"    - ``role``"},{"line_number":40,"context_line":"    - ``user``"},{"line_number":41,"context_line":""}],"source_content_type":"text/x-rst","patch_set":14,"id":"AAAATn%2F9HRs%3D","line":38,"in_reply_to":"AAAATn%2F9KDg%3D","updated":"2013-12-16 17:36:37.000000000","message":"Done","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":37,"context_line":"    - ``group``"},{"line_number":38,"context_line":"    - ``project``"},{"line_number":39,"context_line":"    - ``role``"},{"line_number":40,"context_line":"    - ``user``"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"   In order to subscribe to event notifications, the extension must provide the list of events it is interested in and their corresponding callbacks."}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAAUH%2F%2F5xY%3D","line":40,"updated":"2014-01-07 01:33:31.000000000","message":"please don\u0027t document this twice -- it doesn\u0027t need to be maintained more than once. link to the other doc if you really want to","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":""},{"line_number":64,"context_line":".. code:: python"},{"line_number":65,"context_line":"       extensions_notifier.register(subscribed_events)"}],"source_content_type":"text/x-rst","patch_set":20,"id":"AAAAUH%2F%2F5xk%3D","line":65,"updated":"2014-01-07 01:33:31.000000000","message":"as before, replace the triple line breaks with double line breaks throughout","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    ./bin/keystone-manage db_sync --extension example"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"4. Optional: subscribe to ``resources`` notification events. See"},{"line_number":34,"context_line":"   :doc:`EXTENSIONS_HOWTO` for more details."}],"source_content_type":"text/x-rst","patch_set":22,"id":"AAAAUH%2F%2FWVU%3D","line":34,"updated":"2014-01-14 19:16:58.000000000","message":"i don\u0027t think this addition belongs in this file at all. this file is a stub of what an extension\u0027s documentation should look like, not documentation for extension authors.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"0c1383f62b69a14afd676b7aff4418535bf327a9","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    ./bin/keystone-manage db_sync --extension example"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"4. Optional: subscribe to ``resources`` notification events. See"},{"line_number":34,"context_line":"   :doc:`EXTENSIONS_HOWTO` for more details."}],"source_content_type":"text/x-rst","patch_set":22,"id":"AAAAUH%2F%2FQr0%3D","line":34,"in_reply_to":"AAAAUH%2F%2FRdM%3D","updated":"2014-01-15 19:00:55.000000000","message":"will take it out","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    ./bin/keystone-manage db_sync --extension example"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"4. Optional: subscribe to ``resources`` notification events. See"},{"line_number":34,"context_line":"   :doc:`EXTENSIONS_HOWTO` for more details."}],"source_content_type":"text/x-rst","patch_set":22,"id":"AAAAUH%2F%2FRdM%3D","line":34,"in_reply_to":"AAAAUH%2F%2FWVU%3D","updated":"2014-01-15 16:19:47.000000000","message":"This addition is either a separate change or unrelated.  This patchset warrants some modifications to developing doc, but not configuration in this case.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"}],"keystone/contrib/example/controllers.py":[{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from keystone.common import controller"},{"line_number":19,"context_line":"from keystone.common import dependency"},{"line_number":20,"context_line":"from keystone.openstack.common import log as logging"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"message_received_count \u003d 0"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9lE8%3D","line":21,"updated":"2013-12-10 01:21:24.000000000","message":"pep8 - two lines","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":18,"context_line":"from keystone.common import controller"},{"line_number":19,"context_line":"from keystone.common import dependency"},{"line_number":20,"context_line":"from keystone.openstack.common import log as logging"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"message_received_count \u003d 0"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9k3M%3D","line":21,"in_reply_to":"AAAATn%2F9lE8%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"19afedb9cfe66fddfaf8fa3b8789ab3c2cde34b8","unresolved":false,"context_lines":[{"line_number":53,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":54,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":55,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"},{"line_number":56,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAATn%2F9k0M%3D","line":56,"updated":"2013-12-10 02:45:53.000000000","message":"Suggest making these example notifiers a bit more simple and create test-specific notifiers and fixtures in the test file itself.","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"ce160d1898247d75092f081fb738f7c96c985afa","unresolved":false,"context_lines":[{"line_number":53,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":54,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":55,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"},{"line_number":56,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAATn%2F9kuI%3D","line":56,"in_reply_to":"AAAATn%2F9k0M%3D","updated":"2013-12-10 03:56:32.000000000","message":"Morgan, this basically only counts the messages and logs what has received? What do you want to be simpler than this?","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"4b9021f7c63b98079bc8eafb14b377980127a798","unresolved":false,"context_lines":[{"line_number":53,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":54,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":55,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"},{"line_number":56,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAATn%2F9kNg%3D","line":56,"in_reply_to":"AAAATn%2F9kuI%3D","updated":"2013-12-10 06:49:58.000000000","message":"I was thinking that the need to use the example extension could probably have been avoided.  However, I can see if you are continuing to use the example extension how they would be required.","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"message_received_count \u003d 0"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"@dependency.requires(\u0027example_api\u0027)"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KDA%3D","line":25,"updated":"2013-12-16 08:15:00.000000000","message":"i\u0027m not really getting the point of the received message count, it\u0027s just an ID (starting and 0 and going up) that is never used/read again. If keystone restarts we start at 0 again, so it\u0027s not like the ids are unique. And i\u0027m not seeing them used again.\n\nSuggest removing them completely, if we want something to help differentiate notifications, we might be better served by a time stamp or something?","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"message_received_count \u003d 0"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"@dependency.requires(\u0027example_api\u0027)"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HMg%3D","line":25,"in_reply_to":"AAAATn%2F9KDA%3D","updated":"2013-12-16 17:36:37.000000000","message":"This is to illustrate how the callback works. Do not forget that this is a demo example that has no functionality at all it is just a boilerplate for extensions development.\nI wanted to log something to help people understand that the mechanism works.","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        \"\"\"Description of the controller logic.\"\"\""},{"line_number":34,"context_line":"        self.example_api.do_something(context)"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    @classmethod"},{"line_number":37,"context_line":"    def project_deleted_notification(self, context, message):"},{"line_number":38,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":39,"context_line":"        global message_received_count"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KAs%3D","line":36,"updated":"2013-12-16 08:15:00.000000000","message":"do we need these to be @classmethods?","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":33,"context_line":"        \"\"\"Description of the controller logic.\"\"\""},{"line_number":34,"context_line":"        self.example_api.do_something(context)"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    @classmethod"},{"line_number":37,"context_line":"    def project_deleted_notification(self, context, message):"},{"line_number":38,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":39,"context_line":"        global message_received_count"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HNM%3D","line":36,"in_reply_to":"AAAATn%2F9KAs%3D","updated":"2013-12-16 17:36:37.000000000","message":"This is safer. If you create several instances the callback notification with the registered objects will happen always only one, which is the wanted behaviour","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":39,"context_line":"        global message_received_count"},{"line_number":40,"context_line":"        message_received_count +\u003d 1"},{"line_number":41,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":42,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":43,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":44,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KCw%3D","line":41,"updated":"2013-12-16 08:15:00.000000000","message":"if we do go forward with message_id, then repalce %(message)s with %(message_id)s","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":38,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":39,"context_line":"        global message_received_count"},{"line_number":40,"context_line":"        message_received_count +\u003d 1"},{"line_number":41,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":42,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":43,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":44,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HKQ%3D","line":41,"in_reply_to":"AAAATn%2F9KCw%3D","updated":"2013-12-16 17:36:37.000000000","message":"Done","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        message_received_count +\u003d 1"},{"line_number":41,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":42,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":43,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":44,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"},{"line_number":45,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"},{"line_number":46,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KCs%3D","line":43,"updated":"2013-12-16 08:15:00.000000000","message":"same here","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":40,"context_line":"        message_received_count +\u003d 1"},{"line_number":41,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":42,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":43,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":44,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"},{"line_number":45,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"},{"line_number":46,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HKI%3D","line":43,"in_reply_to":"AAAATn%2F9KCs%3D","updated":"2013-12-16 17:36:37.000000000","message":"Done","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":49,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":50,"context_line":"        global message_received_count"},{"line_number":51,"context_line":"        message_received_count +\u003d 1"},{"line_number":52,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":53,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":54,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":55,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KCo%3D","line":52,"updated":"2013-12-16 08:15:00.000000000","message":"and here","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":49,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":50,"context_line":"        global message_received_count"},{"line_number":51,"context_line":"        message_received_count +\u003d 1"},{"line_number":52,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":53,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":54,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":55,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HKE%3D","line":52,"in_reply_to":"AAAATn%2F9KCo%3D","updated":"2013-12-16 17:36:37.000000000","message":"Done","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        message_received_count +\u003d 1"},{"line_number":52,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":53,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":54,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":55,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"},{"line_number":56,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KCk%3D","line":54,"updated":"2013-12-16 08:15:00.000000000","message":"and here","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        message_received_count +\u003d 1"},{"line_number":52,"context_line":"        msg \u003d _(\u0027Received message id: %(message)s of type %(message_type)s\u0027"},{"line_number":53,"context_line":"                \u0027 as received message number %(messages)s\u0027)"},{"line_number":54,"context_line":"        LOG.info(msg, {\u0027message\u0027: message.get(\u0027message_id\u0027),"},{"line_number":55,"context_line":"                       \u0027message_type\u0027: message.get(\u0027event_type\u0027),"},{"line_number":56,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HKA%3D","line":54,"in_reply_to":"AAAATn%2F9KCk%3D","updated":"2013-12-16 17:36:37.000000000","message":"Done","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"22d8b66c2df07663f9912c33acb7acf545a4435b","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystone.common import controller"},{"line_number":19,"context_line":"from keystone.common import dependency"},{"line_number":20,"context_line":"from keystone.openstack.common import log as logging"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAATn%2F8%2F3s%3D","line":20,"updated":"2013-12-17 21:45:47.000000000","message":"this can be deleted","commit_id":"9e2f72a163c3cb163b938011bcbbd8d4263f3d70"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"9e17604c55c325d70d06e658a8449ec2ac98fd1a","unresolved":false,"context_lines":[{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from keystone.common import controller"},{"line_number":19,"context_line":"from keystone.common import dependency"},{"line_number":20,"context_line":"from keystone.openstack.common import log as logging"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAATn%2F8%2F0I%3D","line":20,"in_reply_to":"AAAATn%2F8%2F3s%3D","updated":"2013-12-17 21:59:55.000000000","message":"Done","commit_id":"9e2f72a163c3cb163b938011bcbbd8d4263f3d70"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"22d8b66c2df07663f9912c33acb7acf545a4435b","unresolved":false,"context_lines":[{"line_number":20,"context_line":"from keystone.openstack.common import log as logging"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"@dependency.requires(\u0027example_api\u0027)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAATn%2F8%2F3o%3D","line":23,"updated":"2013-12-17 21:45:47.000000000","message":"this too","commit_id":"9e2f72a163c3cb163b938011bcbbd8d4263f3d70"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"9e17604c55c325d70d06e658a8449ec2ac98fd1a","unresolved":false,"context_lines":[{"line_number":20,"context_line":"from keystone.openstack.common import log as logging"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"@dependency.requires(\u0027example_api\u0027)"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAATn%2F8%2F0E%3D","line":23,"in_reply_to":"AAAATn%2F8%2F3o%3D","updated":"2013-12-17 21:59:55.000000000","message":"Done","commit_id":"9e2f72a163c3cb163b938011bcbbd8d4263f3d70"}],"keystone/contrib/example/core.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":25,"context_line":"CONF \u003d config.CONF"},{"line_number":26,"context_line":"LOG \u003d logging.getLogger(__name__)"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"message_received_count \u003d 0"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"@dependency.provider(\u0027example_api\u0027)"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5ws%3D","line":28,"updated":"2014-01-07 01:33:31.000000000","message":"why is this a global?","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":42,"context_line":"            \u0027keystone.contrib.example.core.ExampleDriver\u0027)"},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"    def project_deleted_notification(self, context, message):"},{"line_number":45,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":46,"context_line":"        global message_received_count"},{"line_number":47,"context_line":"        message_received_count +\u003d 1"},{"line_number":48,"context_line":"        msg \u003d _(\u0027Received message id: %(message_id)s of type %(message_type)s\u0027"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5xI%3D","line":45,"updated":"2014-01-07 01:33:31.000000000","message":"this should be an inline comment, not a docstr","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":52,"context_line":"                       \u0027messages\u0027: str(message_received_count)})"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"    def project_created_notification(self, context, message):"},{"line_number":55,"context_line":"        \"\"\"The code below is merely an example.\"\"\""},{"line_number":56,"context_line":"        global message_received_count"},{"line_number":57,"context_line":"        message_received_count +\u003d 1"},{"line_number":58,"context_line":"        msg \u003d _(\u0027Received message id: %(message_id)s of type %(message_type)s\u0027"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5ww%3D","line":55,"updated":"2014-01-07 01:33:31.000000000","message":"same","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    \"\"\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"    def __init__(self):"},{"line_number":39,"context_line":"        super(ExampleManager, self).__init__(CONF.ExampleDriver.driver)"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"class ExampleDriver(object):"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWVQ%3D","side":"PARENT","line":39,"updated":"2014-01-14 19:16:58.000000000","message":"this file should not be modified at all","commit_id":"663860bc793a9812756c6af6e61cff0ecd00882b"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"0c1383f62b69a14afd676b7aff4418535bf327a9","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    \"\"\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"    def __init__(self):"},{"line_number":39,"context_line":"        super(ExampleManager, self).__init__(CONF.ExampleDriver.driver)"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"class ExampleDriver(object):"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FQrg%3D","side":"PARENT","line":39,"in_reply_to":"AAAAUH%2F%2FRco%3D","updated":"2014-01-15 19:00:55.000000000","message":"Agree with Morgan. We need an example showing how the stuff works. This is merely an example.","commit_id":"663860bc793a9812756c6af6e61cff0ecd00882b"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":36,"context_line":"    \"\"\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"    def __init__(self):"},{"line_number":39,"context_line":"        super(ExampleManager, self).__init__(CONF.ExampleDriver.driver)"},{"line_number":40,"context_line":""},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"class ExampleDriver(object):"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FRco%3D","side":"PARENT","line":39,"in_reply_to":"AAAAUH%2F%2FWVQ%3D","updated":"2014-01-15 16:19:47.000000000","message":"This file likely should reflect an example using the new \"notifications\" subscription.  This is all example code so someone can develop their own extension (including events).  I disagree that the changes are not needed here.","commit_id":"663860bc793a9812756c6af6e61cff0ecd00882b"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    \"\"\""},{"line_number":37,"context_line":""},{"line_number":38,"context_line":"    notification_subscriptions \u003d {}"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    def __init__(self):"},{"line_number":41,"context_line":"        # Register the notification callback for when projects are deleted."}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FRcI%3D","line":38,"updated":"2014-01-15 16:19:47.000000000","message":"Suggest making this an instance property, instead of a class property.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":39,"context_line":""},{"line_number":40,"context_line":"    def __init__(self):"},{"line_number":41,"context_line":"        # Register the notification callback for when projects are deleted."},{"line_number":42,"context_line":"        # This information is used when the @dependency.provider decorator acts"},{"line_number":43,"context_line":"        # on the class."},{"line_number":44,"context_line":"        self.notification_subscriptions.setdefault(\u0027deleted\u0027, {})"},{"line_number":45,"context_line":"        self.notification_subscriptions[\u0027deleted\u0027].setdefault(\u0027project\u0027, [])"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FRbs%3D","line":42,"updated":"2014-01-15 16:19:47.000000000","message":"This should have more detailed documentation and why it is constructed like it is.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":26,"context_line":"LOG \u003d log.getLogger(__name__)"},{"line_number":27,"context_line":""},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"@dependency.provider(\u0027example_api\u0027)"},{"line_number":30,"context_line":"class ExampleManager(manager.Manager):"},{"line_number":31,"context_line":"    \"\"\"Example Manager."},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FKyE%3D","line":29,"updated":"2014-01-16 19:31:22.000000000","message":"what do you put in to make this work if you don\u0027t have any existing dependencies to declare???","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        # and it must cleanup data related to the project whenever a project"},{"line_number":43,"context_line":"        # has been deleted."},{"line_number":44,"context_line":"        #"},{"line_number":45,"context_line":"        # In this example, the project_deleted_callback will be involved"},{"line_number":46,"context_line":"        # whenever a project has been deleted. Similarily, the"},{"line_number":47,"context_line":"        # project_created_callback wil be invoked whenever a new project is"},{"line_number":48,"context_line":"        # created."}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FKy0%3D","line":45,"updated":"2014-01-16 19:31:22.000000000","message":"involved should be invoked?","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":42,"context_line":"        # and it must cleanup data related to the project whenever a project"},{"line_number":43,"context_line":"        # has been deleted."},{"line_number":44,"context_line":"        #"},{"line_number":45,"context_line":"        # In this example, the project_deleted_callback will be involved"},{"line_number":46,"context_line":"        # whenever a project has been deleted. Similarily, the"},{"line_number":47,"context_line":"        # project_created_callback wil be invoked whenever a new project is"},{"line_number":48,"context_line":"        # created."}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FKm4%3D","line":45,"in_reply_to":"AAAAUH%2F%2FKy0%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":44,"context_line":"        #"},{"line_number":45,"context_line":"        # In this example, the project_deleted_callback will be involved"},{"line_number":46,"context_line":"        # whenever a project has been deleted. Similarily, the"},{"line_number":47,"context_line":"        # project_created_callback wil be invoked whenever a new project is"},{"line_number":48,"context_line":"        # created."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"        # This information is used when the @dependency.provider decorator acts"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FKyw%3D","line":47,"updated":"2014-01-16 19:31:22.000000000","message":"wil should be will","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"2097b7791a1fa75c4b43d1dfe950a9ef87a0df2e","unresolved":false,"context_lines":[{"line_number":44,"context_line":"        #"},{"line_number":45,"context_line":"        # In this example, the project_deleted_callback will be involved"},{"line_number":46,"context_line":"        # whenever a project has been deleted. Similarily, the"},{"line_number":47,"context_line":"        # project_created_callback wil be invoked whenever a new project is"},{"line_number":48,"context_line":"        # created."},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"        # This information is used when the @dependency.provider decorator acts"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FKm0%3D","line":47,"in_reply_to":"AAAAUH%2F%2FKyw%3D","updated":"2014-01-16 19:58:35.000000000","message":"Done","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":6460,"name":"Brad Topol","email":"btopol@us.ibm.com","username":"btopol"},"change_message_id":"e5f68cbe68cce9d538b56a429b9dabbda0314bea","unresolved":false,"context_lines":[{"line_number":59,"context_line":"        super(ExampleManager, self).__init__("},{"line_number":60,"context_line":"            \u0027keystone.contrib.example.core.ExampleDriver\u0027)"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"    def project_deleted_callback(self, service, resource_type, operation,"},{"line_number":63,"context_line":"                                 payload):"},{"line_number":64,"context_line":"        # The code below is merely an example."},{"line_number":65,"context_line":"        msg \u003d _(\u0027Received the following notification: service %(service)s, \u0027"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FKyc%3D","line":62,"updated":"2014-01-16 19:31:22.000000000","message":"great examples","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"}],"keystone/notifications.py":[{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":15,"context_line":"#   under the License."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"\"\"\"Notifications module for OpenStack Identity Service resources\"\"\""},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"from keystone.openstack.common import log"},{"line_number":20,"context_line":"from keystone.openstack.common.notifier import api as notifier_api"},{"line_number":21,"context_line":""}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWVI%3D","side":"PARENT","line":18,"updated":"2014-01-14 19:16:58.000000000","message":"undo","commit_id":"663860bc793a9812756c6af6e61cff0ecd00882b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":37,"context_line":"    :param host: host of the resource (optional)"},{"line_number":38,"context_line":"    \"\"\""},{"line_number":39,"context_line":"    def __init__(self, operation, resource_type, host\u003dNone):"},{"line_number":40,"context_line":"        global RESOURCE_TYPES"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"        self.operation \u003d operation"},{"line_number":43,"context_line":"        self.resource_type \u003d resource_type"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWVA%3D","line":40,"updated":"2014-01-14 19:16:58.000000000","message":"remove - you\u0027re not using this as a global","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"0c1383f62b69a14afd676b7aff4418535bf327a9","unresolved":false,"context_lines":[{"line_number":37,"context_line":"    :param host: host of the resource (optional)"},{"line_number":38,"context_line":"    \"\"\""},{"line_number":39,"context_line":"    def __init__(self, operation, resource_type, host\u003dNone):"},{"line_number":40,"context_line":"        global RESOURCE_TYPES"},{"line_number":41,"context_line":""},{"line_number":42,"context_line":"        self.operation \u003d operation"},{"line_number":43,"context_line":"        self.resource_type \u003d resource_type"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FQrQ%3D","line":40,"in_reply_to":"AAAAUH%2F%2FWVA%3D","updated":"2014-01-15 19:00:55.000000000","message":"Not sure if I understand your comment. We are updating RESOURCE_TYPES in line 44.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b510e2fee70ec2c21a5673b2432903ac8c3f6b75","unresolved":false,"context_lines":[{"line_number":109,"context_line":"        SUBSCRIBERS.setdefault(event, {}).setdefault(resource_type, set())"},{"line_number":110,"context_line":"        SUBSCRIBERS[event][resource_type].add(callback)"},{"line_number":111,"context_line":""},{"line_number":112,"context_line":"        if LOG.logger.getEffectiveLevel() \u003c logging.INFO:"},{"line_number":113,"context_line":"            # Do this only if its going to appear in the logs."},{"line_number":114,"context_line":"            msg \u003d _(\u0027Callback: `%(callback)s` subscribed to event \u0027"},{"line_number":115,"context_line":"                    \u0027`%(event)s`.\u0027)"}],"source_content_type":"text/x-python","patch_set":24,"id":"AAAAUH%2F%2FLPw%3D","line":112,"updated":"2014-01-16 18:18:41.000000000","message":"this should be less than or equal to actually log if the level is INFO","commit_id":"04e2c987a924cdaba69f566d55ae1183efd19cf6"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b510e2fee70ec2c21a5673b2432903ac8c3f6b75","unresolved":false,"context_lines":[{"line_number":143,"context_line":"                                  \u0027event_callback %(cb_name)s %(service)s \u0027"},{"line_number":144,"context_line":"                                  \u0027%(resource_type)s %(operation)s for \u0027"},{"line_number":145,"context_line":"                                  \u0027%(payload)s\u0027),"},{"line_number":146,"context_line":"                                  subst_dict)"},{"line_number":147,"context_line":""},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"def _send_notification(operation, resource_type, resource_id, host\u003dNone):"}],"source_content_type":"text/x-python","patch_set":24,"id":"AAAAUH%2F%2FLOI%3D","line":146,"updated":"2014-01-16 18:18:41.000000000","message":"++","commit_id":"04e2c987a924cdaba69f566d55ae1183efd19cf6"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"3d23ad6e3762b61f1b6e7daf98d8b64cbd355caf","unresolved":false,"context_lines":[{"line_number":90,"context_line":""},{"line_number":91,"context_line":"def register_event_callback(event, resource_type, callbacks):"},{"line_number":92,"context_line":"    if event not in ACTIONS:"},{"line_number":93,"context_line":"        raise ValueError(_(\u0027%(event)s is not a valid notification event, must \u0027"},{"line_number":94,"context_line":"                           \u0027be one of: %(actions)s\u0027),"},{"line_number":95,"context_line":"                         {\u0027event\u0027: event, \u0027actions\u0027: \u0027, \u0027.join(ACTIONS)})"},{"line_number":96,"context_line":"    if resource_type not in RESOURCE_TYPES:"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FLCc%3D","line":93,"updated":"2014-01-16 18:59:02.000000000","message":"I remember dolphm was asking for specific exception instead of ValueError in one of his earlier comments. But I am fine with it as it if dolphm doesn\u0027t oppose to it.","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"308985a93ab7523760f65c47d465acf7d5609b37","unresolved":false,"context_lines":[{"line_number":90,"context_line":""},{"line_number":91,"context_line":"def register_event_callback(event, resource_type, callbacks):"},{"line_number":92,"context_line":"    if event not in ACTIONS:"},{"line_number":93,"context_line":"        raise ValueError(_(\u0027%(event)s is not a valid notification event, must \u0027"},{"line_number":94,"context_line":"                           \u0027be one of: %(actions)s\u0027),"},{"line_number":95,"context_line":"                         {\u0027event\u0027: event, \u0027actions\u0027: \u0027, \u0027.join(ACTIONS)})"},{"line_number":96,"context_line":"    if resource_type not in RESOURCE_TYPES:"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FK7w%3D","line":93,"in_reply_to":"AAAAUH%2F%2FLBY%3D","updated":"2014-01-16 19:10:47.000000000","message":"++ my reasoning wasn\u0027t worth the effort","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"5fb1d028ef657488e22201467cf8b40562fd9307","unresolved":false,"context_lines":[{"line_number":90,"context_line":""},{"line_number":91,"context_line":"def register_event_callback(event, resource_type, callbacks):"},{"line_number":92,"context_line":"    if event not in ACTIONS:"},{"line_number":93,"context_line":"        raise ValueError(_(\u0027%(event)s is not a valid notification event, must \u0027"},{"line_number":94,"context_line":"                           \u0027be one of: %(actions)s\u0027),"},{"line_number":95,"context_line":"                         {\u0027event\u0027: event, \u0027actions\u0027: \u0027, \u0027.join(ACTIONS)})"},{"line_number":96,"context_line":"    if resource_type not in RESOURCE_TYPES:"}],"source_content_type":"text/x-python","patch_set":28,"id":"AAAAUH%2F%2FLBY%3D","line":93,"in_reply_to":"AAAAUH%2F%2FLCc%3D","updated":"2014-01-16 19:00:52.000000000","message":"I asked him and he was fine with moving back to ValueError.","commit_id":"2b7d22746305c2661e412f2837f6d2a3a549bb0e"}],"keystone/openstack/common/notifier/extensions_notifier.py":[{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright 2011 OpenStack Foundation."},{"line_number":2,"context_line":"# All Rights Reserved."},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9lGU%3D","line":1,"updated":"2013-12-10 01:21:24.000000000","message":"2013, or maybe might as well put 2014 there :)","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":1,"context_line":"# Copyright 2011 OpenStack Foundation."},{"line_number":2,"context_line":"# All Rights Reserved."},{"line_number":3,"context_line":"#"},{"line_number":4,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9k2Q%3D","line":1,"in_reply_to":"AAAATn%2F9lGU%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":25,"context_line":"subscribers \u003d {}"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"def register(subscriptions):"},{"line_number":28,"context_line":"    \"\"\"Registers all the extensions listening to specific events\"\"\" "},{"line_number":29,"context_line":"    global subscribers"},{"line_number":30,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":31,"context_line":"        subscribers.setdefault(subscription_event, { \u0027subscribers\u0027: [] })"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9lGc%3D","line":28,"updated":"2013-12-10 01:21:24.000000000","message":"pep8","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":25,"context_line":"subscribers \u003d {}"},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"def register(subscriptions):"},{"line_number":28,"context_line":"    \"\"\"Registers all the extensions listening to specific events\"\"\" "},{"line_number":29,"context_line":"    global subscribers"},{"line_number":30,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":31,"context_line":"        subscribers.setdefault(subscription_event, { \u0027subscribers\u0027: [] })"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9k2U%3D","line":28,"in_reply_to":"AAAATn%2F9lGc%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"f0113f1d6f4711164c14020850980e383e52391a","unresolved":false,"context_lines":[{"line_number":28,"context_line":"    \"\"\"Registers all the extensions listening to specific events\"\"\" "},{"line_number":29,"context_line":"    global subscribers"},{"line_number":30,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":31,"context_line":"        subscribers.setdefault(subscription_event, { \u0027subscribers\u0027: [] })"},{"line_number":32,"context_line":"        subscribers[subscription_event][\u0027subscribers\u0027].append(subscription_callback)"},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"def notify(context, message):"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9lGI%3D","line":31,"updated":"2013-12-10 01:21:24.000000000","message":"may want to check is subscription_callback is callable, just in case\n\nif not hasattr(subscription_callback, \u0027__call__\u0027):\n    LOG.error(\u0027...\u0027)\n\nAlso, want want to add a LOG.info() to log who are registered.","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"714566b0a5d9a7e6750940071fd774dd39ccd2eb","unresolved":false,"context_lines":[{"line_number":28,"context_line":"    \"\"\"Registers all the extensions listening to specific events\"\"\" "},{"line_number":29,"context_line":"    global subscribers"},{"line_number":30,"context_line":"    for subscription_event, subscription_callback in subscriptions.iteritems():"},{"line_number":31,"context_line":"        subscribers.setdefault(subscription_event, { \u0027subscribers\u0027: [] })"},{"line_number":32,"context_line":"        subscribers[subscription_event][\u0027subscribers\u0027].append(subscription_callback)"},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"def notify(context, message):"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATn%2F9k3E%3D","line":31,"in_reply_to":"AAAATn%2F9lGI%3D","updated":"2013-12-10 02:31:18.000000000","message":"Done. Added more log to show the callback action and reaction","commit_id":"bc9be6ce80c059af2ee999ac47df41d748b6735d"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"19afedb9cfe66fddfaf8fa3b8789ab3c2cde34b8","unresolved":false,"context_lines":[{"line_number":33,"context_line":"                    \u0027%(event)s.\u0027)"},{"line_number":34,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback.__name__,"},{"line_number":35,"context_line":"                            \u0027event\u0027: subscription_event})"},{"line_number":36,"context_line":"        else: "},{"line_number":37,"context_line":"            subscribers.setdefault(subscription_event, { \u0027subscribers\u0027: [] })"},{"line_number":38,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":39,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAATn%2F9k1I%3D","line":36,"updated":"2013-12-10 02:45:53.000000000","message":"White space","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"ce160d1898247d75092f081fb738f7c96c985afa","unresolved":false,"context_lines":[{"line_number":33,"context_line":"                    \u0027%(event)s.\u0027)"},{"line_number":34,"context_line":"            LOG.error(msg, {\u0027method\u0027: subscription_callback.__name__,"},{"line_number":35,"context_line":"                            \u0027event\u0027: subscription_event})"},{"line_number":36,"context_line":"        else: "},{"line_number":37,"context_line":"            subscribers.setdefault(subscription_event, { \u0027subscribers\u0027: [] })"},{"line_number":38,"context_line":"            subscribers[subscription_event][\u0027subscribers\u0027].append("},{"line_number":39,"context_line":"                subscription_callback)"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAATn%2F9kt0%3D","line":36,"in_reply_to":"AAAATn%2F9k1I%3D","updated":"2013-12-10 03:56:32.000000000","message":"Done","commit_id":"7b00555517c8a4f8ec316ed9fca5c50b0393b2b6"}],"keystone/tests/test_notifications.py":[{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":256,"context_line":"class NotificationsForExampleExtensions(test_v3.RestfulTestCase):"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    EXTENSION_NAME \u003d \u0027example_extension\u0027"},{"line_number":259,"context_line":"    EXTENSION_TO_ADD \u003d \u0027example_extension\u0027"},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"    def setUp(self):"},{"line_number":262,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kK4%3D","line":259,"updated":"2013-12-10 07:29:50.000000000","message":"In line with my comment, it should be possible to define the callbacks here and do the register at the start of the test function.  That way you don\u0027t need to rely on an example extension as part of the unit tests.\n\n(pseudo code)\n  def _create_project_notify_callback(self, ...):\n      \u003cdo something to verify callback was called\u003e\n\n  register self._create_project_notify_callback\n  call create_project()\n  assert\u003c_create_project_notify_callback\u003e was called","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":256,"context_line":"class NotificationsForExampleExtensions(test_v3.RestfulTestCase):"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    EXTENSION_NAME \u003d \u0027example_extension\u0027"},{"line_number":259,"context_line":"    EXTENSION_TO_ADD \u003d \u0027example_extension\u0027"},{"line_number":260,"context_line":""},{"line_number":261,"context_line":"    def setUp(self):"},{"line_number":262,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fPY%3D","line":259,"in_reply_to":"AAAATn%2F9kK4%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":260,"context_line":""},{"line_number":261,"context_line":"    def setUp(self):"},{"line_number":262,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"},{"line_number":263,"context_line":"        example_extension.message_received_count \u003d 0"},{"line_number":264,"context_line":""},{"line_number":265,"context_line":"    def tearDown(self):"},{"line_number":266,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kGA%3D","line":263,"updated":"2013-12-10 07:29:50.000000000","message":"If you follow the above comment, this reset for example_extension.message_received wont be needed.","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":260,"context_line":""},{"line_number":261,"context_line":"    def setUp(self):"},{"line_number":262,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"},{"line_number":263,"context_line":"        example_extension.message_received_count \u003d 0"},{"line_number":264,"context_line":""},{"line_number":265,"context_line":"    def tearDown(self):"},{"line_number":266,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fPU%3D","line":263,"in_reply_to":"AAAATn%2F9kGA%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":263,"context_line":"        example_extension.message_received_count \u003d 0"},{"line_number":264,"context_line":""},{"line_number":265,"context_line":"    def tearDown(self):"},{"line_number":266,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"    def test_notification_received(self):"},{"line_number":269,"context_line":"        project_ref \u003d self.new_project_ref(domain_id\u003dself.domain_id)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kK0%3D","line":266,"updated":"2013-12-10 07:29:50.000000000","message":"Suggest removing this tearDown as it isn\u0027t doing anything except calling super().tearDown() (e.g. shouldn\u0027t be needed).","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":263,"context_line":"        example_extension.message_received_count \u003d 0"},{"line_number":264,"context_line":""},{"line_number":265,"context_line":"    def tearDown(self):"},{"line_number":266,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"    def test_notification_received(self):"},{"line_number":269,"context_line":"        project_ref \u003d self.new_project_ref(domain_id\u003dself.domain_id)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fPQ%3D","line":266,"in_reply_to":"AAAATn%2F9kK0%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"981561e2824f63264dd8a4342105a19902920465","unresolved":false,"context_lines":[{"line_number":270,"context_line":"        self.assignment_api.create_project(project_ref[\u0027id\u0027], project_ref)"},{"line_number":271,"context_line":"        self.assertEqual(example_extension.message_received_count, 1)"},{"line_number":272,"context_line":"        self.assignment_api.delete_project(project_ref[\u0027id\u0027])"},{"line_number":273,"context_line":"        self.assertEqual(example_extension.message_received_count, 2)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kHs%3D","line":273,"updated":"2013-12-10 07:29:50.000000000","message":"Suggest adding a test to validate that if (for example) a callback is registered for create, delete does not trigger it.","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":270,"context_line":"        self.assignment_api.create_project(project_ref[\u0027id\u0027], project_ref)"},{"line_number":271,"context_line":"        self.assertEqual(example_extension.message_received_count, 1)"},{"line_number":272,"context_line":"        self.assignment_api.delete_project(project_ref[\u0027id\u0027])"},{"line_number":273,"context_line":"        self.assertEqual(example_extension.message_received_count, 2)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fPI%3D","line":273,"in_reply_to":"AAAATn%2F9kEw%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"eff566a78ee3a8d5172703631ae0b07d00924fa1","unresolved":false,"context_lines":[{"line_number":270,"context_line":"        self.assignment_api.create_project(project_ref[\u0027id\u0027], project_ref)"},{"line_number":271,"context_line":"        self.assertEqual(example_extension.message_received_count, 1)"},{"line_number":272,"context_line":"        self.assignment_api.delete_project(project_ref[\u0027id\u0027])"},{"line_number":273,"context_line":"        self.assertEqual(example_extension.message_received_count, 2)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9fPM%3D","line":273,"in_reply_to":"AAAATn%2F9kHs%3D","updated":"2013-12-11 17:49:59.000000000","message":"Done","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"e2bb70a6918d81a7d8a224752dcb9bf913598c4d","unresolved":false,"context_lines":[{"line_number":270,"context_line":"        self.assignment_api.create_project(project_ref[\u0027id\u0027], project_ref)"},{"line_number":271,"context_line":"        self.assertEqual(example_extension.message_received_count, 1)"},{"line_number":272,"context_line":"        self.assignment_api.delete_project(project_ref[\u0027id\u0027])"},{"line_number":273,"context_line":"        self.assertEqual(example_extension.message_received_count, 2)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F9kEw%3D","line":273,"in_reply_to":"AAAATn%2F9kHs%3D","updated":"2013-12-10 07:31:39.000000000","message":"similar that update doesn\u0027t trigger create, etc","commit_id":"dbebb7813cedab701cab640e3e5009cb04d3fcf8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"21d34f52b7b9f58216d76fb2e9e869e6e69f5aef","unresolved":false,"context_lines":[{"line_number":255,"context_line":""},{"line_number":256,"context_line":"class NotificationsForExampleExtensions(test_v3.RestfulTestCase):"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    callback_performed \u003d False"},{"line_number":259,"context_line":""},{"line_number":260,"context_line":"    def _subscribe_for_test(self):"},{"line_number":261,"context_line":"        subscribed_events \u003d {"}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F9U5s%3D","line":258,"updated":"2013-12-12 16:37:00.000000000","message":"Suggest making this an instance variable that is set to False in the setUp().  Since you\u0027re using this as the mechanism to tell if the callback was performed, you\u0027ll need setUp again.","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"190039906140960855f6a01e19f147001f6a41aa","unresolved":false,"context_lines":[{"line_number":255,"context_line":""},{"line_number":256,"context_line":"class NotificationsForExampleExtensions(test_v3.RestfulTestCase):"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    callback_performed \u003d False"},{"line_number":259,"context_line":""},{"line_number":260,"context_line":"    def _subscribe_for_test(self):"},{"line_number":261,"context_line":"        subscribed_events \u003d {"}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F9OLQ%3D","line":258,"in_reply_to":"AAAATn%2F9U5s%3D","updated":"2013-12-13 20:45:29.000000000","message":"Done. I had to create a global variable because I have classmethods.","commit_id":"38c109447fc92c5f04fcb06017b5fcb88173acdd"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":25,"context_line":""},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"EXP_RESOURCE_TYPE \u003d uuid.uuid4().hex"},{"line_number":28,"context_line":"hasBeenNotified \u003d False"},{"line_number":29,"context_line":""},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"class ArbitraryException(Exception):"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KBY%3D","line":28,"updated":"2013-12-16 08:15:00.000000000","message":"no need to have this as a global, use setup to reset it","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":258,"context_line":""},{"line_number":259,"context_line":"    def setUp(self):"},{"line_number":260,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"},{"line_number":261,"context_line":"        extensions_notifier.subscribers \u003d {}"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"    def tearDown(self):"},{"line_number":264,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KBM%3D","line":261,"updated":"2013-12-16 08:15:00.000000000","message":"you can add:\n\nself.send_notification_called \u003d False\n\nin the setup, and use that in your tests, instead of hasBeenNotified\n\ncamelCase is a no-no.","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":258,"context_line":""},{"line_number":259,"context_line":"    def setUp(self):"},{"line_number":260,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"},{"line_number":261,"context_line":"        extensions_notifier.subscribers \u003d {}"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"    def tearDown(self):"},{"line_number":264,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HQk%3D","line":261,"in_reply_to":"AAAATn%2F9KBM%3D","updated":"2013-12-16 17:36:37.000000000","message":"Steve, the methods are classmethods so I cannot use self.\nThe reason is that are classmethods is that I have to ensure that even if you create many instance of that class the callback is performed only once.\nI will change the camel case","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":310,"context_line":""},{"line_number":311,"context_line":"    def test_notification_event_not_valid(self):"},{"line_number":312,"context_line":"        self._subscribe_non_valid_message_type()"},{"line_number":313,"context_line":"        subscribers \u003d extensions_notifier.subscribers"},{"line_number":314,"context_line":"        self.assertFalse(\u0027identity.project.removed\u0027 in subscribers)"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9KA4%3D","line":313,"updated":"2013-12-16 08:15:00.000000000","message":"Why is remove producing different output from create? \nI do not see an invalid message (as line 281 suggests).\n\n*edit* oh, i think I know why, is it because the keyword \u0027removed\u0027 was used instead of \u0027deleted\u0027? - if so ad a comment to line 283","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":310,"context_line":""},{"line_number":311,"context_line":"    def test_notification_event_not_valid(self):"},{"line_number":312,"context_line":"        self._subscribe_non_valid_message_type()"},{"line_number":313,"context_line":"        subscribers \u003d extensions_notifier.subscribers"},{"line_number":314,"context_line":"        self.assertFalse(\u0027identity.project.removed\u0027 in subscribers)"}],"source_content_type":"text/x-python","patch_set":14,"id":"AAAATn%2F9HP4%3D","line":313,"in_reply_to":"AAAATn%2F9KA4%3D","updated":"2013-12-16 17:36:37.000000000","message":"Yes, Removed is not a valid event message.\nI added a note","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"22d8b66c2df07663f9912c33acb7acf545a4435b","unresolved":false,"context_lines":[{"line_number":263,"context_line":"    def tearDown(self):"},{"line_number":264,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"},{"line_number":265,"context_line":"        extensions_notifier.subscribers \u003d {}"},{"line_number":266,"context_line":"        self.has_been_notified \u003d False"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"    def _subscribe_for_test(self):"},{"line_number":269,"context_line":"        subscribed_events \u003d {"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAATn%2F8%2F28%3D","line":266,"updated":"2013-12-17 21:45:47.000000000","message":"i dont think this whole teardown needed, restting the flag and dictionary are pointless as it\u0027s the last thing done here, and the first thing done again, and if it\u0027s all going, may as well remove it all","commit_id":"9e2f72a163c3cb163b938011bcbbd8d4263f3d70"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"9e17604c55c325d70d06e658a8449ec2ac98fd1a","unresolved":false,"context_lines":[{"line_number":263,"context_line":"    def tearDown(self):"},{"line_number":264,"context_line":"        super(NotificationsForExampleExtensions, self).tearDown()"},{"line_number":265,"context_line":"        extensions_notifier.subscribers \u003d {}"},{"line_number":266,"context_line":"        self.has_been_notified \u003d False"},{"line_number":267,"context_line":""},{"line_number":268,"context_line":"    def _subscribe_for_test(self):"},{"line_number":269,"context_line":"        subscribed_events \u003d {"}],"source_content_type":"text/x-python","patch_set":18,"id":"AAAATn%2F8%2F0U%3D","line":266,"in_reply_to":"AAAATn%2F8%2F28%3D","updated":"2013-12-17 21:59:55.000000000","message":"Done","commit_id":"9e2f72a163c3cb163b938011bcbbd8d4263f3d70"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":260,"context_line":"        extensions_notifier.subscribers \u003d {}"},{"line_number":261,"context_line":"        self.has_been_notified \u003d False"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"    def _subscribe_for_test(self):"},{"line_number":264,"context_line":"        subscribed_events \u003d {"},{"line_number":265,"context_line":"            \u0027identity.project.created\u0027: self._project_created_notification"},{"line_number":266,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F84w4%3D","line":263,"updated":"2013-12-19 06:24:26.000000000","message":"not sure why it needs to be a separate method. Should be just be in the test as this code is not shared.","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":260,"context_line":"        extensions_notifier.subscribers \u003d {}"},{"line_number":261,"context_line":"        self.has_been_notified \u003d False"},{"line_number":262,"context_line":""},{"line_number":263,"context_line":"    def _subscribe_for_test(self):"},{"line_number":264,"context_line":"        subscribed_events \u003d {"},{"line_number":265,"context_line":"            \u0027identity.project.created\u0027: self._project_created_notification"},{"line_number":266,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F81tU%3D","line":263,"in_reply_to":"AAAATn%2F84w4%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":266,"context_line":"        }"},{"line_number":267,"context_line":"        extensions_notifier.register(subscribed_events)"},{"line_number":268,"context_line":""},{"line_number":269,"context_line":"    def _subscribe_not_callable(self):"},{"line_number":270,"context_line":"        fake_method \u003d None"},{"line_number":271,"context_line":"        subscribed_events \u003d {"},{"line_number":272,"context_line":"            \u0027identity.project.updated\u0027: fake_method"}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F84w0%3D","line":269,"updated":"2013-12-19 06:24:26.000000000","message":"same as above","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":266,"context_line":"        }"},{"line_number":267,"context_line":"        extensions_notifier.register(subscribed_events)"},{"line_number":268,"context_line":""},{"line_number":269,"context_line":"    def _subscribe_not_callable(self):"},{"line_number":270,"context_line":"        fake_method \u003d None"},{"line_number":271,"context_line":"        subscribed_events \u003d {"},{"line_number":272,"context_line":"            \u0027identity.project.updated\u0027: fake_method"}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F81tQ%3D","line":269,"in_reply_to":"AAAATn%2F84w0%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":273,"context_line":"        }"},{"line_number":274,"context_line":"        extensions_notifier.register(subscribed_events)"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"    def _subscribe_non_valid_message_type(self):"},{"line_number":277,"context_line":"        subscribed_events \u003d {"},{"line_number":278,"context_line":"            \u0027identity.project.removed\u0027: self._project_deleted_notification"},{"line_number":279,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F84ww%3D","line":276,"updated":"2013-12-19 06:24:26.000000000","message":"same","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":273,"context_line":"        }"},{"line_number":274,"context_line":"        extensions_notifier.register(subscribed_events)"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"    def _subscribe_non_valid_message_type(self):"},{"line_number":277,"context_line":"        subscribed_events \u003d {"},{"line_number":278,"context_line":"            \u0027identity.project.removed\u0027: self._project_deleted_notification"},{"line_number":279,"context_line":"        }"}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F81tM%3D","line":276,"in_reply_to":"AAAATn%2F84ww%3D","updated":"2013-12-19 17:22:24.000000000","message":"Done","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"47a2009f052f94cb37431cf11c34b3aa07f1c27d","unresolved":false,"context_lines":[{"line_number":279,"context_line":"        }"},{"line_number":280,"context_line":"        extensions_notifier.register(subscribed_events)"},{"line_number":281,"context_line":""},{"line_number":282,"context_line":"    def _project_deleted_notification(self, context, message):"},{"line_number":283,"context_line":"        \"\"\"The code below is not intented to do anything.\"\"\""},{"line_number":284,"context_line":"        self.has_been_notified \u003d True"},{"line_number":285,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F84wg%3D","line":282,"updated":"2013-12-19 06:24:26.000000000","message":"is this method used?","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"a66c997ed57a29cbf988d37661bc40e2052c44fe","unresolved":false,"context_lines":[{"line_number":279,"context_line":"        }"},{"line_number":280,"context_line":"        extensions_notifier.register(subscribed_events)"},{"line_number":281,"context_line":""},{"line_number":282,"context_line":"    def _project_deleted_notification(self, context, message):"},{"line_number":283,"context_line":"        \"\"\"The code below is not intented to do anything.\"\"\""},{"line_number":284,"context_line":"        self.has_been_notified \u003d True"},{"line_number":285,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"AAAATn%2F81uQ%3D","line":282,"in_reply_to":"AAAATn%2F84wg%3D","updated":"2013-12-19 17:22:24.000000000","message":"It should be used if the event type was correct, so the method is necessary but is never invoked because it is used for the negative test in the false event type","commit_id":"7862adf5415ddcc748e200902da3423f1249c720"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":265,"context_line":"        self.has_been_notified \u003d True"},{"line_number":266,"context_line":""},{"line_number":267,"context_line":"    def _project_created_notification(self, context, message):"},{"line_number":268,"context_line":"        \"\"\"The code below is not intented to do anything.\"\"\""},{"line_number":269,"context_line":"        self.has_been_notified \u003d True"},{"line_number":270,"context_line":""},{"line_number":271,"context_line":"    def test_notification_received(self):"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5wQ%3D","line":268,"updated":"2014-01-07 01:33:31.000000000","message":"either rewrite these or make them inline comments... and if it\u0027s really not supposed to do anything, use a:\n\n  pass\n\ns/intented/intended/","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":284,"context_line":"        }"},{"line_number":285,"context_line":"        extensions_notifier.register(subscribed_events)"},{"line_number":286,"context_line":"        subscribers \u003d extensions_notifier.subscribers"},{"line_number":287,"context_line":"        self.assertFalse(\u0027identity.project.updated\u0027 in subscribers)"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":"    def test_notification_event_not_valid(self):"},{"line_number":290,"context_line":"        subscribed_events \u003d {"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5wc%3D","line":287,"updated":"2014-01-07 01:33:31.000000000","message":"assertIn","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"0bad7d26f2b64b29ff3d3c642b50852288643905","unresolved":false,"context_lines":[{"line_number":294,"context_line":"        subscribers \u003d extensions_notifier.subscribers"},{"line_number":295,"context_line":"        # NOTE(fabiog): the removed operation does not exist, the"},{"line_number":296,"context_line":"        # correct one is deleted. This makes the event not valid."},{"line_number":297,"context_line":"        self.assertFalse(\u0027identity.project.removed\u0027 in subscribers)"}],"source_content_type":"text/x-python","patch_set":20,"id":"AAAAUH%2F%2F5wk%3D","line":297,"updated":"2014-01-07 01:33:31.000000000","message":"assertNotIn","commit_id":"116ac655e0593f47c2980e7c688215d5d2b60ccb"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"184b5a9c74115584eca475b22bd99a98cf2bd8ea","unresolved":false,"context_lines":[{"line_number":281,"context_line":"                                     \u0027project\u0027,"},{"line_number":282,"context_line":"                                     [fake_method])"},{"line_number":283,"context_line":"        subscribers \u003d extensions_notifier.subscribers"},{"line_number":284,"context_line":"        self.assertNotIn(\u0027updated\u0027, subscribers)"},{"line_number":285,"context_line":""},{"line_number":286,"context_line":"    def test_notification_event_not_valid(self):"},{"line_number":287,"context_line":"        self.assertRaises(ValueError,"}],"source_content_type":"text/x-python","patch_set":21,"id":"AAAAUH%2F%2Fr6M%3D","line":284,"updated":"2014-01-09 16:14:58.000000000","message":"suggest a comment here, that mentioned that callbacks that are not callable/do not exist are only logged, they won\u0027t cause an exception","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"924e689784b175c945d214273b453bda683567f5","unresolved":false,"context_lines":[{"line_number":281,"context_line":"                                     \u0027project\u0027,"},{"line_number":282,"context_line":"                                     [fake_method])"},{"line_number":283,"context_line":"        subscribers \u003d extensions_notifier.subscribers"},{"line_number":284,"context_line":"        self.assertNotIn(\u0027updated\u0027, subscribers)"},{"line_number":285,"context_line":""},{"line_number":286,"context_line":"    def test_notification_event_not_valid(self):"},{"line_number":287,"context_line":"        self.assertRaises(ValueError,"}],"source_content_type":"text/x-python","patch_set":21,"id":"AAAAUH%2F%2FrrY%3D","line":284,"in_reply_to":"AAAAUH%2F%2Fr6M%3D","updated":"2014-01-09 16:55:36.000000000","message":"will do","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"184b5a9c74115584eca475b22bd99a98cf2bd8ea","unresolved":false,"context_lines":[{"line_number":294,"context_line":"        self.assertRaises(ValueError,"},{"line_number":295,"context_line":"                          extensions_notifier.register,"},{"line_number":296,"context_line":"                          \u0027removed\u0027,"},{"line_number":297,"context_line":"                          uuid.uuid4().hex,"},{"line_number":298,"context_line":"                          self._project_deleted_notification)"}],"source_content_type":"text/x-python","patch_set":21,"id":"AAAAUH%2F%2Fr50%3D","line":297,"updated":"2014-01-09 16:14:58.000000000","message":"nit: is the error coming up because \u0027removed\u0027 is not a valid type, or because the id does not exist.","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":1916,"name":"Guang Yee","email":"gyee@suse.com","username":"guang-yee"},"change_message_id":"924e689784b175c945d214273b453bda683567f5","unresolved":false,"context_lines":[{"line_number":294,"context_line":"        self.assertRaises(ValueError,"},{"line_number":295,"context_line":"                          extensions_notifier.register,"},{"line_number":296,"context_line":"                          \u0027removed\u0027,"},{"line_number":297,"context_line":"                          uuid.uuid4().hex,"},{"line_number":298,"context_line":"                          self._project_deleted_notification)"}],"source_content_type":"text/x-python","patch_set":21,"id":"AAAAUH%2F%2FrrM%3D","line":297,"in_reply_to":"AAAAUH%2F%2Fr50%3D","updated":"2014-01-09 16:55:36.000000000","message":"nice catch! the test is for invalid resource type","commit_id":"ad5ca2e12a9c3e0e2b2fcf9fb33b238a7e32e729"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"b51f547b579eacb59912ced0b33381804802cbef","unresolved":false,"context_lines":[{"line_number":253,"context_line":"        self._assertLastNotify(user_ref[\u0027id\u0027], \u0027updated\u0027, \u0027user\u0027)"},{"line_number":254,"context_line":""},{"line_number":255,"context_line":""},{"line_number":256,"context_line":"class NotificationsForExampleExtensions(test_v3.RestfulTestCase):"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    def setUp(self):"},{"line_number":259,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FWUw%3D","line":256,"updated":"2014-01-14 19:16:58.000000000","message":"for example extensions?","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":253,"context_line":"        self._assertLastNotify(user_ref[\u0027id\u0027], \u0027updated\u0027, \u0027user\u0027)"},{"line_number":254,"context_line":""},{"line_number":255,"context_line":""},{"line_number":256,"context_line":"class NotificationsForExampleExtensions(test_v3.RestfulTestCase):"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    def setUp(self):"},{"line_number":259,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FRbQ%3D","line":256,"in_reply_to":"AAAAUH%2F%2FWUw%3D","updated":"2014-01-15 16:19:47.000000000","message":"This is a bad name.  We shouldn\u0027t be testing the example extension (as the name implies), this is testing the Notification.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"d96e46358658148da841033ec8f32e050e0d13cc","unresolved":false,"context_lines":[{"line_number":254,"context_line":""},{"line_number":255,"context_line":""},{"line_number":256,"context_line":"class NotificationsForExampleExtensions(test_v3.RestfulTestCase):"},{"line_number":257,"context_line":""},{"line_number":258,"context_line":"    def setUp(self):"},{"line_number":259,"context_line":"        super(NotificationsForExampleExtensions, self).setUp()"},{"line_number":260,"context_line":"        extensions_notifier.subscribers \u003d {}"}],"source_content_type":"text/x-python","patch_set":22,"id":"AAAAUH%2F%2FRbE%3D","line":257,"updated":"2014-01-15 16:19:47.000000000","message":"We also need to test the @dependancy.provides doing the right thing for registering.","commit_id":"1c656974f8f59b0193780ac8f5365e873aa30b50"}],"keystone/tests/test_overrides.conf":[{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"bfab6aca1b6b26c589b5ff2621751c2b5bf61b5d","unresolved":false,"context_lines":[{"line_number":1,"context_line":"[DEFAULT]"},{"line_number":2,"context_line":"crypt_strength \u003d 1000"},{"line_number":3,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"[identity]"},{"line_number":6,"context_line":"driver \u003d keystone.identity.backends.kvs.Identity"}],"source_content_type":"text/plain","patch_set":14,"id":"AAAATn%2F9KB8%3D","line":3,"updated":"2013-12-16 08:15:00.000000000","message":"i think you could override this in test_notifications with:\nself.opt(notification_driver\u003d\u0027keystone.common.extensions_notifier\u0027)","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"67afb8ff3c6e484f660e8daa8b47c2b1fc16cea4","unresolved":false,"context_lines":[{"line_number":1,"context_line":"[DEFAULT]"},{"line_number":2,"context_line":"crypt_strength \u003d 1000"},{"line_number":3,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"[identity]"},{"line_number":6,"context_line":"driver \u003d keystone.identity.backends.kvs.Identity"}],"source_content_type":"text/plain","patch_set":14,"id":"AAAATn%2F9G2o%3D","line":3,"in_reply_to":"AAAATn%2F9HLg%3D","updated":"2013-12-16 18:30:49.000000000","message":"That\u0027s weird. I know it\u0027s under DEFAULT, but that is why i suggested self.opt, instead of self.opt_in_group. \n\nHave you tried using opt_in_group, and calling [DEFAULT] directly? Might it have to do with the fact that you can have multiple notification drivers specified?","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"},{"author":{"_account_id":7052,"name":"Fabio Giannetti","email":"fgiannet@cisco.com","username":"fabgia"},"change_message_id":"3dd0c38e7cf55bd6c011adccb8a9f1b8753e58e7","unresolved":false,"context_lines":[{"line_number":1,"context_line":"[DEFAULT]"},{"line_number":2,"context_line":"crypt_strength \u003d 1000"},{"line_number":3,"context_line":"notification_driver \u003d keystone.common.extensions_notifier"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"[identity]"},{"line_number":6,"context_line":"driver \u003d keystone.identity.backends.kvs.Identity"}],"source_content_type":"text/plain","patch_set":14,"id":"AAAATn%2F9HLg%3D","line":3,"in_reply_to":"AAAATn%2F9KB8%3D","updated":"2013-12-16 17:36:37.000000000","message":"I actually tried and it does not work.\nI think the reason is that this parameter is in [DEFAULT] and not in a specific header. If you have some ideas pleas help.","commit_id":"32ff0bb19fff16684315cfba0efc575cb64dbb44"}]}
