def connect_failed(ids)
      aliases = @client.aliases(ids).join(", ")
      @connect_request_stats.update("enroll failed #{aliases}")
      result = nil
      begin
        Log.info("Received indication that service initialization for this agent for brokers #{ids.inspect} has failed")
        connected = @client.connected
        ignored = connected & ids
        Log.info("Not marking brokers #{ignored.inspect} as unusable because currently connected") if ignored
        Log.info("Current broker configuration: #{@client.status.inspect}")
        @client.declare_unusable(ids - ignored)
      rescue StandardError => e
        ErrorTracker.log(self, msg = "Failed handling broker connection failure indication for #{ids.inspect}", e)
        result = Log.format(msg, e)
      end
      result
    end
def connect_failed(ids)
      aliases = @client.aliases(ids).join(", ")
      @connect_request_stats.update("enroll failed #{aliases}")
      result = nil
      begin
        Log.info("Received indication that service initialization for this agent for brokers #{ids.inspect} has failed")
        connected = @client.connected
        ignored = connected & ids
        Log.info("Not marking brokers #{ignored.inspect} as unusable because currently connected") if ignored
        Log.info("Current broker configuration: #{@client.status.inspect}")
        @client.declare_unusable(ids - ignored)
      rescue StandardError => e
        ErrorTracker.log(self, msg = "Failed handling broker connection failure indication for #{ids.inspect}", e)
        result = Log.format(msg, e)
      end
      result
    end
There were problems while setting up service for this agent on the given AMQP brokers,
 so mark these brokers as failed if not currently connected and later, during the
 periodic status check, attempt to reconnect

 === Parameters
 ids(Array):: Identity of brokers

 === Return
 (String|nil):: Error message if failed, otherwise nil