class Gitlab::QA::Component::Base

def instance_no_teardown

def instance_no_teardown
  begin
    retries ||= 0
    prepare
    start
    reconfigure
    wait_until_ready
    process_exec_commands
  rescue Support::ShellCommand::StatusError => e
    # for scenarios where a service fails during startup, attempt to retry to avoid flaky failures
    if (retries += 1) < 3
      Runtime::Logger.warn(
        "Retry instance_no_teardown due to Support::ShellCommand::StatusError -- attempt #{retries}"
      )
      teardown!
      retry
    end
    raise e
  end
  yield self if block_given?
end