← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1264957] Re: glance config option(sql_max_retries) not supported to be set -1

 

latest code have fixed this bug,detail code fowllowing:    
    try:
        engine.connect()
    except sqla_exc.OperationalError as e:
        if not _is_db_connection_error(e.args[0]):
            raise

        remaining = CONF.database.max_retries
        if remaining == -1:
            remaining = 'infinite'
        while True:
            msg = _('SQL connection failed. %s attempts left.')
            LOG.warn(msg % remaining)
            if remaining != 'infinite':
                remaining -= 1
            time.sleep(CONF.database.retry_interval)
            try:
                engine.connect()
                break
            except sqla_exc.OperationalError as e:
                if (remaining != 'infinite' and remaining == 0) or \
                        not _is_db_connection_error(e.args[0]):
                    raise


** Changed in: glance
       Status: Triaged => Invalid

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1264957

Title:
  glance config option(sql_max_retries) not supported to be set -1

Status in OpenStack Image Registry and Delivery Service (Glance):
  Invalid

Bug description:
  glance config option(sql_max_retries ) not supported to be set -1
  for example:

  # Database reconnection retry times - in event connectivity is lost
  # set to -1 implies an infinite retry count
  sql_max_retries = -1

  
  but nova and neutron  support sql_max_retries = -1, why not add codes to support it?

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1264957/+subscriptions


References