hazelcast-nodejs-client
hazelcast-nodejs-client copied to clipboard
While config Inputs are invalid, error message is not enough [API-1490]
While configuring the client, if the inputs are invalid such as (use this as it is, do not change anything)
{ network: { hazelcastCloud: { discoveryToken: 'YOUR_DISCOVERY_TOKEN' } }, clusterName: 'YOUR_CLUSTER_NAME' }
, returned error message is
[DefaultLogger] INFO at LifecycleService: HazelcastClient is STARTING [DefaultLogger] INFO at LifecycleService: HazelcastClient is STARTED /PATH-TO-PROJECT/node_modules/hazelcast-client/lib/discovery/HazelcastCloudDiscovery.js:75 for (const value of jsonValue) { ^ TypeError: jsonValue is not iterable at Function.parseResponse (/PATH-TO-PROJECT/node_modules/hazelcast-client/lib/discovery/HazelcastCloudDiscovery.js:75:29) at IncomingMessage.<anonymous> (/PATH-TO-PROJECT/node_modules/hazelcast-client/lib/discovery/HazelcastCloudDiscovery.js:61:58) at IncomingMessage.emit (node:events:539:35) at endReadableNT (node:internal/streams/readable:1345:12) at processTicksAndRejections (node:internal/process/task_queues:83:21)
however there should be a better error message.
Internal Jira issue: API-1490
Fixed by https://github.com/hazelcast/hazelcast-nodejs-client/pull/1349