'Update the state of this service in the datastore.'

def _report_state(self, service):

    try:
        service.service_ref.report_count += 1
        service.service_ref.save()
        if getattr(service, 'model_disconnected', False):
            service.model_disconnected = False
            LOG.info(_LI('Recovered    from    being    unable    to    report    status.'))
    except messaging.MessagingTimeout:
        if (not getattr(service, 'model_disconnected', False)):
            service.model_disconnected = True
            LOG.warning(_LW('Lost    connection    to    nova-conductor    for    reporting    service    status.'))
    except Exception:
        LOG.exception(_LE('Unexpected    error    while    reporting    service    status'))
        service.model_disconnected = True
