class KPM::NexusFacade::MavenCentralApiCalls
def process_response_with_retries(response)
def process_response_with_retries(response) case response.code when '200' response.body when '301', '302', '307' location = response['Location'] logger.debug { "Following redirect to #{location}" } new_path = location.gsub!(configuration[:url], '') if new_path.nil? # Redirect to another domain (e.g. CDN) get_raw_response_with_retries(location) else get_response_with_retries(nil, location, nil) end when '404' raise StandardError, ERROR_MESSAGE_404 else raise UnexpectedStatusCodeException, response.code end end