Sha256: d8be6a3cfbd01f1338aaec266f40e93427a018377882619a69d915d662bc334f

Contents?: true

Size: 672 Bytes

Versions: 12

Compression:

Stored size: 672 Bytes

Contents

module Datahen
  module Client
    class JobOutput < Datahen::Client::Base
      def find(job_id, collection, id)
        self.class.get("/jobs/#{job_id}/output/collections/#{collection}/records/#{id}", @options)
      end

      def all(job_id, collection = 'default', opts = {})
        limit = opts.has_key?(:retry_limit) ? opts.fetch(:retry_limit) : 0
        self.retry(limit, 10, "Error while updating the seeder.") do
          self.class.get("/jobs/#{job_id}/output/collections/#{collection}/records", @options)
        end
      end

      def collections(job_id)
        self.class.get("/jobs/#{job_id}/output/collections", @options)
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
datahen-1.4.0 lib/datahen/client/job_output.rb
datahen-1.3.2 lib/datahen/client/job_output.rb
datahen-1.3.1 lib/datahen/client/job_output.rb
datahen-1.3.0 lib/datahen/client/job_output.rb
datahen-1.2.3 lib/datahen/client/job_output.rb
datahen-1.2.2 lib/datahen/client/job_output.rb
datahen-1.2.1 lib/datahen/client/job_output.rb
datahen-1.1.2 lib/datahen/client/job_output.rb
datahen-1.1.1 lib/datahen/client/job_output.rb
datahen-1.0.3 lib/datahen/client/job_output.rb
datahen-1.0.2 lib/datahen/client/job_output.rb
datahen-1.0.1 lib/datahen/client/job_output.rb