Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quoting Service - throwing errors while processing quotes when LOG_LEVEL set to debug #3604

Closed
vijayg10 opened this issue Nov 1, 2023 · 1 comment
Assignees
Labels
bug Something isn't working or it has wrong behavior on a Mojaloop Core service core-dev-squad oss-core This is an issue - story or epic related to a feature on a Mojaloop core service or related to it

Comments

@vijayg10
Copy link

vijayg10 commented Nov 1, 2023

Summary:
When LOG_LEVEL environment variable is set to debug, the quoting service is not able to process the quoting requests. Observed the following errors in the log related to event-sdk.

2023-10-30T15:01:55.510Z - error: "ERROR - POST /quotes: TypeError: Cannot read properties of undefined (reading 'length')\n    at /opt/app/node_modules/@mojaloop/event-sdk/dist/transport/EventLoggingServiceClient.js:27:138\n    at new Promise (<anonymous>)\n    at EventLoggingServiceClient.log (/opt/app/node_modules/@mojaloop/event-sdk/dist/transport/EventLoggingServiceClient.js:19:16)\n    at DefaultSidecarRecorder.record (/opt/app/node_modules/@mojaloop/event-sdk/dist/Recorder.js:86:42)\n    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n    at async Span.recordMessage (/opt/app/node_modules/@mojaloop/event-sdk/dist/Span.js:332:27)\n    at async Span.audit (/opt/app/node_modules/@mojaloop/event-sdk/dist/Span.js:241:22)\n    at async Quotes (/opt/app/src/handlers/quotes.js:86:7)\n    at async OpenAPIBackend.handleRequest (/opt/app/node_modules/openapi-backend/backend.js:215:26)\n    at async exports.Manager.execute (/opt/app/node_modules/@hapi/hapi/lib/toolkit.js:60:28)"

Severity:
Medium

Priority:
Critical

Expected Behavior

  • Quoting service should process the quotes requests even when the log level set to debug

Steps to Reproduce

  1. Set the configuration to the following
    a. Enable event sidecar
    b. Set LOG_LEVEL to debug
  2. Deploy mojaloop helm chart
  3. Run provisioning collection
  4. Make a quotes request and observe the logs in quoting service

Specifications

  • Component (if known): Quoting service
  • Version: v15.4.0
  • Bug found/raised by: @vijayg10 @dfry
@vijayg10 vijayg10 added oss-core This is an issue - story or epic related to a feature on a Mojaloop core service or related to it bug Something isn't working or it has wrong behavior on a Mojaloop Core service core-dev-squad labels Nov 1, 2023
@oderayi oderayi self-assigned this Nov 2, 2023
@elnyry-sam-k
Copy link
Member

marking as high pri , and to be included for v15.2.0

oderayi added a commit to mojaloop/event-sdk that referenced this issue Nov 2, 2023
fix(mojaloop/#3604): fix bug with debug logging - mojaloop/project#3604
- Fix bug with logging when logging level is `debug`
- Add test coverage
@oderayi oderayi closed this as completed Nov 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working or it has wrong behavior on a Mojaloop Core service core-dev-squad oss-core This is an issue - story or epic related to a feature on a Mojaloop core service or related to it
Projects
None yet
Development

No branches or pull requests

3 participants