'Removes a host from a physical hypervisor pool.'

@wrap_exception()
def remove_aggregate_host(self, context, host, slave_info, aggregate):

    try:
        self.driver.remove_from_aggregate(context, aggregate, host, slave_info=slave_info)
    except NotImplementedError:
        LOG.debug('Hypervisor    driver    does    not    support    remove_aggregate_host')
    except (exception.AggregateError, exception.InvalidAggregateAction) as e:
        with excutils.save_and_reraise_exception():
            self.driver.undo_aggregate_operation(context, aggregate.add_host, aggregate, host, isinstance(e, exception.AggregateError))
