Callbacks on internal events
Problem Statement
Keystone extensions are creating and managing data tables independently from the "core" code. These extensions may create data that have interdependencies with the core data. For instance an extension can create extra data related to a user or a project or establish relationship between two entities. Keystone is not currently providing a method for the extensions to react to changes in the core data enabling them to clean/reflect the state changes in core.
Solution
The solution is to leverage the existing notification method for Create, Update and Delete and having a mechanism for extensions to register to those events providing a callback. When an event is fired the EvenHandler will go through the list of extensions that have subscribed to that event and invoke their callbacks. The extensions are now responsible of eliminate any data inconsistency that may be present and/or perform any actions that are necessary/required.
Blueprint information
- Status:
- Complete
- Approver:
- None
- Priority:
- Medium
- Drafter:
- Fabio Giannetti
- Direction:
- Needs approval
- Assignee:
- Fabio Giannetti
- Definition:
- Review
- Series goal:
- Accepted for icehouse
- Implementation:
- Implemented
- Milestone target:
- 2014.1
- Started by
- Fabio Giannetti
- Completed by
- Dolph Mathews
Related branches
Related bugs
Sprints
Whiteboard
Gerrit topic: https:/
Addressed by: https:/
Implementation of a notification solution for Keystone extensions
Gerrit topic: https:/