Class: Rdkafka::Admin::CreatePartitionsHandle

Inherits:
Rdkafka::AbstractHandle show all
Defined in:
lib/rdkafka/admin/create_partitions_handle.rb

Constant Summary

Constants inherited from Rdkafka::AbstractHandle

Rdkafka::AbstractHandle::REGISTRY

Instance Method Summary collapse

Methods inherited from Rdkafka::AbstractHandle

#initialize, #pending?, register, remove, #unlock, #wait

Methods included from Helpers::Time

#monotonic_now

Constructor Details

This class inherits a constructor from Rdkafka::AbstractHandle

Instance Method Details

#create_resultBoolean

Returns whether the create topic was successful.

Returns:

  • (Boolean)

    whether the create topic was successful



15
16
17
# File 'lib/rdkafka/admin/create_partitions_handle.rb', line 15

def create_result
  CreatePartitionsReport.new(self[:error_string], self[:result_name])
end

#operation_nameString

Returns the name of the operation.

Returns:

  • (String)

    the name of the operation



10
11
12
# File 'lib/rdkafka/admin/create_partitions_handle.rb', line 10

def operation_name
  "create partitions"
end

#raise_errorObject

Raises:



19
20
21
22
23
24
# File 'lib/rdkafka/admin/create_partitions_handle.rb', line 19

def raise_error
  raise RdkafkaError.new(
      self[:response],
      broker_message: CreateTopicReport.new(self[:error_string], self[:result_name]).error_string
  )
end