Skip to content

Commit 154e3d3

Browse files
authored
karafka-rdkafka syncs + ci sync (#689)
* rules snc * missing stress * fixes * fix rspec exclusions * remark * remarks * remove 3.1 * remarks * fix * rm fix * fix metadata * Trigger CI build
1 parent 76f0978 commit 154e3d3

17 files changed

+143
-45
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
## 0.23.0 (Unreleased)
44
- **[Breaking]** Drop support for Ruby 3.1 to move forward with the fiber scheduler work.
5+
- [Enhancement] Bump librdkafka to `2.11.0`
56
- [Enhancement] Support explicit Debian testing due to lib issues.
67
- [Enhancement] Support ARM64 Gnu precompilation.
78
- [Enhancement] Improve what symbols are exposed outside of the precompiled extensions.

README.md

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -163,16 +163,17 @@ bundle exec rake produce_messages
163163

164164
| rdkafka-ruby | librdkafka | patches |
165165
|-|-|-|
166-
| 0.22.x (2025-07-17) | 2.8.0 (2025-01-07) | yes |
167-
| 0.21.x (2025-02-13) | 2.8.0 (2025-01-07) | yes |
168-
| 0.20.0 (2025-01-07) | 2.6.1 (2024-11-18) | yes |
169-
| 0.19.0 (2024-10-01) | 2.5.3 (2024-09-02) | yes |
170-
| 0.18.0 (2024-09-02) | 2.5.0 (2024-06-10) | yes |
171-
| 0.17.0 (2024-08-03) | 2.4.0 (2024-05-07) | no |
172-
| 0.16.0 (2024-06-13) | 2.3.0 (2023-10-25) | no |
173-
| 0.15.0 (2023-12-03) | 2.3.0 (2023-10-25) | no |
174-
| 0.14.0 (2023-11-21) | 2.2.0 (2023-07-12) | no |
175-
| 0.13.0 (2023-07-24) | 2.0.2 (2023-01-20) | no |
176-
| 0.12.0 (2022-06-17) | 1.9.0 (2022-06-16) | no |
177-
| 0.11.0 (2021-11-17) | 1.8.2 (2021-10-18) | no |
178-
| 0.10.0 (2021-09-07) | 1.5.0 (2020-07-20) | no |
166+
| 0.23.x (Unreleased) | 2.11.0 (2025-07-03) | yes |
167+
| 0.22.x (2025-07-17) | 2.8.0 (2025-01-07) | yes |
168+
| 0.21.x (2025-02-13) | 2.8.0 (2025-01-07) | yes |
169+
| 0.20.0 (2025-01-07) | 2.6.1 (2024-11-18) | yes |
170+
| 0.19.0 (2024-10-01) | 2.5.3 (2024-09-02) | yes |
171+
| 0.18.0 (2024-09-02) | 2.5.0 (2024-06-10) | yes |
172+
| 0.17.0 (2024-08-03) | 2.4.0 (2024-05-07) | no |
173+
| 0.16.0 (2024-06-13) | 2.3.0 (2023-10-25) | no |
174+
| 0.15.0 (2023-12-03) | 2.3.0 (2023-10-25) | no |
175+
| 0.14.0 (2023-11-21) | 2.2.0 (2023-07-12) | no |
176+
| 0.13.0 (2023-07-24) | 2.0.2 (2023-01-20) | no |
177+
| 0.12.0 (2022-06-17) | 1.9.0 (2022-06-16) | no |
178+
| 0.11.0 (2021-11-17) | 1.8.2 (2021-10-18) | no |
179+
| 0.10.0 (2021-09-07) | 1.5.0 (2020-07-20) | no |
Binary file not shown.

ext/build_common.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ readonly CYRUS_SASL_VERSION="2.1.28"
1919
readonly ZLIB_VERSION="1.3.1"
2020
readonly ZSTD_VERSION="1.5.7"
2121
readonly KRB5_VERSION="1.21.3"
22-
readonly LIBRDKAFKA_VERSION="2.8.0"
22+
readonly LIBRDKAFKA_VERSION="2.11.0"
2323

2424
# SHA256 checksums for supply chain security
2525
# Update these when upgrading versions
@@ -29,7 +29,7 @@ declare -A CHECKSUMS=(
2929
["zlib-1.3.1.tar.gz"]="9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23"
3030
["zstd-${ZSTD_VERSION}.tar.gz"]="eb33e51f49a15e023950cd7825ca74a4a2b43db8354825ac24fc1b7ee09e6fa3"
3131
["krb5-${KRB5_VERSION}.tar.gz"]="b7a4cd5ead67fb08b980b21abd150ff7217e85ea320c9ed0c6dadd304840ad35"
32-
["librdkafka-${LIBRDKAFKA_VERSION}.tar.gz"]="5bd1c46f63265f31c6bfcedcde78703f77d28238eadf23821c2b43fc30be3e25"
32+
["librdkafka-${LIBRDKAFKA_VERSION}.tar.gz"]="592a823dc7c09ad4ded1bc8f700da6d4e0c88ffaf267815c6f25e7450b9395ca"
3333
)
3434

3535
# Colors for output

lib/rdkafka/admin.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -664,7 +664,6 @@ def describe_acl(resource_type:, resource_name:, resource_pattern_type:, princip
664664
describe_acl_handle
665665
end
666666

667-
668667
# Describe configs
669668
#
670669
# @param resources [Array<Hash>] Array where elements are hashes with two keys:

lib/rdkafka/config.rb

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,10 +129,7 @@ def self.opaques
129129
end
130130

131131
# Default config that can be overwritten.
132-
DEFAULT_CONFIG = {
133-
# Request api version so advanced features work
134-
:"api.version.request" => true
135-
}.freeze
132+
DEFAULT_CONFIG = {}.freeze
136133

137134
# Required config that cannot be overwritten.
138135
REQUIRED_CONFIG = {

lib/rdkafka/consumer.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ def assignment_lost?
246246
# @param timeout_ms [Integer] The timeout for fetching this information.
247247
# @return [TopicPartitionList]
248248
# @raise [RdkafkaError] When getting the committed positions fails.
249-
def committed(list=nil, timeout_ms=2000)
249+
def committed(list=nil, timeout_ms=2_000)
250250
closed_consumer_check(__method__)
251251

252252
if list.nil?

lib/rdkafka/consumer/topic_partition_list.rb

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,10 +66,14 @@ def add_topic(topic, partitions=nil)
6666
#
6767
# @param topic [String] The topic's name
6868
# @param partitions_with_offsets [Hash<Integer, Integer>] The topic's partitions and offsets
69+
# @param partitions_with_offsets [Array<Consumer::Partition>] The topic's partitions with offsets
70+
# and metadata (if any)
6971
#
7072
# @return [nil]
7173
def add_topic_and_partitions_with_offsets(topic, partitions_with_offsets)
72-
@data[topic.to_s] = partitions_with_offsets.map { |p, o| Partition.new(p, o) }
74+
@data[topic.to_s] = partitions_with_offsets.map do |p, o|
75+
p.is_a?(Partition) ? p : Partition.new(p, o)
76+
end
7377
end
7478

7579
# Return a `Hash` with the topics as keys and and an array of partition information as the value if present.

lib/rdkafka/producer.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@ class Producer
66
include Helpers::Time
77
include Helpers::OAuth
88

9-
# Empty hash used as a default
10-
EMPTY_HASH = {}.freeze
11-
129
# @private
1310
@@partitions_count_cache = PartitionsCountCache.new
1411

@@ -30,6 +27,9 @@ def self.partitions_count_cache=(partitions_count_cache)
3027
@@partitions_count_cache = partitions_count_cache
3128
end
3229

30+
# Empty hash used as a default
31+
EMPTY_HASH = {}.freeze
32+
3333
private_constant :EMPTY_HASH
3434

3535
# Raised when there was a critical issue when invoking rd_kafka_topic_new

lib/rdkafka/version.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
module Rdkafka
44
VERSION = "0.23.0"
5-
LIBRDKAFKA_VERSION = "2.8.0"
6-
LIBRDKAFKA_SOURCE_SHA256 = "5bd1c46f63265f31c6bfcedcde78703f77d28238eadf23821c2b43fc30be3e25"
5+
LIBRDKAFKA_VERSION = "2.11.0"
6+
LIBRDKAFKA_SOURCE_SHA256 = "592a823dc7c09ad4ded1bc8f700da6d4e0c88ffaf267815c6f25e7450b9395ca"
77
end

0 commit comments

Comments
 (0)