diff --git a/client-pool.js b/client-pool.js index d4db5ef..5098afa 100644 --- a/client-pool.js +++ b/client-pool.js @@ -19,6 +19,8 @@ function ClientPool(options) { authKey: this.authKey }; + clientConnectOptions.codecEngine = options.codecEngine || null + this._handleClientError = (event) => { this.emit('error', event); }; diff --git a/cluster-broker-client.js b/cluster-broker-client.js index 4c59303..e6468ce 100644 --- a/cluster-broker-client.js +++ b/cluster-broker-client.js @@ -14,6 +14,7 @@ function ClusterBrokerClient(broker, options) { this.mappingEngine = options.mappingEngine || 'skeletonRendezvous'; this.clientPoolSize = options.clientPoolSize || 1; this.isReady = false; + this.codecEngine = options.codecEngine || null; if (this.mappingEngine === 'skeletonRendezvous') { this.mapper = new SkeletonRendezvousMapper(options.mappingEngineOptions); @@ -67,7 +68,8 @@ ClusterBrokerClient.prototype.setBrokers = function (sccBrokerURIList) { let clientPool = new ClientPool({ clientCount: this.clientPoolSize, targetURI: clientURI, - authKey: this.authKey + authKey: this.authKey, + codecEngine: this.codecEngine }); brokerClientMap[clientURI] = clientPool; this.sccBrokerClientPools[clientURI] = clientPool; diff --git a/index.js b/index.js index 78ab779..b7f12c7 100644 --- a/index.js +++ b/index.js @@ -17,6 +17,7 @@ module.exports.attach = function (broker, options) { authKey: authKey, mappingEngine: options.mappingEngine, clientPoolSize: options.clientPoolSize, + codecEngine: options.codecEngine, }); let retryDelay = options.brokerRetryDelay || DEFAULT_RETRY_DELAY;