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

nats

Package Overview
Dependencies
Maintainers
2
Versions
195
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nats - npm Package Compare versions

Comparing version 0.7.16 to 0.7.18

33

lib/nats.js

@@ -26,3 +26,3 @@ /*!

var VERSION = '0.7.16',
var VERSION = '0.7.18',

@@ -486,3 +486,4 @@ DEFAULT_PORT = 4222,

'verbose' : this.options.verbose,
'pedantic': this.options.pedantic
'pedantic': this.options.pedantic,
'protocol': 1,
};

@@ -499,3 +500,2 @@ if (this.user !== undefined) {

}
// If we enqueued requests before we received INFO from the server, or we

@@ -803,2 +803,29 @@ // reconnected, there be other data pending, write this immediately instead

}
// Always try to read the connect_urls from info
if(client.info.connect_urls && client.info.connect_urls.length > 0) {
// don't add duplicates
var known = [];
client.servers.forEach(function(server) {
known.push(server.url.href);
});
// add new ones
var toAdd = [];
client.info.connect_urls.forEach(function(server) {
var u = 'nats://' + server;
if(known.indexOf(u) === -1) {
toAdd.push(new Server(url.parse(u)));
}
});
if(toAdd.length > 0) {
if(client.options.noRandomize !== true) {
shuffle(toAdd);
}
toAdd.forEach(function(s) {
client.servers.push(s);
});
}
}
// Process first INFO

@@ -805,0 +832,0 @@ if (client.infoReceived === false) {

2

package.json
{
"name": "nats",
"version": "0.7.16",
"version": "0.7.18",
"description": "Node.js client for NATS, a lightweight, high-performance cloud native messaging system",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

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