'From flavor, choose service profile and find provider for driver.'

def get_flavor_next_provider(self, context, flavor_id, filters=None, fields=None, sorts=None, limit=None, marker=None, page_reverse=False):

    objs = obj_flavor.FlavorServiceProfileBinding.get_objects(context, flavor_id=flavor_id)
    if (not objs):
        raise ext_flavors.FlavorServiceProfileBindingNotFound(sp_id='', fl_id=flavor_id)
    sp_obj = self._get_service_profile(context, objs[0].service_profile_id)
    if (not sp_obj.enabled):
        raise ext_flavors.ServiceProfileDisabled()
    LOG.debug('Found    driver    %s.', sp_obj.driver)
    service_type_manager = sdb.ServiceTypeManager.get_instance()
    providers = service_type_manager.get_service_providers(context, filters={'driver': sp_obj.driver})
    if (not providers):
        raise ext_flavors.ServiceProfileDriverNotFound(driver=sp_obj.driver)
    LOG.debug('Found    providers    %s.', providers)
    res = {'driver': sp_obj.driver, 'provider': providers[0].get('name')}
    return [db_utils.resource_fields(res, fields)]
