Sha256: 887f62c51ef37a781ec3c073c00e0101cb12394aa09cbf4d1af1fc85aeb0ef10

Contents?: true

Size: 768 Bytes

Versions: 3

Compression:

Stored size: 768 Bytes

Contents

module Chronicle
  module ETL
    # Abstract class representing a Loader for an ETL job
    class Loader
      extend Chronicle::ETL::Catalog

      # Construct a new instance of this loader. Options are passed in from a Runner
      # == Paramters:
      # options::
      #   Options for configuring this Loader
      def initialize(options = {})
        @options = options
      end

      # Called once before processing records
      def start; end

      # Load a single record
      def load
        raise NotImplementedError
      end

      # Called once there are no more records to process
      def finish; end
    end
  end
end

require_relative 'csv_loader'
require_relative 'rest_loader'
require_relative 'stdout_loader'
require_relative 'table_loader'

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
chronicle-etl-0.2.3 lib/chronicle/etl/loaders/loader.rb
chronicle-etl-0.2.2 lib/chronicle/etl/loaders/loader.rb
chronicle-etl-0.2.1 lib/chronicle/etl/loaders/loader.rb