Countly / Countly/countly-server

docker compose;no connect Mongodb;ERROR:2024-11-19T02:20:17.982Z: INFO [jobs:manager] Cancelling 0 jobs { MongoNetworkError: failed to connect to server [localhost:27017] on first connect [MongoNetworkError: connect ECONNREFUSED 127.0.0.1:27017]

Open
#5,777 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
5.9k
Forks
981
Avg merge
18h 51m
Merged PRs (30d)
49

Description

2024-11-19T02:20:17.982Z: INFO [jobs:manager] Cancelling 0 jobs { MongoNetworkError: failed to connect to server [localhost:27017] on first connect [MongoNetworkError: connect ECONNREFUSED 127.0.0.1:27017] at Pool. (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/topologies/server.js:431:11) at emitOne (events.js:116:13) at Pool.emit (events.js:211:7) at connect (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/pool.js:557:14) at makeConnection (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connect.js:39:11) at callback (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connect.js:261:5) at Socket.err (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connect.js:286:7) at Object.onceWrapper (events.js:315:30) at emitOne (events.js:116:13) at Socket.emit (events.js:211:7) at emitErrorNT (internal/streams/destroy.js:66:8) at _combinedTickCallback (internal/process/next_tick.js:139:11) at process._tickCallback (internal/process/next_tick.js:181:9) name: 'MongoNetworkError', errorLabels: [ 'TransientTransactionError' ], [Symbol(mongoErrorContextSymbol)]: {} } { MongoNetworkError: failed to connect to server [localhost:27017] on first connect [MongoNetworkError: connect ECONNREFUSED 127.0.0.1:27017] at Pool. (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/topologies/server.js:431:11) at emitOne (events.js:116:13) at Pool.emit (events.js:211:7) at connect (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/pool.js:557:14) at makeConnection (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connect.js:39:11) at callback (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connect.js:261:5) at Socket.err (/opt/countly/node_modules/mongodb/node_modules/mongodb-core/lib/connection/connect.js:286:7) at Object.onceWrapper (events.js:315:30) at emitOne (events.js:116:13) at Socket.emit (events.js:211:7) at emitErrorNT (internal/streams/destroy.js:66:8) at _combinedTickCallback (internal/process/next_tick.js:139:11) at process._tickCallback (internal/process/next_tick.js:181:9) name: 'MongoNetworkError', errorLabels: [ 'TransientTransactionError' ],

This is a problem,i do not handle it

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure with Docker Compose and inspect the MongoDB connection configuration indicated by the ECONNREFUSED localhost:27017 log. Done means the Countly jobs manager connects to MongoDB successfully without the reported network error.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker-compose, javascript, mongodb
Domain
backend, databases, devops
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.