'Check if cloud DB instance creation is complete.'

def check_create_complete(self, instance_id):

    instance = self._refresh_instance(instance_id)
    if (instance is None):
        return False
    if (instance.status in self.BAD_STATUSES):
        raise exception.ResourceInError(resource_status=instance.status, status_reason=self.TROVE_STATUS_REASON.get(instance.status, _('Unknown')))
    if (instance.status != self.ACTIVE):
        return False
    LOG.info('Database    instance    %(database)s    created    (flavor:%(flavor)s,    volume:%(volume)s,    datastore:%(datastore_type)s,    datastore_version:%(datastore_version)s)', {'database': self._dbinstance_name(), 'flavor': self.flavor, 'volume': self.volume, 'datastore_type': self.datastore_type, 'datastore_version': self.datastore_version})
    return True
