You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even if I provide the batchReceivePolicy property in the Map returned by configResolver.configToMap the builder.loadConf will not get this info because it can't handle complex attributes.
Will need to be used the same strategy used here to set the batchReceivePolicy to the builder.
Just adding this code make it work correctly
if (conf.getBatchReceivePolicy() != null) { builder.batchReceivePolicy(conf.getBatchReceivePolicy()); }
The text was updated successfully, but these errors were encountered:
I am sorry I couldn't totally follow the issue description.
Did you provide the batchReceive=true in channel attributes in addition to the batchReceivePolicy you are building using ConsumerConfigurationData ?
Hey @ozangunalp , yes I've provided the batchReceive=true and I'm providing the ConsumerConfigurationData setting the batchReceivePolicy there. But the batchReceivePolicy is never sent to the consumer builder in the PulsarIncomingChannel
Also, not related to the bug but due to a limitation in CDI you'd need to produce a ConsumerConfigurationData<Object> for the programmatic configuration to be taken into account.
When we add a configuration in Quarkus to provide a custom ConsumerConfigurationData with the batchReceivePolicy provided
`
@produces
@Identifier("goals")
public ConsumerConfigurationData getConsumerGoalsConfig() {
ConsumerConfigurationData data = new ConsumerConfigurationData<>();
data.setMaxPendingChunkedMessage(2000);
data.setBatchReceivePolicy(
BatchReceivePolicy.builder()
.messagesFromMultiTopicsEnabled(false)
.maxNumBytes(10 * 1024 * 1024)
.maxNumMessages(1000)
.timeout(30, TimeUnit.SECONDS)
.build());
return data;
}
`
This configuration is never sent to the builder..
We don't have here a if to set the batchReceivePolicy to the builder when the batchReceivePolicy is provided in the conf instance.
The process rely on this code.
Even if I provide the batchReceivePolicy property in the Map returned by configResolver.configToMap the builder.loadConf will not get this info because it can't handle complex attributes.
Will need to be used the same strategy used here to set the batchReceivePolicy to the builder.
Just adding this code make it work correctly
if (conf.getBatchReceivePolicy() != null) { builder.batchReceivePolicy(conf.getBatchReceivePolicy()); }
The text was updated successfully, but these errors were encountered: