We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
The consumer inside the KafkaPubSub class is private.
I need to access it in order to register it to some emitted events like "consumer.stop" or "consumer.crash".
Can you please provide a solution for this?
Maybe a public method inside the KafkaPubSub class that allows registering events to the created consumer could be a solution?
Thanks!
The text was updated successfully, but these errors were encountered:
@tomasAlabes something like this could be a solution?
import { ... ConsumerEvents RemoveInstrumentationEventListener, ValueOf } from "kafkajs"; ... public consumerOn( eventName: ValueOf<ConsumerEvents>, listener: (event: any) => void ): RemoveInstrumentationEventListener<typeof eventName> { return this.consumer.on(eventName, listener); }
Sorry, something went wrong.
Would you mind create a PR for the proposal? I don't mind taking a look and adding it.
feat: add on consumer method
1efcc6e
Closes Consumer inside KafkaPubSub class is private tomasAlabes#26
No branches or pull requests
The consumer inside the KafkaPubSub class is private.
I need to access it in order to register it to some emitted events like "consumer.stop" or "consumer.crash".
Can you please provide a solution for this?
Maybe a public method inside the KafkaPubSub class that allows registering events to the created consumer could be a solution?
Thanks!
The text was updated successfully, but these errors were encountered: