'Add a state change event to the database.'

def _add_event(self, action, status, reason):

    physical_res_id = (self.resource_id or self.physical_resource_name())
    ev = event.Event(self.context, self.stack, action, status, reason, physical_res_id, self._rsrc_prop_data, self.name, self.type())
    ev.store()
    self.stack.dispatch_event(ev)
