New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

kafka-observe

Package Overview
Dependencies
Maintainers
1
Versions
130
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kafka-observe - npm Package Compare versions

Comparing version 2.0.4 to 2.0.5

2

index.js

@@ -102,3 +102,3 @@ const { Consumer, ConsumerGroup, Producer } = require("./IO");

*/
callback: callbackController({ producer, consumer }),
eventCallback: callbackController({ producer, consumer }),
};

@@ -105,0 +105,0 @@

{
"name": "kafka-observe",
"version": "2.0.4",
"version": "2.0.5",
"description": "",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -57,3 +57,4 @@ # kafka-observe

`producer`: instance of a connected producer
`getTopicSubject`: a function that returns a topic to subscribe to with the correct strategy.
`getTopicSubject`: a function that returns a topic to subscribe to with the correct strategy.
`eventCallback`: a function that sends out an event and listens for a response

@@ -67,3 +68,3 @@ ## getTopicSubject

getTopicSubject.getTopicSubject({
getTopicSubject({
topic: "topic name",

@@ -76,2 +77,19 @@ loadBalanced: "true|false", // True for Loadbalanced strategy false for All strategy

## eventCallback
Returns a subject you can subscribe to listen to events of a certain topic.
```javascript
const { eventCallback } = require("kafka-observe")(options);
eventCallback({
topic: "topic name",
sender: "event",
listeners: ["listen_for_event"],
payload: {} // An object you want send with the event (needs to be JSON convertable)
}).then((event) => {
// do something with the event
});
```
## producer

@@ -78,0 +96,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc