lib/azure/armrest/model/storage_account.rb
# Returns an array of all blobs for all containers. The +options+ hash
# may contain the same arguments that a call to StorageAccount#blobs
# would accept.
#
Returns an array of all blobs for all containers. The +options+ hash
may contain the same arguments that a call to StorageAccount#blobs
would accept.
Returns an array of all blobs for all containers . The + options + hash may contain the same arguments that a call to StorageAccount#blobs would accept .
def all_blobs(key = access_key, max_threads = 10, options = {})
        raise ArgumentError, "No access key specified" unless key
        array = []
        mutex = Mutex.new
        opts = {
          :skip_accessors_definition => options[:skip_accessors_definition]
        }
        Parallel.each(containers(key, opts), :in_threads => max_threads) do |container|
          begin
            mutex.synchronize { array.concat(blobs(container.name_from_hash, key, options)) }
          rescue Errno::ECONNREFUSED, Azure::Armrest::TimeoutException => err
            msg = "Unable to gather blob information for #{container.name_from_hash}: #{err}"
            Azure::Armrest::Configuration.log.try(:log, Logger::WARN, msg)
            next
          end
        end
        array
      end
def all_blobs ( key = access_key , max_threads = 10 , options = { } ) raise ArgumentError , "No access key specified" unless key array = [ ] mutex = Mutex . new opts = { :skip_accessors_definition => options [ :skip_accessors_definition ] } Parallel . each ( containers ( key , opts ) , :in_threads => max_threads ) do | container | begin mutex . synchronize { array . concat ( blobs ( container . name_from_hash , key , options ) ) } rescue Errno :: ECONNREFUSED , Azure :: Armrest :: TimeoutException => err msg = "Unable to gather blob information for #{container.name_from_hash}: #{err}" Azure :: Armrest :: Configuration . log . try ( :log , Logger :: WARN , msg ) next end end array end
Returns an array of all blobs for all containers.
Returns an array of all blobs for all containers .
key
<not_specific>
access_key
<not_specific>
max_threads
<not_specific>
options
<not_specific>