Skip to content
This repository has been archived by the owner on Mar 10, 2020. It is now read-only.

Kafka ascoltatore is not using HighLevelConsumer #158

Closed
sanchuvarkey-accesso opened this issue Nov 18, 2016 · 8 comments
Closed

Kafka ascoltatore is not using HighLevelConsumer #158

sanchuvarkey-accesso opened this issue Nov 18, 2016 · 8 comments

Comments

@sanchuvarkey-accesso
Copy link
Contributor

I have noticed the Kafka client as part of this integration is using the Simple consumer. As part of our project, we need to use HighLevelConsumer to get the queue functionality from Kafka.

To achieve the above we need to modify the _startConn method in kafka_ascoltatore.js something like this

if (useHighLevelConsumer) {
            that._consumer = new HighLevelConsumer(that._consumerClient, subscriptions, {
                groupId: groupId,
                fromOffset: true, autoCommit: false, encoding: "buffer"
            });
        } else {
            that._consumer = new Consumer(that._consumerClient, subscriptions, {
                groupId: groupId,
                fromOffset: true, autoCommit: false, encoding: "buffer"
            });
        }
@mcollina
Copy link
Collaborator

Would you like to send us a pull request? What's the difference between the two?

@sanchuvarkey-accesso
Copy link
Contributor Author

The high level consumer can manage things like offset commits and rebalancing across consumer instances in a consumer group automatically.

Using the simple consumer you have to manage partition subscription, broker leader changes and offset commits yourself. The concept of a consumer group does not exist for the simple consumer API.

contents from here
http://stackoverflow.com/questions/31482004/what-is-the-difference-between-simple-consumer-and-high-level-consumer

@sanchuvarkey-accesso
Copy link
Contributor Author

Yes i can submit a pull request

@mcollina
Copy link
Collaborator

Thanks!

@sanchuvarkey-accesso
Copy link
Contributor Author

I am getting 403 when i try to commit to this repo. Can you please add me as a committer? my username is svarkey

Thanks
Sanchu

@mcollina
Copy link
Collaborator

@svarkey you will need to press the fork button on the top right of github, commit there, and then send a pull request from that repo.

@sanchuvarkey-accesso
Copy link
Contributor Author

Pull request created
#159

@sanchuvarkey-accesso
Copy link
Contributor Author

Issue verified on version 3.2.0. Closing this

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants