def validate
      target_proxies = @proxies.dup
      target_proxies_lock = Mutex.new
      connectable_proxies = []
      connectable_proxies_lock = Mutex.new
      threads = []

      ProxyFetcher.config.pool_size.times do
        threads << Thread.new do
          loop do
            proxy = target_proxies_lock.synchronize { target_proxies.shift }
            break unless proxy

            connectable_proxies_lock.synchronize { connectable_proxies << proxy } if proxy.connectable?
          end
        end
      end

      threads.each(&:join)

      @valid_proxies = connectable_proxies
    end
def validate
      target_proxies = @proxies.dup
      target_proxies_lock = Mutex.new
      connectable_proxies = []
      connectable_proxies_lock = Mutex.new
      threads = []

      ProxyFetcher.config.pool_size.times do
        threads << Thread.new do
          loop do
            proxy = target_proxies_lock.synchronize { target_proxies.shift }
            break unless proxy

            connectable_proxies_lock.synchronize { connectable_proxies << proxy } if proxy.connectable?
          end
        end
      end

      threads.each(&:join)

      @valid_proxies = connectable_proxies
    end
@param [Array<ProxyFetcher::Proxy>] *proxies
   Any number of <code>ProxyFetcher::Proxy</code> to validate
 Performs validation

 @return [Array<ProxyFetcher::Proxy>]
   list of valid proxies