Sha256: beebe24be1012ccab59b61fef4ab3db3edcf5ba3e3cafd5bfcd797bc8222e831

Contents?: true

Size: 513 Bytes

Versions: 3

Compression:

Stored size: 513 Bytes

Contents

module BoomNats
  class Railtie < Rails::Railtie
    initializer "activeservice.autoload", before: :set_autoload_paths do |app|
      # app.config.autoload_paths << ActiveService::Configuration.path
      app.config.eager_load_paths << Rails.root.join("app", "consumers").to_s
    end

    initializer "boom_nats.railtie.configure_rails_initialization" do |app|
      app.config.nats = BoomNats.setup
      BoomNats.logger = Rails.logger
    end

    server do |app|
      app.config.nats.start
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
boom_nats-0.1.2 lib/boom_nats/railtie.rb
boom_nats-0.1.1 lib/boom_nats/railtie.rb
boom_nats-0.1.0 lib/boom_nats/railtie.rb