{ok, Connection} = mongoc:connect({ single, "localhost:27018" }
Result is following:
=ERROR REPORT==== 22-May-2020::16:37:22 ===
** Generic server <0.112.0> terminating
** Last message in was {'EXIT',<0.111.0>,killed}
** When Server state == {state,rsPrimary,"localhost",27018,<0.110.0>,
<0.111.0>,
[{name,m_pool_name},
{register,storage_mongodb_connection_pool},
{pool_size,1},
{max_overflow,1},
{connectTimeoutMS,10000},
{socketTimeoutMS,10000},
{serverSelectionTimeoutMS,30000},
{waitQueueTimeoutMS,10000},
{heartbeatFrequencyMS,10000},
{minHeartbeatFrequencyMS,1000},
{rp_mode,primary}],
[{database,<<"DBName">>},
{login,<<"DBLogin">>},
{password,<<"DBPassword">>}],
undefined,10000,10000,1000,<0.139.0>,1}
** Reason for termination ==
** killed
After first error like shown above there is an endless flow of alike messages with only one difference in first line:
** When Server state == {state,undefined,"localhost",27018,<0.110.0>,
In both cases I can connect to the Mongo using CLI client and Compass clients and they are working fine. That is why login/password/dbName/hosts/ports are correct.
MongoDB Server version is 4.0.15
I tried with locally installed single-node 4.0.18 Server and everything worked well. Issues with cluster deployment only.
Hi,
I'm trying to connect to a ReplicaSet but getting different errors and after all connection failing.
Case number 1: Connecting to the ReplicaSet in K8 cluster. Code to connect:
As a result I see exceptions in the logs pointing to some bad_match error in code:
There is a huge error message, so I can provide other parts if needed.
Case number 2: Connecting MongoDB service from outside K8 cluster.
In this case I'm doing a port forwarding to local host and trying to connect to forwarded port like this:
I also tried
Result is following:
After first error like shown above there is an endless flow of alike messages with only one difference in first line:
In both cases I can connect to the Mongo using CLI client and Compass clients and they are working fine. That is why login/password/dbName/hosts/ports are correct.
MongoDB Server version is 4.0.15
I tried with locally installed single-node 4.0.18 Server and everything worked well. Issues with cluster deployment only.
Please, advice.
Thank you in advance,
Regards, Ivan