-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expose More Performance-Related Configurations #630
Expose More Performance-Related Configurations #630
Conversation
Doing testing with the defaults.
It completed in 10 minutes 3 seconds. Yikes. Looked like a lot of RocksDB Write Stalls. Most likely caused by the Write Buffer Manager Size being too small. |
This also took ~10 minutes. Turns out that this ticket is blocked by #576 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We might want to open a tech-debt ticket to make this class smaller.
I disabled metrics aggregation ( I disabled the changes related to the WriteBufferManager and Block Cache size (no shared WBM or Block Cache). Keeping the changes to commit interval and state store cache kept the small performance improvement (113 seconds). My thoughts going into this PR were confirmed:
I think this PR is ready to review on its own. We should define follow-up issues to:
My profiling has confirmed that this ticket accomplishes what it needed to do—power users can mostly limit the total on-heap and off-heap memory by tuning configurations, and we also improved performance slightly in the case where more resources are provided to the server. The only danger of this PR is that the new default configurations result in poorer performance than the old default configurations, because for certain types of memory the old configurations did not specify a limit (which is dangerous as it makes OOM more easy to occur) |
…m with no limits.
07880ec
to
ffcfc8d
Compare
…s-configurations-with-smart-guardrails
…allow-user-to-set-streams-configurations-with-smart-guardrails
// Need to inject the LHServerConfig, but Kafka Streams requires we pass in a Class with | ||
// a default constructor. So the only way to do that is to have a static singleton which | ||
// we set elsewhere in the code. | ||
public static LHServerConfig serverConfig; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mjsax this appears to be the only way to "inject" configuration into the RockDBConfigSetter
implementation. Would it be worth a KIP to add a method:
KafkaStreams#setRocksDBConfigurator(RocksDBConfigSetter otterSetter)
The method should throw IllegalStateException
if it is called after KafkaStreams#start()
, or if the rocksdb.config.setter
parameter is set on the properties.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't think it's the only way to inject configs.
There is RocksConfigSetter.setConfig(..., config)
taking the Kafka Streams config
object and third parameter. When you create StreamsConfig
you pass in Map<?, ?> props
and all entries will be contained in config
.
Thus, you can take LHServerConfig
and add all of it to props
before creating StreamsConfig
and should have access to all of it in setConfig(...)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mjsax Thanks so much! This works great. Much better than submitting a KIP to the Apache Kafka Debate Club 😄
CC @eduwercamacaro let's refactor this tomorrow.
No description provided.