You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "li xiangyuan (Jira)" <ji...@apache.org> on 2019/08/24 10:10:00 UTC

[jira] [Commented] (KAFKA-1448) Filter-plugins for messages

    [ https://issues.apache.org/jira/browse/KAFKA-1448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16914900#comment-16914900 ] 

li xiangyuan commented on KAFKA-1448:
-------------------------------------

hi

since kafka now support for add heads to message ,I think it is possible now to filter message with given message head on server side. 

in my situation,we have a topic more than 30 groups subscribe it,and every group only need handle less than 1/3 meesages in this topic. if we can implement server-side message filter,we could reduce network flow obviously.

i wrote some code extends FileRecords class to send meesage only without specified message head  and success,I think it's a good way to filter message.

> Filter-plugins for messages
> ---------------------------
>
>                 Key: KAFKA-1448
>                 URL: https://issues.apache.org/jira/browse/KAFKA-1448
>             Project: Kafka
>          Issue Type: Wish
>          Components: consumer
>            Reporter: Moritz Möller
>            Assignee: Neha Narkhede
>            Priority: Major
>
> Hi,
> we use Kafka to transmit different events that occur on different products, and would like to be able to subscribe only to a certain set of events for certain products.
> Using one topic for each event * product combination would yield around 2000 topics, which seems to be not what kafka is designed for.
> What we would need is a way to add a consumer filter plugin to kafka (a simple class that can accept or reject a message) and to pass a parameter from the consumer to that filter class.
> Is there a better way to do this already, or if not, would you accept a patch upstream that adds such a mechanism?
> Thanks,
> Mo



--
This message was sent by Atlassian Jira
(v8.3.2#803003)