karafka-rdkafka 0.27.2-aarch64-linux-gnu → 0.28.1-aarch64-linux-gnu
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +41 -1
- data/README.md +4 -3
- data/docker-compose-ssl.yml +1 -1
- data/docker-compose.yml +1 -1
- data/ext/librdkafka.so +0 -0
- data/karafka-rdkafka.gemspec +1 -0
- data/lib/rdkafka/abstract_handle.rb +37 -4
- data/lib/rdkafka/admin/config_binding_result.rb +1 -1
- data/lib/rdkafka/admin/create_acl_handle.rb +2 -8
- data/lib/rdkafka/admin/create_acl_report.rb +2 -1
- data/lib/rdkafka/admin/create_partitions_handle.rb +1 -20
- data/lib/rdkafka/admin/create_topic_handle.rb +1 -20
- data/lib/rdkafka/admin/delete_acl_handle.rb +2 -10
- data/lib/rdkafka/admin/delete_groups_handle.rb +3 -11
- data/lib/rdkafka/admin/delete_records_handle.rb +31 -0
- data/lib/rdkafka/admin/delete_records_report.rb +25 -0
- data/lib/rdkafka/admin/delete_topic_handle.rb +1 -20
- data/lib/rdkafka/admin/describe_acl_handle.rb +2 -10
- data/lib/rdkafka/admin/describe_acl_report.rb +2 -1
- data/lib/rdkafka/admin/describe_configs_handle.rb +2 -13
- data/lib/rdkafka/admin/describe_configs_report.rb +5 -6
- data/lib/rdkafka/admin/incremental_alter_configs_handle.rb +2 -13
- data/lib/rdkafka/admin/incremental_alter_configs_report.rb +5 -6
- data/lib/rdkafka/admin/list_consumer_groups_handle.rb +31 -0
- data/lib/rdkafka/admin/list_consumer_groups_report.rb +83 -0
- data/lib/rdkafka/admin/list_offsets_handle.rb +2 -13
- data/lib/rdkafka/admin/list_offsets_report.rb +5 -2
- data/lib/rdkafka/admin.rb +233 -145
- data/lib/rdkafka/bindings.rb +63 -16
- data/lib/rdkafka/callbacks/base_handler.rb +62 -0
- data/lib/rdkafka/callbacks/create_acl_handler.rb +37 -0
- data/lib/rdkafka/callbacks/create_partitions_handler.rb +37 -0
- data/lib/rdkafka/callbacks/create_topic_handler.rb +37 -0
- data/lib/rdkafka/callbacks/delete_acl_handler.rb +42 -0
- data/lib/rdkafka/callbacks/delete_groups_handler.rb +37 -0
- data/lib/rdkafka/callbacks/delete_records_handler.rb +38 -0
- data/lib/rdkafka/callbacks/delete_topic_handler.rb +37 -0
- data/lib/rdkafka/callbacks/describe_acl_handler.rb +35 -0
- data/lib/rdkafka/callbacks/describe_configs_handler.rb +42 -0
- data/lib/rdkafka/callbacks/incremental_alter_configs_handler.rb +42 -0
- data/lib/rdkafka/callbacks/list_consumer_groups_handler.rb +39 -0
- data/lib/rdkafka/callbacks/list_offsets_handler.rb +42 -0
- data/lib/rdkafka/callbacks.rb +60 -246
- data/lib/rdkafka/config.rb +69 -50
- data/lib/rdkafka/consumer/headers.rb +19 -5
- data/lib/rdkafka/consumer/topic_partition_list.rb +57 -42
- data/lib/rdkafka/consumer.rb +190 -48
- data/lib/rdkafka/defaults.rb +32 -3
- data/lib/rdkafka/error.rb +14 -5
- data/lib/rdkafka/helpers/list_offsets.rb +127 -0
- data/lib/rdkafka/helpers/metadata.rb +29 -0
- data/lib/rdkafka/helpers/oauth.rb +10 -5
- data/lib/rdkafka/metadata.rb +84 -19
- data/lib/rdkafka/native_kafka.rb +20 -7
- data/lib/rdkafka/producer/delivery_handle.rb +4 -5
- data/lib/rdkafka/producer/partitions_count_cache.rb +24 -38
- data/lib/rdkafka/producer/testing.rb +2 -1
- data/lib/rdkafka/producer.rb +100 -71
- data/lib/rdkafka/version.rb +3 -3
- data/lib/rdkafka.rb +19 -0
- data/package-lock.json +6 -6
- data/renovate.json +11 -1
- metadata +21 -5
- data/Gemfile +0 -13
- data/Gemfile.lint +0 -14
- data/Gemfile.lint.lock +0 -123
data/lib/rdkafka/producer.rb
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
module Rdkafka
|
|
4
|
-
# A producer for Kafka messages. To create a producer set up a {Config} and call
|
|
4
|
+
# A producer for Kafka messages. To create a producer set up a {Config} and call
|
|
5
|
+
# {Config#producer producer} on that.
|
|
5
6
|
class Producer
|
|
6
7
|
include Helpers::Time
|
|
7
8
|
include Helpers::OAuth
|
|
9
|
+
include Helpers::Metadata
|
|
8
10
|
|
|
9
|
-
#
|
|
11
|
+
# @!visibility private
|
|
10
12
|
@@partitions_count_cache = PartitionsCountCache.new
|
|
11
13
|
|
|
12
14
|
# Global (process wide) partitions cache. We use it to store number of topics partitions,
|
|
@@ -94,6 +96,12 @@ module Rdkafka
|
|
|
94
96
|
)
|
|
95
97
|
|
|
96
98
|
unless result == :config_ok
|
|
99
|
+
# rd_kafka_topic_new has not been called yet, so librdkafka has not taken
|
|
100
|
+
# ownership of the config. Destroy it ourselves before raising, otherwise the
|
|
101
|
+
# partially built rd_kafka_topic_conf_t leaks. (On the rd_kafka_topic_new path
|
|
102
|
+
# librdkafka frees the conf on both success and failure, so we never destroy it
|
|
103
|
+
# there.)
|
|
104
|
+
Rdkafka::Bindings.rd_kafka_topic_conf_destroy(topic_config)
|
|
97
105
|
raise Config::ConfigError.new(error_buffer.read_string)
|
|
98
106
|
end
|
|
99
107
|
end
|
|
@@ -168,8 +176,7 @@ module Rdkafka
|
|
|
168
176
|
end
|
|
169
177
|
end
|
|
170
178
|
|
|
171
|
-
# Begin a new transaction
|
|
172
|
-
# Requires {#init_transactions} to have been called first
|
|
179
|
+
# Begin a new transaction. Requires {#init_transactions} to have been called first
|
|
173
180
|
#
|
|
174
181
|
# @return [true] Returns true on success
|
|
175
182
|
# @raise [RdkafkaError] if beginning the transaction fails
|
|
@@ -324,10 +331,9 @@ module Rdkafka
|
|
|
324
331
|
# @return [Integer] the number of messages in the queue
|
|
325
332
|
# @raise [Rdkafka::ClosedProducerError] if called on a closed producer
|
|
326
333
|
#
|
|
327
|
-
# @note This method is thread-safe as it uses the @native_kafka.with_inner synchronization
|
|
328
|
-
#
|
|
329
334
|
# @example
|
|
330
335
|
# producer.queue_size #=> 42
|
|
336
|
+
# @note This method is thread-safe as it uses the @native_kafka.with_inner synchronization
|
|
331
337
|
def queue_size
|
|
332
338
|
closed_producer_check(__method__)
|
|
333
339
|
|
|
@@ -353,10 +359,6 @@ module Rdkafka
|
|
|
353
359
|
# @return [nil]
|
|
354
360
|
# @raise [Rdkafka::ClosedProducerError] if called on a closed producer
|
|
355
361
|
#
|
|
356
|
-
# @note This method holds the inner lock until the queue is empty or `:stop` is returned.
|
|
357
|
-
# Other producer operations (produce, close, etc.) will wait until this method returns.
|
|
358
|
-
# @note This method is thread-safe as it uses @native_kafka.with_inner synchronization
|
|
359
|
-
#
|
|
360
362
|
# @example Drain all pending callbacks
|
|
361
363
|
# producer.events_poll_nb_each { |_count| }
|
|
362
364
|
#
|
|
@@ -365,6 +367,9 @@ module Rdkafka
|
|
|
365
367
|
# producer.events_poll_nb_each do |_count|
|
|
366
368
|
# :stop if monotonic_now >= deadline
|
|
367
369
|
# end
|
|
370
|
+
# @note This method holds the inner lock until the queue is empty or `:stop` is returned.
|
|
371
|
+
# Other producer operations (produce, close, etc.) will wait until this method returns.
|
|
372
|
+
# @note This method is thread-safe as it uses @native_kafka.with_inner synchronization
|
|
368
373
|
def events_poll_nb_each
|
|
369
374
|
closed_producer_check(__method__)
|
|
370
375
|
|
|
@@ -380,7 +385,8 @@ module Rdkafka
|
|
|
380
385
|
# Partition count for a given topic.
|
|
381
386
|
#
|
|
382
387
|
# @param topic [String] The topic name.
|
|
383
|
-
# @return [Integer] partition count for a given topic or `RD_KAFKA_PARTITION_UA (-1)` if it
|
|
388
|
+
# @return [Integer] partition count for a given topic or `RD_KAFKA_PARTITION_UA (-1)` if it
|
|
389
|
+
# could not be obtained.
|
|
384
390
|
#
|
|
385
391
|
# @note If 'allow.auto.create.topics' is set to true in the broker, the topic will be
|
|
386
392
|
# auto-created after returning nil.
|
|
@@ -388,9 +394,11 @@ module Rdkafka
|
|
|
388
394
|
# @note We cache the partition count for a given topic for given time. If statistics are
|
|
389
395
|
# enabled for any producer or consumer, it will take precedence over per instance fetching.
|
|
390
396
|
#
|
|
391
|
-
# This prevents us in case someone uses `partition_key
|
|
392
|
-
# each message.
|
|
393
|
-
#
|
|
397
|
+
# This prevents us, in case someone uses `partition_key`, from querying for the count with
|
|
398
|
+
# each message. A missing topic (`unknown_topic_or_part`) is cached as
|
|
399
|
+
# `RD_KAFKA_PARTITION_UA` too, so producing to a not-yet-created topic does not run a
|
|
400
|
+
# blocking metadata query on every message; the cache TTL still bounds how long that result
|
|
401
|
+
# is reused before we look again.
|
|
394
402
|
def partition_count(topic)
|
|
395
403
|
closed_producer_check(__method__)
|
|
396
404
|
|
|
@@ -402,33 +410,43 @@ module Rdkafka
|
|
|
402
410
|
end
|
|
403
411
|
|
|
404
412
|
topic_metadata ? topic_metadata[:partition_count] : Rdkafka::Bindings::RD_KAFKA_PARTITION_UA
|
|
413
|
+
rescue Rdkafka::RdkafkaError => e
|
|
414
|
+
# A missing topic is an expected, cacheable outcome (the topic may be auto-created on
|
|
415
|
+
# produce, or simply not exist yet). Returning RD_KAFKA_PARTITION_UA from inside the block
|
|
416
|
+
# caches it, so we don't re-run a blocking metadata query on every produce(partition_key:)
|
|
417
|
+
# to that topic. Anything else is a real error and is re-raised.
|
|
418
|
+
raise(e) unless e.code == :unknown_topic_or_part
|
|
419
|
+
|
|
420
|
+
Rdkafka::Bindings::RD_KAFKA_PARTITION_UA
|
|
405
421
|
end
|
|
406
|
-
rescue Rdkafka::RdkafkaError => e
|
|
407
|
-
# If the topic does not exist, it will be created or if not allowed another error will be
|
|
408
|
-
# raised. We here return RD_KAFKA_PARTITION_UA so this can happen without early error
|
|
409
|
-
# happening on metadata discovery.
|
|
410
|
-
return Rdkafka::Bindings::RD_KAFKA_PARTITION_UA if e.code == :unknown_topic_or_part
|
|
411
|
-
|
|
412
|
-
raise(e)
|
|
413
422
|
end
|
|
414
423
|
|
|
415
|
-
# Produces a message to a Kafka topic. The message is added to rdkafka's queue, call
|
|
424
|
+
# Produces a message to a Kafka topic. The message is added to rdkafka's queue, call
|
|
425
|
+
# {DeliveryHandle#wait wait} on the returned delivery handle to make sure it is delivered.
|
|
416
426
|
#
|
|
417
|
-
# When no partition is specified the underlying Kafka library picks a partition based on the
|
|
418
|
-
#
|
|
427
|
+
# When no partition is specified the underlying Kafka library picks a partition based on the
|
|
428
|
+
# key. If no key is specified, a random partition will be used. When a timestamp is provided
|
|
429
|
+
# this is used instead of the auto-generated timestamp.
|
|
419
430
|
#
|
|
420
431
|
# @param topic [String] The topic to produce to
|
|
421
432
|
# @param payload [String, nil]
|
|
422
433
|
# @param key [String, nil]
|
|
423
434
|
# @param partition [Integer, nil] Optional partition to produce to
|
|
424
|
-
# @param partition_key [String, nil] Optional partition key based on which partition
|
|
425
|
-
#
|
|
426
|
-
# @param
|
|
427
|
-
#
|
|
428
|
-
# @param
|
|
435
|
+
# @param partition_key [String, nil] Optional partition key based on which partition
|
|
436
|
+
# assignment can happen
|
|
437
|
+
# @param timestamp [Time, Integer, nil] Optional timestamp of this message. Integer
|
|
438
|
+
# timestamp is in milliseconds since Jan 1 1970.
|
|
439
|
+
# @param headers [Hash{String => String, Array<String>}] Optional message headers. Values
|
|
440
|
+
# can be either a single string or an array of strings to support duplicate headers per
|
|
441
|
+
# KIP-82
|
|
442
|
+
# @param label [Object, nil] a label that can be assigned when producing a message that
|
|
443
|
+
# will be part of the delivery handle and the delivery report
|
|
444
|
+
# @param topic_config [Hash] topic config for given message dispatch. Allows to send
|
|
445
|
+
# messages to topics with different configuration
|
|
429
446
|
# @param partitioner [String] name of the partitioner to use
|
|
430
447
|
#
|
|
431
|
-
# @return [DeliveryHandle] Delivery handle that can be used to wait for the result of
|
|
448
|
+
# @return [DeliveryHandle] Delivery handle that can be used to wait for the result of
|
|
449
|
+
# producing this message
|
|
432
450
|
#
|
|
433
451
|
# @raise [RdkafkaError] When adding the message to rdkafka's queue failed
|
|
434
452
|
def produce(
|
|
@@ -511,24 +529,39 @@ module Rdkafka
|
|
|
511
529
|
delivery_handle[:offset] = Rdkafka::Bindings::RD_KAFKA_PARTITION_UA
|
|
512
530
|
DeliveryHandle.register(delivery_handle)
|
|
513
531
|
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
+
# Everything between registration and the successful return must remove the handle from the
|
|
533
|
+
# process-global registry if it raises. Otherwise a failure after registration (a concurrent
|
|
534
|
+
# close making `with_inner` raise `ClosedInnerError`, or a header value whose `#to_s` raises)
|
|
535
|
+
# would orphan the handle in the registry forever, since nothing else will ever resolve it.
|
|
536
|
+
begin
|
|
537
|
+
args = [
|
|
538
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_RKT, :pointer, topic_ref,
|
|
539
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_MSGFLAGS, :int, Rdkafka::Bindings::RD_KAFKA_MSG_F_COPY,
|
|
540
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_VALUE, :buffer_in, payload, :size_t, payload_size,
|
|
541
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_KEY, :buffer_in, key, :size_t, key_size,
|
|
542
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_PARTITION, :int32, partition,
|
|
543
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_TIMESTAMP, :int64, raw_timestamp,
|
|
544
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_OPAQUE, :pointer, delivery_handle
|
|
545
|
+
]
|
|
546
|
+
|
|
547
|
+
if headers && !headers.empty?
|
|
548
|
+
headers.each do |key0, value0|
|
|
549
|
+
key = key0.to_s
|
|
550
|
+
case value0
|
|
551
|
+
when Array
|
|
552
|
+
# Handle array of values per KIP-82
|
|
553
|
+
value0.each do |v|
|
|
554
|
+
value = v.to_s
|
|
555
|
+
args.push(
|
|
556
|
+
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_HEADER,
|
|
557
|
+
:string, key,
|
|
558
|
+
:pointer, value,
|
|
559
|
+
:size_t, value.bytesize
|
|
560
|
+
)
|
|
561
|
+
end
|
|
562
|
+
else
|
|
563
|
+
# Handle single value
|
|
564
|
+
value = value0.to_s
|
|
532
565
|
args.push(
|
|
533
566
|
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_HEADER,
|
|
534
567
|
:string, key,
|
|
@@ -536,36 +569,31 @@ module Rdkafka
|
|
|
536
569
|
:size_t, value.bytesize
|
|
537
570
|
)
|
|
538
571
|
end
|
|
539
|
-
else
|
|
540
|
-
# Handle single value
|
|
541
|
-
value = value0.to_s
|
|
542
|
-
args.push(
|
|
543
|
-
:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_HEADER,
|
|
544
|
-
:string, key,
|
|
545
|
-
:pointer, value,
|
|
546
|
-
:size_t, value.bytesize
|
|
547
|
-
)
|
|
548
572
|
end
|
|
549
573
|
end
|
|
550
|
-
end
|
|
551
574
|
|
|
552
|
-
|
|
575
|
+
args.push(:int, Rdkafka::Bindings::RD_KAFKA_VTYPE_END)
|
|
553
576
|
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
577
|
+
# Produce the message
|
|
578
|
+
response = @native_kafka.with_inner do |inner|
|
|
579
|
+
Rdkafka::Bindings.rd_kafka_producev(
|
|
580
|
+
inner,
|
|
581
|
+
*args
|
|
582
|
+
)
|
|
583
|
+
end
|
|
561
584
|
|
|
562
|
-
|
|
563
|
-
|
|
585
|
+
# Raise error if the produce call was not successful. On a successful enqueue the handle
|
|
586
|
+
# stays registered on purpose: the delivery callback resolves and removes it once librdkafka
|
|
587
|
+
# reports the delivery.
|
|
588
|
+
if response != Rdkafka::Bindings::RD_KAFKA_RESP_ERR_NO_ERROR
|
|
589
|
+
@native_kafka.with_inner do |inner|
|
|
590
|
+
Rdkafka::RdkafkaError.validate!(response, client_ptr: inner)
|
|
591
|
+
end
|
|
592
|
+
end
|
|
593
|
+
rescue Exception
|
|
564
594
|
DeliveryHandle.remove(delivery_handle.to_ptr.address)
|
|
565
595
|
|
|
566
|
-
|
|
567
|
-
Rdkafka::RdkafkaError.validate!(response, client_ptr: inner)
|
|
568
|
-
end
|
|
596
|
+
raise
|
|
569
597
|
end
|
|
570
598
|
|
|
571
599
|
delivery_handle
|
|
@@ -607,5 +635,6 @@ module Rdkafka
|
|
|
607
635
|
def closed_producer_check(method)
|
|
608
636
|
raise Rdkafka::ClosedProducerError.new(method) if closed?
|
|
609
637
|
end
|
|
638
|
+
alias_method :closed_check, :closed_producer_check
|
|
610
639
|
end
|
|
611
640
|
end
|
data/lib/rdkafka/version.rb
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
module Rdkafka
|
|
4
4
|
# Current rdkafka-ruby gem version
|
|
5
|
-
VERSION = "0.
|
|
5
|
+
VERSION = "0.28.1"
|
|
6
6
|
# Target librdkafka version to be used
|
|
7
|
-
LIBRDKAFKA_VERSION = "2.14.
|
|
7
|
+
LIBRDKAFKA_VERSION = "2.14.2"
|
|
8
8
|
# SHA256 hash of the librdkafka source tarball for verification
|
|
9
|
-
LIBRDKAFKA_SOURCE_SHA256 = "
|
|
9
|
+
LIBRDKAFKA_SOURCE_SHA256 = "d7eec9c31c817fa44402f679c252dfbf97e4c338a849a25c3579a31fd127beb8"
|
|
10
10
|
end
|
data/lib/rdkafka.rb
CHANGED
|
@@ -9,12 +9,16 @@ require "rdkafka/version"
|
|
|
9
9
|
require "rdkafka/defaults"
|
|
10
10
|
require "rdkafka/helpers/time"
|
|
11
11
|
require "rdkafka/helpers/oauth"
|
|
12
|
+
require "rdkafka/helpers/metadata"
|
|
13
|
+
require "rdkafka/helpers/list_offsets"
|
|
12
14
|
require "rdkafka/abstract_handle"
|
|
13
15
|
require "rdkafka/admin"
|
|
14
16
|
require "rdkafka/admin/create_topic_handle"
|
|
15
17
|
require "rdkafka/admin/create_topic_report"
|
|
16
18
|
require "rdkafka/admin/delete_groups_handle"
|
|
17
19
|
require "rdkafka/admin/delete_groups_report"
|
|
20
|
+
require "rdkafka/admin/delete_records_handle"
|
|
21
|
+
require "rdkafka/admin/delete_records_report"
|
|
18
22
|
require "rdkafka/admin/delete_topic_handle"
|
|
19
23
|
require "rdkafka/admin/delete_topic_report"
|
|
20
24
|
require "rdkafka/admin/create_partitions_handle"
|
|
@@ -31,11 +35,26 @@ require "rdkafka/admin/incremental_alter_configs_handle"
|
|
|
31
35
|
require "rdkafka/admin/incremental_alter_configs_report"
|
|
32
36
|
require "rdkafka/admin/list_offsets_handle"
|
|
33
37
|
require "rdkafka/admin/list_offsets_report"
|
|
38
|
+
require "rdkafka/admin/list_consumer_groups_handle"
|
|
39
|
+
require "rdkafka/admin/list_consumer_groups_report"
|
|
34
40
|
require "rdkafka/admin/acl_binding_result"
|
|
35
41
|
require "rdkafka/admin/config_binding_result"
|
|
36
42
|
require "rdkafka/admin/config_resource_binding_result"
|
|
37
43
|
require "rdkafka/bindings"
|
|
38
44
|
require "rdkafka/callbacks"
|
|
45
|
+
require "rdkafka/callbacks/base_handler"
|
|
46
|
+
require "rdkafka/callbacks/create_topic_handler"
|
|
47
|
+
require "rdkafka/callbacks/delete_topic_handler"
|
|
48
|
+
require "rdkafka/callbacks/create_partitions_handler"
|
|
49
|
+
require "rdkafka/callbacks/delete_groups_handler"
|
|
50
|
+
require "rdkafka/callbacks/delete_records_handler"
|
|
51
|
+
require "rdkafka/callbacks/create_acl_handler"
|
|
52
|
+
require "rdkafka/callbacks/delete_acl_handler"
|
|
53
|
+
require "rdkafka/callbacks/describe_acl_handler"
|
|
54
|
+
require "rdkafka/callbacks/describe_configs_handler"
|
|
55
|
+
require "rdkafka/callbacks/incremental_alter_configs_handler"
|
|
56
|
+
require "rdkafka/callbacks/list_offsets_handler"
|
|
57
|
+
require "rdkafka/callbacks/list_consumer_groups_handler"
|
|
39
58
|
require "rdkafka/config"
|
|
40
59
|
require "rdkafka/consumer"
|
|
41
60
|
require "rdkafka/consumer/headers"
|
data/package-lock.json
CHANGED
|
@@ -286,9 +286,9 @@
|
|
|
286
286
|
}
|
|
287
287
|
},
|
|
288
288
|
"node_modules/smol-toml": {
|
|
289
|
-
"version": "1.
|
|
290
|
-
"resolved": "https://registry.npmjs.org/smol-toml/-/smol-toml-1.
|
|
291
|
-
"integrity": "sha512-
|
|
289
|
+
"version": "1.7.0",
|
|
290
|
+
"resolved": "https://registry.npmjs.org/smol-toml/-/smol-toml-1.7.0.tgz",
|
|
291
|
+
"integrity": "sha512-aqVvWoyO21L23mb+drl4RmMXbf6N7FdHjAhTRA9ZBL7apWBgfWC16KjrASI+1p9GAroljyMHj6fK67i0UiTNvQ==",
|
|
292
292
|
"dev": true,
|
|
293
293
|
"license": "BSD-3-Clause",
|
|
294
294
|
"engines": {
|
|
@@ -312,9 +312,9 @@
|
|
|
312
312
|
}
|
|
313
313
|
},
|
|
314
314
|
"node_modules/yaml": {
|
|
315
|
-
"version": "2.
|
|
316
|
-
"resolved": "https://registry.npmjs.org/yaml/-/yaml-2.
|
|
317
|
-
"integrity": "sha512-
|
|
315
|
+
"version": "2.9.0",
|
|
316
|
+
"resolved": "https://registry.npmjs.org/yaml/-/yaml-2.9.0.tgz",
|
|
317
|
+
"integrity": "sha512-2AvhNX3mb8zd6Zy7INTtSpl1F15HW6Wnqj0srWlkKLcpYl/gMIMJiyuGq2KeI2YFxUPjdlB+3Lc10seMLtL4cA==",
|
|
318
318
|
"dev": true,
|
|
319
319
|
"license": "ISC",
|
|
320
320
|
"bin": {
|
data/renovate.json
CHANGED
|
@@ -87,12 +87,22 @@
|
|
|
87
87
|
],
|
|
88
88
|
"groupName": "ruby setup",
|
|
89
89
|
"internalChecksFilter": "strict"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"description": "Let setup-ruby pass age gate before ruby so it is ready when the group PR is created",
|
|
93
|
+
"matchPackageNames": [
|
|
94
|
+
"ruby/setup-ruby"
|
|
95
|
+
],
|
|
96
|
+
"minimumReleaseAge": "5 days"
|
|
90
97
|
}
|
|
91
98
|
],
|
|
92
99
|
"labels": [
|
|
93
100
|
"dependencies"
|
|
94
101
|
],
|
|
95
102
|
"lockFileMaintenance": {
|
|
96
|
-
"enabled": true
|
|
103
|
+
"enabled": true,
|
|
104
|
+
"schedule": [
|
|
105
|
+
"before 4am on the first day of the month"
|
|
106
|
+
]
|
|
97
107
|
}
|
|
98
108
|
}
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: karafka-rdkafka
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.28.1
|
|
5
5
|
platform: aarch64-linux-gnu
|
|
6
6
|
authors:
|
|
7
7
|
- Thijs Cadier
|
|
@@ -88,9 +88,6 @@ extensions: []
|
|
|
88
88
|
extra_rdoc_files: []
|
|
89
89
|
files:
|
|
90
90
|
- CHANGELOG.md
|
|
91
|
-
- Gemfile
|
|
92
|
-
- Gemfile.lint
|
|
93
|
-
- Gemfile.lint.lock
|
|
94
91
|
- MIT-LICENSE
|
|
95
92
|
- README.md
|
|
96
93
|
- Rakefile
|
|
@@ -115,6 +112,8 @@ files:
|
|
|
115
112
|
- lib/rdkafka/admin/delete_acl_report.rb
|
|
116
113
|
- lib/rdkafka/admin/delete_groups_handle.rb
|
|
117
114
|
- lib/rdkafka/admin/delete_groups_report.rb
|
|
115
|
+
- lib/rdkafka/admin/delete_records_handle.rb
|
|
116
|
+
- lib/rdkafka/admin/delete_records_report.rb
|
|
118
117
|
- lib/rdkafka/admin/delete_topic_handle.rb
|
|
119
118
|
- lib/rdkafka/admin/delete_topic_report.rb
|
|
120
119
|
- lib/rdkafka/admin/describe_acl_handle.rb
|
|
@@ -123,10 +122,25 @@ files:
|
|
|
123
122
|
- lib/rdkafka/admin/describe_configs_report.rb
|
|
124
123
|
- lib/rdkafka/admin/incremental_alter_configs_handle.rb
|
|
125
124
|
- lib/rdkafka/admin/incremental_alter_configs_report.rb
|
|
125
|
+
- lib/rdkafka/admin/list_consumer_groups_handle.rb
|
|
126
|
+
- lib/rdkafka/admin/list_consumer_groups_report.rb
|
|
126
127
|
- lib/rdkafka/admin/list_offsets_handle.rb
|
|
127
128
|
- lib/rdkafka/admin/list_offsets_report.rb
|
|
128
129
|
- lib/rdkafka/bindings.rb
|
|
129
130
|
- lib/rdkafka/callbacks.rb
|
|
131
|
+
- lib/rdkafka/callbacks/base_handler.rb
|
|
132
|
+
- lib/rdkafka/callbacks/create_acl_handler.rb
|
|
133
|
+
- lib/rdkafka/callbacks/create_partitions_handler.rb
|
|
134
|
+
- lib/rdkafka/callbacks/create_topic_handler.rb
|
|
135
|
+
- lib/rdkafka/callbacks/delete_acl_handler.rb
|
|
136
|
+
- lib/rdkafka/callbacks/delete_groups_handler.rb
|
|
137
|
+
- lib/rdkafka/callbacks/delete_records_handler.rb
|
|
138
|
+
- lib/rdkafka/callbacks/delete_topic_handler.rb
|
|
139
|
+
- lib/rdkafka/callbacks/describe_acl_handler.rb
|
|
140
|
+
- lib/rdkafka/callbacks/describe_configs_handler.rb
|
|
141
|
+
- lib/rdkafka/callbacks/incremental_alter_configs_handler.rb
|
|
142
|
+
- lib/rdkafka/callbacks/list_consumer_groups_handler.rb
|
|
143
|
+
- lib/rdkafka/callbacks/list_offsets_handler.rb
|
|
130
144
|
- lib/rdkafka/config.rb
|
|
131
145
|
- lib/rdkafka/consumer.rb
|
|
132
146
|
- lib/rdkafka/consumer/headers.rb
|
|
@@ -135,6 +149,8 @@ files:
|
|
|
135
149
|
- lib/rdkafka/consumer/topic_partition_list.rb
|
|
136
150
|
- lib/rdkafka/defaults.rb
|
|
137
151
|
- lib/rdkafka/error.rb
|
|
152
|
+
- lib/rdkafka/helpers/list_offsets.rb
|
|
153
|
+
- lib/rdkafka/helpers/metadata.rb
|
|
138
154
|
- lib/rdkafka/helpers/oauth.rb
|
|
139
155
|
- lib/rdkafka/helpers/time.rb
|
|
140
156
|
- lib/rdkafka/metadata.rb
|
|
@@ -172,7 +188,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
172
188
|
- !ruby/object:Gem::Version
|
|
173
189
|
version: '0'
|
|
174
190
|
requirements: []
|
|
175
|
-
rubygems_version: 4.0.
|
|
191
|
+
rubygems_version: 4.0.16
|
|
176
192
|
specification_version: 4
|
|
177
193
|
summary: The rdkafka gem is a modern Kafka client library for Ruby based on librdkafka.
|
|
178
194
|
It wraps the production-ready C client using the ffi gem and targets Kafka 1.0+
|
data/Gemfile
DELETED
data/Gemfile.lint
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
source "https://rubygems.org"
|
|
4
|
-
|
|
5
|
-
# Documentation linting
|
|
6
|
-
gem "yard-lint"
|
|
7
|
-
|
|
8
|
-
# Code style (StandardRB via RuboCop)
|
|
9
|
-
gem "standard"
|
|
10
|
-
gem "standard-performance"
|
|
11
|
-
gem "rubocop-performance"
|
|
12
|
-
gem "rubocop-rspec"
|
|
13
|
-
gem "standard-rspec"
|
|
14
|
-
gem "rubocop-thread_safety"
|
data/Gemfile.lint.lock
DELETED
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
GEM
|
|
2
|
-
remote: https://rubygems.org/
|
|
3
|
-
specs:
|
|
4
|
-
ast (2.4.3)
|
|
5
|
-
json (2.18.0)
|
|
6
|
-
language_server-protocol (3.17.0.5)
|
|
7
|
-
lint_roller (1.1.0)
|
|
8
|
-
parallel (1.27.0)
|
|
9
|
-
parser (3.3.10.1)
|
|
10
|
-
ast (~> 2.4.1)
|
|
11
|
-
racc
|
|
12
|
-
prism (1.8.0)
|
|
13
|
-
racc (1.8.1)
|
|
14
|
-
rainbow (3.1.1)
|
|
15
|
-
regexp_parser (2.11.3)
|
|
16
|
-
rubocop (1.82.1)
|
|
17
|
-
json (~> 2.3)
|
|
18
|
-
language_server-protocol (~> 3.17.0.2)
|
|
19
|
-
lint_roller (~> 1.1.0)
|
|
20
|
-
parallel (~> 1.10)
|
|
21
|
-
parser (>= 3.3.0.2)
|
|
22
|
-
rainbow (>= 2.2.2, < 4.0)
|
|
23
|
-
regexp_parser (>= 2.9.3, < 3.0)
|
|
24
|
-
rubocop-ast (>= 1.48.0, < 2.0)
|
|
25
|
-
ruby-progressbar (~> 1.7)
|
|
26
|
-
unicode-display_width (>= 2.4.0, < 4.0)
|
|
27
|
-
rubocop-ast (1.49.0)
|
|
28
|
-
parser (>= 3.3.7.2)
|
|
29
|
-
prism (~> 1.7)
|
|
30
|
-
rubocop-capybara (2.22.1)
|
|
31
|
-
lint_roller (~> 1.1)
|
|
32
|
-
rubocop (~> 1.72, >= 1.72.1)
|
|
33
|
-
rubocop-factory_bot (2.28.0)
|
|
34
|
-
lint_roller (~> 1.1)
|
|
35
|
-
rubocop (~> 1.72, >= 1.72.1)
|
|
36
|
-
rubocop-performance (1.26.1)
|
|
37
|
-
lint_roller (~> 1.1)
|
|
38
|
-
rubocop (>= 1.75.0, < 2.0)
|
|
39
|
-
rubocop-ast (>= 1.47.1, < 2.0)
|
|
40
|
-
rubocop-rspec (3.9.0)
|
|
41
|
-
lint_roller (~> 1.1)
|
|
42
|
-
rubocop (~> 1.81)
|
|
43
|
-
rubocop-rspec_rails (2.32.0)
|
|
44
|
-
lint_roller (~> 1.1)
|
|
45
|
-
rubocop (~> 1.72, >= 1.72.1)
|
|
46
|
-
rubocop-rspec (~> 3.5)
|
|
47
|
-
rubocop-thread_safety (0.7.3)
|
|
48
|
-
lint_roller (~> 1.1)
|
|
49
|
-
rubocop (~> 1.72, >= 1.72.1)
|
|
50
|
-
rubocop-ast (>= 1.44.0, < 2.0)
|
|
51
|
-
ruby-progressbar (1.13.0)
|
|
52
|
-
standard (1.53.0)
|
|
53
|
-
language_server-protocol (~> 3.17.0.2)
|
|
54
|
-
lint_roller (~> 1.0)
|
|
55
|
-
rubocop (~> 1.82.0)
|
|
56
|
-
standard-custom (~> 1.0.0)
|
|
57
|
-
standard-performance (~> 1.8)
|
|
58
|
-
standard-custom (1.0.2)
|
|
59
|
-
lint_roller (~> 1.0)
|
|
60
|
-
rubocop (~> 1.50)
|
|
61
|
-
standard-performance (1.9.0)
|
|
62
|
-
lint_roller (~> 1.1)
|
|
63
|
-
rubocop-performance (~> 1.26.0)
|
|
64
|
-
standard-rspec (0.4.0)
|
|
65
|
-
lint_roller (>= 1.0)
|
|
66
|
-
rubocop-capybara (~> 2.22)
|
|
67
|
-
rubocop-factory_bot (~> 2.27)
|
|
68
|
-
rubocop-rspec (~> 3.9)
|
|
69
|
-
rubocop-rspec_rails (~> 2.31)
|
|
70
|
-
unicode-display_width (3.2.0)
|
|
71
|
-
unicode-emoji (~> 4.1)
|
|
72
|
-
unicode-emoji (4.2.0)
|
|
73
|
-
yard (0.9.38)
|
|
74
|
-
yard-lint (1.4.0)
|
|
75
|
-
yard (~> 0.9)
|
|
76
|
-
zeitwerk (~> 2.6)
|
|
77
|
-
zeitwerk (2.7.4)
|
|
78
|
-
|
|
79
|
-
PLATFORMS
|
|
80
|
-
ruby
|
|
81
|
-
x86_64-linux
|
|
82
|
-
|
|
83
|
-
DEPENDENCIES
|
|
84
|
-
rubocop-performance
|
|
85
|
-
rubocop-rspec
|
|
86
|
-
rubocop-thread_safety
|
|
87
|
-
standard
|
|
88
|
-
standard-performance
|
|
89
|
-
standard-rspec
|
|
90
|
-
yard-lint
|
|
91
|
-
|
|
92
|
-
CHECKSUMS
|
|
93
|
-
ast (2.4.3) sha256=954615157c1d6a382bc27d690d973195e79db7f55e9765ac7c481c60bdb4d383
|
|
94
|
-
json (2.18.0) sha256=b10506aee4183f5cf49e0efc48073d7b75843ce3782c68dbeb763351c08fd505
|
|
95
|
-
language_server-protocol (3.17.0.5) sha256=fd1e39a51a28bf3eec959379985a72e296e9f9acfce46f6a79d31ca8760803cc
|
|
96
|
-
lint_roller (1.1.0) sha256=2c0c845b632a7d172cb849cc90c1bce937a28c5c8ccccb50dfd46a485003cc87
|
|
97
|
-
parallel (1.27.0) sha256=4ac151e1806b755fb4e2dc2332cbf0e54f2e24ba821ff2d3dcf86bf6dc4ae130
|
|
98
|
-
parser (3.3.10.1) sha256=06f6a725d2cd91e5e7f2b7c32ba143631e1f7c8ae2fb918fc4cebec187e6a688
|
|
99
|
-
prism (1.8.0) sha256=84453a16ef5530ea62c5f03ec16b52a459575ad4e7b9c2b360fd8ce2c39c1254
|
|
100
|
-
racc (1.8.1) sha256=4a7f6929691dbec8b5209a0b373bc2614882b55fc5d2e447a21aaa691303d62f
|
|
101
|
-
rainbow (3.1.1) sha256=039491aa3a89f42efa1d6dec2fc4e62ede96eb6acd95e52f1ad581182b79bc6a
|
|
102
|
-
regexp_parser (2.11.3) sha256=ca13f381a173b7a93450e53459075c9b76a10433caadcb2f1180f2c741fc55a4
|
|
103
|
-
rubocop (1.82.1) sha256=09f1a6a654a960eda767aebea33e47603080f8e9c9a3f019bf9b94c9cab5e273
|
|
104
|
-
rubocop-ast (1.49.0) sha256=49c3676d3123a0923d333e20c6c2dbaaae2d2287b475273fddee0c61da9f71fd
|
|
105
|
-
rubocop-capybara (2.22.1) sha256=ced88caef23efea53f46e098ff352f8fc1068c649606ca75cb74650970f51c0c
|
|
106
|
-
rubocop-factory_bot (2.28.0) sha256=4b17fc02124444173317e131759d195b0d762844a71a29fe8139c1105d92f0cb
|
|
107
|
-
rubocop-performance (1.26.1) sha256=cd19b936ff196df85829d264b522fd4f98b6c89ad271fa52744a8c11b8f71834
|
|
108
|
-
rubocop-rspec (3.9.0) sha256=8fa70a3619408237d789aeecfb9beef40576acc855173e60939d63332fdb55e2
|
|
109
|
-
rubocop-rspec_rails (2.32.0) sha256=4a0d641c72f6ebb957534f539d9d0a62c47abd8ce0d0aeee1ef4701e892a9100
|
|
110
|
-
rubocop-thread_safety (0.7.3) sha256=067cdd52fbf5deffc18995437e45b5194236eaff4f71de3375a1f6052e48f431
|
|
111
|
-
ruby-progressbar (1.13.0) sha256=80fc9c47a9b640d6834e0dc7b3c94c9df37f08cb072b7761e4a71e22cff29b33
|
|
112
|
-
standard (1.53.0) sha256=f3c9493385db7079d0abce6f7582f553122156997b81258cd361d3480eeacf9c
|
|
113
|
-
standard-custom (1.0.2) sha256=424adc84179a074f1a2a309bb9cf7cd6bfdb2b6541f20c6bf9436c0ba22a652b
|
|
114
|
-
standard-performance (1.9.0) sha256=49483d31be448292951d80e5e67cdcb576c2502103c7b40aec6f1b6e9c88e3f2
|
|
115
|
-
standard-rspec (0.4.0) sha256=0fdf64c887cd6404f1c3a1435b14ba6fde2e9e80c0f4dafe4b04a67f673db262
|
|
116
|
-
unicode-display_width (3.2.0) sha256=0cdd96b5681a5949cdbc2c55e7b420facae74c4aaf9a9815eee1087cb1853c42
|
|
117
|
-
unicode-emoji (4.2.0) sha256=519e69150f75652e40bf736106cfbc8f0f73aa3fb6a65afe62fefa7f80b0f80f
|
|
118
|
-
yard (0.9.38) sha256=721fb82afb10532aa49860655f6cc2eaa7130889df291b052e1e6b268283010f
|
|
119
|
-
yard-lint (1.4.0) sha256=7dd88fbb08fd77cb840bea899d58812817b36d92291b5693dd0eeb3af9f91f0f
|
|
120
|
-
zeitwerk (2.7.4) sha256=2bef90f356bdafe9a6c2bd32bcd804f83a4f9b8bc27f3600fff051eb3edcec8b
|
|
121
|
-
|
|
122
|
-
BUNDLED WITH
|
|
123
|
-
4.0.3
|