-
Notifications
You must be signed in to change notification settings - Fork 64
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
Kafka Partition Key Routing #18
Comments
Let me know if this should be a separate issue. I tried to workaround my issue by processing a key-based partition assignment in nginx lua and then settings a variable used by kafka_partition. It looks like this won't work because I get this error from ngx_kafka_module: Also, based on my initial question, let me know if there is a better way to approach this. |
In my opinion, it is a good way using And I'm very glad to diagnose your problems if it is convenient for you to paste some configuration code here. |
@brg-liuwei thanks. The config is relatively simple at this point:
I understand what you mean by having a separate location block per partition to solve this problem however I'm unable to add a partition number into the incoming URI. So the remaining question is how do I modify the URI of an incoming request with |
@dkinon
Send message with route_key:
Those code has been tested in my dev env. It worked. And if you have any another questions, feel free to add more comments. |
This is working for me, thanks. It would be nice to have a more dynamic configuration for this where |
@dkinon The PR you mentioned is welcomed. You can first read the source code and then learn some basic knowledge about nginx module development. And we can discuss technical questions there or in PR context. |
I've got basic kafka message routing working but I have a requirement to route messages to a partition based on a routing key. Is there a way to achieve this currently?
The text was updated successfully, but these errors were encountered: