fix docker-compose files to work with 21.10

fixes to match TCP protocol of 21.10
fixes so that we can gossip on SSL
This commit is contained in:
Nicolas Dextraze
2022-10-22 20:07:01 -04:00
parent aa07b04dd3
commit 5059892bc0
34 changed files with 6741 additions and 6704 deletions

View File

@ -6,6 +6,7 @@ var ensure = require('./common/utils/ensure');
const util = require('util');
const http = require('http');
const https = require('https');
const dns = require('dns');
const dnsService = {
@ -95,13 +96,14 @@ function createFromClusterDns(connectionSettings, clusterDns, externalGossipPort
managerExternalHttpPort: externalGossipPort,
maxDiscoverAttempts: mergedSettings.maxDiscoverAttempts,
discoverDelay: mergedSettings.discoverDelay,
gossipTimeout: mergedSettings.gossipTimeout
gossipTimeout: mergedSettings.gossipTimeout,
rejectUnauthorized: connectionSettings.useSslConnection ? connectionSettings.validateServer : undefined
};
var endPointDiscoverer = new ClusterDiscoverer(
mergedSettings.log,
clusterSettings,
dnsService,
http
connectionSettings.useSslConnection ? https : http
);
return new EventStoreNodeConnection(mergedSettings, clusterSettings, endPointDiscoverer, connectionName);
}
@ -116,13 +118,14 @@ function createFromGossipSeeds(connectionSettings, gossipSeeds, connectionName)
externalGossipPort: 0,
maxDiscoverAttempts: mergedSettings.maxDiscoverAttempts,
discoverDelay: mergedSettings.discoverDelay,
gossipTimeout: mergedSettings.gossipTimeout
gossipTimeout: mergedSettings.gossipTimeout,
rejectUnauthorized: connectionSettings.useSslConnection ? connectionSettings.validateServer : undefined
};
var endPointDiscoverer = new ClusterDiscoverer(
mergedSettings.log,
clusterSettings,
dnsService,
http
connectionSettings.useSslConnection ? https : http
);
return new EventStoreNodeConnection(mergedSettings, clusterSettings, endPointDiscoverer, connectionName);
}
@ -162,4 +165,4 @@ module.exports.create = function(settings, endPointOrGossipSeeds, connectionName
if (typeof endPointOrGossipSeeds === 'object') return createFromTcpEndpoint(settings, endPointOrGossipSeeds, connectionName);
if (typeof endPointOrGossipSeeds === 'string') return createFromStringEndpoint(settings, endPointOrGossipSeeds, connectionName);
throw new TypeError('endPointOrGossipSeeds must be an object, a string or an array.');
};
};