sbmt-kafka_producer 3.1.0 → 3.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b9d0ac5904cd82c25700683f5b2955dd4b115328c6f854af93a4532407af48a2
4
- data.tar.gz: af80b9874b6161f01b78e219a694850ab44b5cf234388d6a66ea0350af31e3a8
3
+ metadata.gz: 3ce35f992f57c20f9746ed0c2d914f9fe8a783bad484d4b1edc0007bab97d0c0
4
+ data.tar.gz: b03f5d0240033e4d38bf11aa80c140e13d2776260d606bd74093cb8fb143e862
5
5
  SHA512:
6
- metadata.gz: 309463f869927645071f9cfa27ac92c0d10bb044f1ff9441ef3de54115fc05f2ea7286678acd98838278c0011fc047ec43a49408530c86ef18e626b54119ef84
7
- data.tar.gz: f823b0dfba4f627953e25802d18bfe342646912a7e5c19285e8901b7c7d15512b37e114b0ee87bfb1c2de481abeab604b753d309ec96f8572c2dcdc1749f02d1
6
+ metadata.gz: 244f293d301325ecfbffff6d19c9683488f265028d384dde9dd0ca445451185ea4f48b7225ade46ad32e86d9f29549a0bf47446b7d27eb9332efac0ac41b7e5d
7
+ data.tar.gz: 66981ce8b08d64ea14f474cee45a8d776fd10326516c7abeade30261a1646b385e8621037918986995e76c956dfa2ef8e17ea7b3222b1d23202080bb187a330d
data/CHANGELOG.md CHANGED
@@ -13,6 +13,18 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
13
13
 
14
14
  ### Fixed
15
15
 
16
+ ## [3.2.0] - 2024-11-22
17
+
18
+ ### Changed
19
+
20
+ - Removed `ignore_kafka_error` option
21
+
22
+ ## [3.1.1] - 2024-10-31
23
+
24
+ ### Changed
25
+
26
+ - Update README
27
+
16
28
  ## [3.1.0] - 2024-09-13
17
29
 
18
30
  ### Added
data/Gemfile CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- source "https://rubygems.org"
3
+ source ENV.fetch("NEXUS_PUBLIC_SOURCE_URL", "https://rubygems.org")
4
4
 
5
5
  gemspec
data/README.md CHANGED
@@ -62,11 +62,10 @@ The `config/kafka_producer.yml` file is the main configuration for this gem.
62
62
  ```yaml
63
63
  default: &default
64
64
  deliver: true
65
- ignore_kafka_error: true
66
65
  # see more options at https://github.com/karafka/waterdrop/blob/master/lib/waterdrop/config.rb
67
66
  wait_on_queue_full: true
68
67
  max_payload_size: 1000012
69
- max_wait_timeout_ms: 60000
68
+ max_wait_timeout: 60000
70
69
  auth:
71
70
  kind: plaintext
72
71
  kafka:
@@ -77,9 +76,9 @@ default: &default
77
76
  retry_backoff: 1000 # in milliseconds, optional, default: 1000
78
77
  connect_timeout: 2000 # in milliseconds, optional, default: 2000
79
78
  message_timeout: 55000 # in milliseconds, optional, default: 55000
80
- kafka_config: # low-level custom Kafka options
81
- queue.buffering.max.messages: 1
82
- queue.buffering.max.ms: 10000
79
+ # kafka_config: # optional, low-level custom Kafka options (see https://github.com/confluentinc/librdkafka/blob/master/CONFIGURATION.md)
80
+ # queue.buffering.max.messages: 100000
81
+ # queue.buffering.max.ms: 5
83
82
 
84
83
  development:
85
84
  <<: *default
@@ -3,7 +3,6 @@ default: &default
3
3
  wait_on_queue_full: true
4
4
  max_payload_size: 1000012
5
5
  max_wait_timeout: 60000
6
- ignore_kafka_error: true
7
6
 
8
7
  auth:
9
8
  sasl_username: <%= ENV.fetch('KAFKA_BROKERS'){ 'SCRAM-SHA-512:kafka_login:kafka_password' }.split(':').second %>
@@ -75,13 +75,7 @@ module Sbmt
75
75
  result
76
76
  end
77
77
 
78
- def ignore_kafka_errors?
79
- config.ignore_kafka_error.to_s == "true"
80
- end
81
-
82
78
  def log_error(error)
83
- return true if ignore_kafka_errors?
84
-
85
79
  log_tags = {stacktrace: error.backtrace.join("\n")}
86
80
 
87
81
  logger.tagged(log_tags) do
@@ -27,15 +27,14 @@ module Sbmt
27
27
 
28
28
  config_name :kafka_producer
29
29
 
30
- attr_config :ignore_kafka_error, :deliver, :wait_on_queue_full,
30
+ attr_config :deliver, :wait_on_queue_full,
31
31
  :max_payload_size, :max_wait_timeout,
32
32
  :wait_on_queue_full_timeout,
33
33
  auth: {}, kafka: {},
34
34
  logger_class: "::Sbmt::KafkaProducer::Logger",
35
35
  metrics_listener_class: "::Sbmt::KafkaProducer::Instrumentation::YabedaMetricsListener"
36
36
 
37
- coerce_types ignore_kafka_error: :boolean,
38
- deliver: :boolean, wait_on_queue_full: :boolean,
37
+ coerce_types deliver: :boolean, wait_on_queue_full: :boolean,
39
38
  max_payload_size: :integer, max_wait_timeout: :integer,
40
39
  wait_on_queue_full_timeout: :integer
41
40
  coerce_types kafka: coerce_to(Kafka)
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Sbmt
4
4
  module KafkaProducer
5
- VERSION = "3.1.0"
5
+ VERSION = "3.2.0"
6
6
  end
7
7
  end
@@ -13,7 +13,7 @@ Gem::Specification.new do |spec|
13
13
  spec.homepage = "https://github.com/Kuper-Tech/sbmt-kafka_producer"
14
14
  spec.required_ruby_version = ">= 3.0.0"
15
15
 
16
- spec.metadata["allowed_push_host"] = "https://rubygems.org"
16
+ spec.metadata["allowed_push_host"] = ENV.fetch("NEXUS_URL", "https://rubygems.org")
17
17
 
18
18
  spec.metadata["homepage_uri"] = spec.homepage
19
19
  spec.metadata["source_code_uri"] = spec.homepage
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sbmt-kafka_producer
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0
4
+ version: 3.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kuper Ruby-Platform Team
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-09-18 00:00:00.000000000 Z
11
+ date: 2024-11-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: anyway_config
@@ -426,7 +426,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
426
426
  - !ruby/object:Gem::Version
427
427
  version: '0'
428
428
  requirements: []
429
- rubygems_version: 3.1.6
429
+ rubygems_version: 3.3.7
430
430
  signing_key:
431
431
  specification_version: 4
432
432
  summary: Ruby gem for producing Kafka messages