Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

kafka-node

Package Overview
Dependencies
Maintainers
3
Versions
113
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kafka-node - npm Package Compare versions

Comparing version 1.0.5 to 1.0.6

3

CHANGELOG.md
# kafka-node CHANGELOG
## 2016-11-15, Version 1.0.6
- Fix leave group exception that can occur in [Consumer Group](https://github.com/SOHU-Co/kafka-node#consumergroup) [#513](https://github.com/SOHU-Co/kafka-node/pull/513)
## 2016-11-03, Version 1.0.5

@@ -4,0 +7,0 @@ - Update doc added how to list all topics [#503](https://github.com/SOHU-Co/kafka-node/pull/503)

2

lib/consumerGroup.js

@@ -401,3 +401,3 @@ 'use strict';

this.stopHeartbeats();
if (self.generationId != null) {
if (self.generationId != null && self.memberId) {
this.client.sendLeaveGroupRequest(this.options.groupId, this.memberId, function (error) {

@@ -404,0 +404,0 @@ self.generationId = null;

@@ -12,3 +12,3 @@ {

"bugs": "https://github.com/SOHU-co/kafka-node/issues",
"version": "1.0.5",
"version": "1.0.6",
"main": "kafka.js",

@@ -15,0 +15,0 @@ "license": "MIT",

@@ -101,2 +101,33 @@ 'use strict';

describe('#close', function () {
let sandbox, consumerGroup;
beforeEach(function () {
sandbox = sinon.sandbox.create();
consumerGroup = new ConsumerGroup({
host: host,
connectOnReady: false,
sessionTimeout: 8000,
heartbeatInterval: 250,
retryMinTimeout: 250
}, 'TestTopic');
});
afterEach(function () {
sandbox.restore();
});
it('should not throw an exception when closing immediately after an UnknownMemberId error', function (done) {
const UnknownMemberId = require('../lib/errors/UnknownMemberIdError');
sandbox.stub(consumerGroup.client, 'sendHeartbeatRequest').yields(new UnknownMemberId('test'));
should.doesNotThrow(function () {
consumerGroup.connect();
consumerGroup.once('connect', function () {
consumerGroup.close(done);
});
});
});
});
describe('#sendHeartbeats', function () {

@@ -103,0 +134,0 @@ var consumerGroup, sandbox;

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