salesforce / storm-dynamic-spout

A framework for building spouts for Apache Storm and a Kafka based spout for dynamically skipping messages to be processed later.
BSD 3-Clause "New" or "Revised" License
40 stars 13 forks source link

[KAFKA] Limit the number of times fillBuffer() can be called recursively #42

Closed stanlemon closed 6 years ago

stanlemon commented 6 years ago

See https://github.com/salesforce/storm-dynamic-spout/blob/56a4cd0c0aae9a1689ab2ccbf7cc08f8e6842d2a/src/main/java/com/salesforce/storm/spout/dynamic/kafka/Consumer.java#L404

To avoid a Stackoverflow we should limit the number of times fillBuffer can be called recursively, basically setting an upper bounds to the times we attempt this during an OutOfRangeException.