Skip to content

Conversation

@robbavey
Copy link
Member

This is a common error, which cannot be fixed without changing Logstash setting
and should not be hidden as a debug log entry.

Fixes #177

futures.each_with_index do |future, i|
begin
result = future.get()
rescue org.apache.kafka.common.errors.RecordTooLargeException => x
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@robbavey there's another PR that catches this exception during producer.send
https://github.com/logstash-plugins/logstash-output-kafka/pull/191/files#diff-c6a637e53249d2c5a0ee842b0bc19e82R265 instead of this PR's future.get

I believe this one makes sense as the other operation will only return the future so no exception should be raised, right?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this PR ups the visibility of an error that was already being logged at debug in the following rescue => e block. I'm kind of tempted to change this PR to just increase the log level of the blanket rescue to increase the visibility of any error caught here, and reduce if the noise levels get too high.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed, we want to know whenever an error happens, otherwise logstash will either be silently retrying things or dropping data (Both terrible).

Log errors encountered when sending messages to Kafka at warn, rather than
debug, to improve the visibility of errors such as 'RecordTooLargeException.'

Fixes logstash-plugins#177
Copy link
Member

@jsvd jsvd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM pending on 💚

@elasticsearch-bot
Copy link

Rob Bavey merged this into the following branches!

Branch Commits
master 8161bd6, e6d61ec

elasticsearch-bot pushed a commit that referenced this pull request Jun 5, 2018
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Log errors encountered when sending messages to Kafka at warn, rather than
debug, to improve the visibility of errors such as 'RecordTooLargeException.'

Fixes logstash-plugins#177

Fixes logstash-plugins#179
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Fixed incorrect millisecond to second conversion for retry_backoff_ms logstash-plugins#216
Fixed unnecessary sleep after exhausted retries logstash-plugins#166
Changed Kafka send errors to log as warn logstash-plugins#179
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Fixed incorrect millisecond to second conversion for retry_backoff_ms logstash-plugins#216
Fixed unnecessary sleep after exhausted retries logstash-plugins#166
Changed Kafka send errors to log as warn logstash-plugins#179
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Fixed incorrect millisecond to second conversion for retry_backoff_ms logstash-plugins#216
Fixed unnecessary sleep after exhausted retries logstash-plugins#166
Changed Kafka send errors to log as warn logstash-plugins#179
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Fixed unnecessary sleep after exhausted retries logstash-plugins#166
Changed Kafka send errors to log as warn logstash-plugins#179
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Fixed unnecessary sleep after exhausted retries logstash-plugins#166
Changed Kafka send errors to log as warn logstash-plugins#179
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Fixed unnecessary sleep after exhausted retries logstash-plugins#166
Changed Kafka send errors to log as warn logstash-plugins#179
robbavey added a commit to robbavey/logstash-output-kafka that referenced this pull request Feb 11, 2019
Fixed unnecessary sleep after exhausted retries logstash-plugins#166
Changed Kafka send errors to log as warn logstash-plugins#179
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Increase default max_request_size

3 participants