-
Notifications
You must be signed in to change notification settings - Fork 107
BatchingSettings default value for elementCountThreshold #543
Comments
@vam-google any updates on this? |
@zhengzhu88 This behavior is by design. I believe that the default values for the batching properties have to be Then the default values were chaned to "no batching by default", see #2542. Interestingly enough the older issue also mentions amount of minutes needed to figure out what was happening (it says 20 minutes). So it seems, the older defaults were better ones (it took 20 minutes, compared to 30 minutes now =). At the same time we cannot provide default batching properties to anything else except "no batching" because Also max element count is not the only threshold
All these three must coexist somehow, if we increase But what is really missing here is the documentation. If we choose a default value, we must specify it explicitly in the documentation, so it does not confuse users. I believe the proper documentation should solve most of the problems here. |
This was fixed by providing proper documentation for |
When creating a BatchingSettings object using the builder, if a user doesn't explicitly call
builder.setElementCountThreshold()
, the builder uses the default elementCountThreshold of 1. That means that the default behavior of the BatchingSettings object is to not batch at all. I spent a good 30 minutes trying to figure out my application wasn't batching messages even when I was using a BatchingSettings object. Can the default value be something greater than 1, just so that when the user tries to batch something, it doesn't look like the library is broken?The text was updated successfully, but these errors were encountered: