Sha256: 089b5661d789e3189b22c4608db583a462978adb44b533b6cf65fa1b1b29e130

Contents?: true

Size: 587 Bytes

Versions: 49

Compression:

Stored size: 587 Bytes

Contents

# frozen_string_literal: true

module Kafka
  module Protocol

    class DeleteTopicsRequest
      def initialize(topics:, timeout:)
        @topics, @timeout = topics, timeout
      end

      def api_key
        DELETE_TOPICS_API
      end

      def api_version
        0
      end

      def response_class
        Protocol::DeleteTopicsResponse
      end

      def encode(encoder)
        encoder.write_array(@topics) do |topic|
          encoder.write_string(topic)
        end
        # Timeout is in ms.
        encoder.write_int32(@timeout * 1000)
      end
    end

  end
end

Version data entries

49 entries across 49 versions & 4 rubygems

Version Path
ruby-kafka-0.7.6.beta2 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.6.beta1 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.5 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.5.beta1 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.4 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.3 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.2 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.1.debugcorruption2 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.1.messagecorruptiondebug lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.1 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.1.beta2 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.1.possible.pre.fetch.pre.fix lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.1.beta1 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.0 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.6.8 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.0.beta2 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.0.beta1 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.7.0.alpha4 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.6.7 lib/kafka/protocol/delete_topics_request.rb
ruby-kafka-0.6.6 lib/kafka/protocol/delete_topics_request.rb