Sha256: bef243a7698e8528896486c99b75533b7fa2afb14309ad391c6ef683513db45d

Contents?: true

Size: 553 Bytes

Versions: 7

Compression:

Stored size: 553 Bytes

Contents

module WaterDrop
  # Raw poseidon connection pool for WaterDrop messages delivery
  module Pool
    extend SingleForwardable
    # Delegate directly to pool
    def_delegators :pool, :with

    class << self
      # @return [::ConnectionPool] connection pool instance that we can then use
      def pool
        @pool ||= ConnectionPool.new(
          size: ::WaterDrop.config.connection_pool_size,
          timeout: ::WaterDrop.config.connection_pool_timeout
        ) do
          WaterDrop::ProducerProxy.new
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
waterdrop-0.2.1 lib/water_drop/pool.rb
waterdrop-0.2.0 lib/water_drop/pool.rb
waterdrop-0.1.13 lib/water_drop/pool.rb
waterdrop-0.1.12 lib/water_drop/pool.rb
waterdrop-0.1.11 lib/water_drop/pool.rb
waterdrop-0.1.10 lib/water_drop/pool.rb
waterdrop-0.1.9 lib/water_drop/pool.rb