karafka 2.0.16 → 2.0.17

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8cc0ac8b318d7c40e8974e2e26753c68cc5f611bbcd0e4fbea94e3eb275002dd
4
- data.tar.gz: db638edaecc662ac8a0f7d627f4bcae6e1e1e83500a49c4dfa4a4f32ee8f78c9
3
+ metadata.gz: 8d15d4c803dc84a009e4a1ab02e90a9f034a396f718f742060c545f00422ffd5
4
+ data.tar.gz: fd69d2a4dcb11a9ea94b8a9f7a4dbb505034a304e94b1bd5e9a0a9fe44a666f0
5
5
  SHA512:
6
- metadata.gz: 6875e7e152b4150f397f3830c828412e0477409483c81e714525161e5263cff686c0cb9b46a6c11cb5b914dc51087e4bac95d5dcdc0e25c7233825b363ed7e6c
7
- data.tar.gz: 1f35d410350dc3fbe97462e979f3df832484df1f1f5119e16fe2c28210d01a05e1d3e086c73e1a3b70ba3c6cae9a25dd50e0907ca454b68c9166efcabd22f972
6
+ metadata.gz: fe75bb62fecbca6b541d1c1737a596b0a937a02a294ec62a13220915194807568be84c0ebb338de6de8a124714164ed7f7f060cdb573f5606357cce861ba364f
7
+ data.tar.gz: 6c622f4d2ce80b86807e0e05b3108f7fab66ba2696cd2b662a3412986bc98ba954d03bf70141c3a5526e8e4954495efa34c846a0ec594e2e05b05ef2fa01291a
checksums.yaml.gz.sig CHANGED
Binary file
@@ -109,6 +109,7 @@ jobs:
109
109
  uses: ruby/setup-ruby@v1
110
110
  with:
111
111
  ruby-version: ${{matrix.ruby}}
112
+ bundler-cache: true
112
113
 
113
114
  - name: Install latest Bundler
114
115
  run: |
data/CHANGELOG.md CHANGED
@@ -1,5 +1,26 @@
1
1
  # Karafka framework changelog
2
2
 
3
+ ## 2.0.17 (2022-11-10)
4
+ - [Fix] Few typos around DLQ and Pro DLQ Dispatch original metadata naming.
5
+ - [Fix] Narrow the components lookup to the appropriate scope (#1114)
6
+
7
+ ### Upgrade notes
8
+
9
+ 1. Replace `original-*` references from DLQ dispatched metadata with `original_*`
10
+
11
+ ```ruby
12
+ # DLQ topic consumption
13
+ def consume
14
+ messages.each do |broken_message|
15
+ topic = broken_message.metadata['original_topic'] # was original-topic
16
+ partition = broken_message.metadata['original_partition'] # was original-partition
17
+ offset = broken_message.metadata['original_offset'] # was original-offset
18
+
19
+ Rails.logger.error "This message is broken: #{topic}/#{partition}/#{offset}"
20
+ end
21
+ end
22
+ ```
23
+
3
24
  ## 2.0.16 (2022-11-09)
4
25
  - **[Breaking]** Disable the root `manual_offset_management` setting and require it to be configured per topic. This is part of "topic features" configuration extraction for better code organization.
5
26
  - **[Feature]** Introduce **Dead Letter Queue** feature and Pro **Enhanced Dead Letter Queue** feature
@@ -26,7 +47,6 @@
26
47
  - [Specs] Split specs into regular and pro to simplify how resources are loaded
27
48
  - [Specs] Add specs to ensure, that all the Pro components have a proper per-file license (#1099)
28
49
 
29
-
30
50
  ### Upgrade notes
31
51
 
32
52
  1. Remove the `manual_offset_management` setting from the main config if you use it:
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- karafka (2.0.16)
4
+ karafka (2.0.17)
5
5
  karafka-core (>= 2.0.2, < 3.0.0)
6
6
  rdkafka (>= 0.12)
7
7
  thor (>= 0.20)
data/README.md CHANGED
@@ -4,6 +4,8 @@
4
4
  [![Gem Version](https://badge.fury.io/rb/karafka.svg)](http://badge.fury.io/rb/karafka)
5
5
  [![Join the chat at https://slack.karafka.io](https://raw.githubusercontent.com/karafka/misc/master/slack.svg)](https://slack.karafka.io)
6
6
 
7
+ **Note**: Upgrade notes for migration from Karafka `1.4` to Karafka `2.0` can be found [here](https://karafka.io/docs/Upgrades-2.0/).
8
+
7
9
  ## About Karafka
8
10
 
9
11
  Karafka is a Ruby and Rails multi-threaded efficient Kafka processing framework that:
@@ -123,7 +123,7 @@ module Karafka
123
123
  dlq_topic = event[:caller].topic.dead_letter_queue.topic
124
124
  partition = message.partition
125
125
 
126
- info "Dispatched message #{offset} from #{topic}/#{partition} to DQL topic: #{dlq_topic}"
126
+ info "Dispatched message #{offset} from #{topic}/#{partition} to DLQ topic: #{dlq_topic}"
127
127
  end
128
128
 
129
129
  # There are many types of errors that can occur in many places, but we provide a single
@@ -68,9 +68,9 @@ module Karafka
68
68
  payload: skippable_message.raw_payload,
69
69
  key: skippable_message.partition.to_s,
70
70
  headers: skippable_message.headers.merge(
71
- 'original-topic' => topic.name,
72
- 'original-partition' => skippable_message.partition.to_s,
73
- 'original-offset' => skippable_message.offset.to_s
71
+ 'original_topic' => topic.name,
72
+ 'original_partition' => skippable_message.partition.to_s,
73
+ 'original_offset' => skippable_message.offset.to_s
74
74
  )
75
75
  )
76
76
 
@@ -13,10 +13,10 @@ module Karafka
13
13
  class << self
14
14
  # Extends topic and builder with given feature API
15
15
  def activate
16
- Topic.prepend(self::Topic) if const_defined?('Topic')
17
- Proxy.prepend(self::Builder) if const_defined?('Builder')
18
- Builder.prepend(self::Builder) if const_defined?('Builder')
19
- Builder.prepend(Base::Expander.new(self)) if const_defined?('Contract')
16
+ Topic.prepend(self::Topic) if const_defined?('Topic', false)
17
+ Proxy.prepend(self::Builder) if const_defined?('Builder', false)
18
+ Builder.prepend(self::Builder) if const_defined?('Builder', false)
19
+ Builder.prepend(Base::Expander.new(self)) if const_defined?('Contract', false)
20
20
  end
21
21
 
22
22
  # Loads all the features and activates them
@@ -4,7 +4,7 @@ module Karafka
4
4
  module Routing
5
5
  module Features
6
6
  class DeadLetterQueue < Base
7
- # DQL topic extensions
7
+ # DLQ topic extensions
8
8
  module Topic
9
9
  # After how many retries should be move data to DLQ
10
10
  DEFAULT_MAX_RETRIES = 3
@@ -3,5 +3,5 @@
3
3
  # Main module namespace
4
4
  module Karafka
5
5
  # Current Karafka version
6
- VERSION = '2.0.16'
6
+ VERSION = '2.0.17'
7
7
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: karafka
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.16
4
+ version: 2.0.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Maciej Mensfeld
@@ -35,7 +35,7 @@ cert_chain:
35
35
  Qf04B9ceLUaC4fPVEz10FyobjaFoY4i32xRto3XnrzeAgfEe4swLq8bQsR3w/EF3
36
36
  MGU0FeSV2Yj7Xc2x/7BzLK8xQn5l7Yy75iPF+KP3vVmDHnNl
37
37
  -----END CERTIFICATE-----
38
- date: 2022-11-09 00:00:00.000000000 Z
38
+ date: 2022-11-10 00:00:00.000000000 Z
39
39
  dependencies:
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: karafka-core
metadata.gz.sig CHANGED
Binary file