Sha256: c9727c129373404cb197c821fb0d0baddef6a020d37c98f87a069dd8d91b861b

Contents?: true

Size: 704 Bytes

Versions: 20

Compression:

Stored size: 704 Bytes

Contents

# frozen_string_literal: true

module Rdkafka
  class Producer
    # Handle to wait for a delivery report which is returned when
    # producing a message.
    class DeliveryHandle < Rdkafka::AbstractHandle
      layout :pending, :bool,
             :response, :int,
             :partition, :int,
             :offset, :int64,
             :topic_name, :pointer

      # @return [String] the name of the operation (e.g. "delivery")
      def operation_name
        "delivery"
      end

      # @return [DeliveryReport] a report on the delivery of the message
      def create_result
        DeliveryReport.new(self[:partition], self[:offset], self[:topic_name].read_string)
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 2 rubygems

Version Path
rdkafka-0.13.1 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.14.1 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.15.0 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.14.0 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.14.0.rc1 lib/rdkafka/producer/delivery_handle.rb
karafka-rdkafka-0.13.4 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0 lib/rdkafka/producer/delivery_handle.rb
karafka-rdkafka-0.13.3 lib/rdkafka/producer/delivery_handle.rb
karafka-rdkafka-0.13.2 lib/rdkafka/producer/delivery_handle.rb
karafka-rdkafka-0.13.1 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0.beta.8 lib/rdkafka/producer/delivery_handle.rb
karafka-rdkafka-0.13.0 lib/rdkafka/producer/delivery_handle.rb
karafka-rdkafka-0.13.0.beta2 lib/rdkafka/producer/delivery_handle.rb
karafka-rdkafka-0.13.0.beta1 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0.beta.7 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0.beta.6 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0.beta.5 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0.beta.3 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0.beta.2 lib/rdkafka/producer/delivery_handle.rb
rdkafka-0.13.0.beta.1 lib/rdkafka/producer/delivery_handle.rb