Halleyx Inc.
Original Message:
Sent: Dec 18, 2023 03:33
From: Bryn Langdown
Subject: sample implementation code for TMF622 - connect ECONNREFUSED 127.0.0.1:27017
Hi Ragavi,
Wow, thank you for your really quick reply! Unfortunately I've only been working with the sample implementation code for a shore time so I'm not to sure how to make theses changes.
Cheers Bryn
------------------------------
Bryn Langdown
Aussie Broadband Limited
Original Message:
Sent: Dec 18, 2023 02:53
From: Ragavi Ramasamy
Subject: sample implementation code for TMF622 - connect ECONNREFUSED 127.0.0.1:27017
Hello Bryn,
Ensure Swagger UI accessibility in the development environment by either modifying the environment to "dev" or adjusting the application middleware conditions. Consider removing the Swagger middleware from conditional checks to streamline access during development.
------------------------------
Ragavi Ramasamy
Halleyx Inc.
Original Message:
Sent: Dec 18, 2023 01:47
From: Bryn Langdown
Subject: sample implementation code for TMF622 - connect ECONNREFUSED 127.0.0.1:27017
Hello There,
I am attempting to get sample implementation code for TMF622 running in a Docker container on my local Windows PC.
I have created a docker-compose file with the following entries.
version: '3.9'
services:
mongo:
image: mongo:latest
container_name: mongo
environment:
MONGO_INITDB_ROOT_USERNAME: mongodb
MONGO_INITDB_ROOT_PASSWORD: mongodb
ports: ['27017:27017']
volumes: ['tmf:/data/db']
tmf622:
build: .
image: tmforumorg/api-productorderingmanagement_tmf-622:5.0.0
container_name: product
ports: ['8622:8622']
stdin_open: true
tty: true
environment:
- dbhost=mongo
- dbport=27017
volumes:
tmf: {}
I have run,
docker build .
docker compose up
Everything seems to be running smoothly, I can get to the URL's and can see the swagger page, I can get to the DB via MongoCompass, but when I try to run create product example in swagger I get the following error.
2023-12-18 16:17:47 product | info: Service::serve: POST createProductOrder
2023-12-18 16:17:47 product | info: Service::create: createProductOrder ProductOrder
2023-12-18 16:17:47 product | info: ... replace requestedCompletionDate with native Date type
2023-12-18 16:17:47 product | info: ... replace requestedStartDate with native Date type
2023-12-18 16:17:47 product | info: ... replace date with native Date type
2023-12-18 16:17:47 product | info: ... processMissingProperties: ProductOrder
2023-12-18 16:17:47 product | info: populateMandatoryAttributes: type=ProductOrder
2023-12-18 16:17:47 product | info: ... processExcludedInPost: ProductOrder ProductOrder_Create
2023-12-18 16:17:47 product | info: ... processExcludedInPost: undefined not found
2023-12-18 16:18:17 product | info: mongo::connect err=MongoServerSelectionError: connect ECONNREFUSED 127.0.0.1:27017
2023-12-18 16:18:17 product | info: mongo::create error=MongoServerSelectionError: connect ECONNREFUSED 127.0.0.1:27017
2023-12-18 16:18:17 product | info: handleRequest:: error={
2023-12-18 16:18:17 product | "error": {
2023-12-18 16:18:17 product | "code": "1",
2023-12-18 16:18:17 product | "reason": "Internal database error",
2023-12-18 16:18:17 product | "message": "Internal Server Error"
2023-12-18 16:18:17 product | },
2023-12-18 16:18:17 product | "code": 500
2023-12-18 16:18:17 product | }
Regards Bryn
------------------------------
Bryn Langdown
Aussie Broadband Limited
------------------------------