Re: [Proposal] Make Dispatcher pluggable

2021-09-27 Thread PengHui Li
Thanks, LGTM. Penghui On Sun, Sep 26, 2021 at 4:32 PM Lin Lin wrote: > > > On 2021/09/24 14:09:14, PengHui Li wrote: > > Sorry for the late reply, > > > > If a batch has 10 messages, but users only want to filter out parts of > them > > such as 3 messages, only 7 messages should be processed a

Re: [Proposal] Make Dispatcher pluggable

2021-09-26 Thread Lin Lin
On 2021/09/24 14:09:14, PengHui Li wrote: > Sorry for the late reply, > > If a batch has 10 messages, but users only want to filter out parts of them > such as 3 messages, only 7 messages should be processed at the consumer > side. > So if the proposal is for the entry filter, I think we shou

Re: [Proposal] Make Dispatcher pluggable

2021-09-24 Thread PengHui Li
Sorry for the late reply, If a batch has 10 messages, but users only want to filter out parts of them such as 3 messages, only 7 messages should be processed at the consumer side. So if the proposal is for the entry filter, I think we should have the EntryFitler interface, not MessageFilter? Actu

Re: [Proposal] Make Dispatcher pluggable

2021-09-10 Thread Lin Lin
On 2021/09/10 06:22:09, PengHui Li wrote: > Looks good overall, > > Do we need to consider the batch filter since the API is defined as > `Message`, not `Entry`, so parts of the batch need to filter out, does it > should be handled by Filter, or the consumer side, or the producer side? > > T

Re: [Proposal] Make Dispatcher pluggable

2021-09-09 Thread PengHui Li
Looks good overall, Do we need to consider the batch filter since the API is defined as `Message`, not `Entry`, so parts of the batch need to filter out, does it should be handled by Filter, or the consumer side, or the producer side? Thanks, Penghui On Fri, Sep 10, 2021 at 11:53 AM Lin Lin wro

Re: [Proposal] Make Dispatcher pluggable

2021-09-09 Thread Lin Lin
> What about: > > public interface MessageFilter { >enum FilterOutcome { >ACCEPT, -> deliver to the Consumer >REJECT, -> skip the message >SYSTEM -> use standard system processing > } > > public FilterOutcome filterMessages(List message

Re: [Proposal] Make Dispatcher pluggable

2021-09-09 Thread Enrico Olivelli
Lin, Il giorno mer 8 set 2021 alle ore 09:40 Lin Lin ha scritto: > > > I also share this problem, because if you want to efficiently implement > > message filtering you need to do it in the broker side. > > > > I am not sure that making the full Dispatcher pluggable is a good idea, > > because t

Re: [Proposal] Make Dispatcher pluggable

2021-09-08 Thread Lin Lin
> I also share this problem, because if you want to efficiently implement > message filtering you need to do it in the broker side. > > I am not sure that making the full Dispatcher pluggable is a good idea, > because the code is too complex and also > it really depends on the internals of the B

Re: [Proposal] Make Dispatcher pluggable

2021-09-07 Thread Enrico Olivelli
Lin, Il giorno mer 8 set 2021 alle ore 07:34 linlin ha scritto: > # Motivation > > There are many users who need to use tag messages. The implementation of > this part has also been discussed before: > > > https://lists.apache.org/list.html?*@pulsar.apache.org:lte=2y:Proposal%20for%20Consumer%20

[Proposal] Make Dispatcher pluggable

2021-09-07 Thread linlin
# Motivation There are many users who need to use tag messages. The implementation of this part has also been discussed before: https://lists.apache.org/list.html?*@pulsar.apache.org:lte=2y:Proposal%20for%20Consumer%20Filtering%20in%20Pulsar%20brokers I suggest to plug-in the Dispatcher, so that