Skip to content

Setup k8s manifests#112

Open
Obiajulu-gif wants to merge 10 commits intoMissBlue00:mainfrom
Obiajulu-gif:setup_k8s_manifests
Open

Setup k8s manifests#112
Obiajulu-gif wants to merge 10 commits intoMissBlue00:mainfrom
Obiajulu-gif:setup_k8s_manifests

Conversation

@Obiajulu-gif
Copy link
Copy Markdown

This pull request introduces a comprehensive observability and structured logging system to the stellar-pay API service. It adds structured JSON logging with correlation IDs, integrates logging and request context throughout the API, and provides CloudWatch dashboard assets for production monitoring. The changes also include middleware, interceptors, and exception filters to ensure consistent logging and traceability across requests and errors.

Observability and Logging Enhancements:

  • Introduced a structured JSON logger (StructuredLogger) with support for log levels, correlation IDs, and child loggers for contextual logging. Added a test suite for logger behavior. (apps/api/src/observability/logger.ts, apps/api/src/observability/logger.spec.ts) [1] [2]
  • Implemented request context propagation using AsyncLocalStorage, with middleware to generate and attach correlation IDs to each request. (apps/api/src/observability/request-context.ts, apps/api/src/observability/request-context.middleware.ts) [1] [2]
  • Added a global request logging interceptor and an exception filter to log all HTTP requests and unhandled exceptions with structured payloads. (apps/api/src/observability/request-logging.interceptor.ts, apps/api/src/observability/logging-exception.filter.ts) [1] [2]
  • Integrated the logger and request context middleware into the NestJS application bootstrap and module configuration, ensuring all routes benefit from observability features. (apps/api/src/app.module.ts, apps/api/src/main.ts, apps/api/src/observability/index.ts) [1] [2] [3] [4] [5]

Application Logging Integration:

  • Added contextual logging to key controllers and services (AppController, AppService, HealthController, TreasuryController, TreasuryService) to emit structured events for important actions and API endpoints. (apps/api/src/app.controller.ts, apps/api/src/app.service.ts, apps/api/src/health/health.controller.ts, apps/api/src/treasury/treasury.controller.ts, apps/api/src/treasury/treasury.service.ts) [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11]

Documentation and Configuration:

  • Updated documentation to describe observability features and how to deploy CloudWatch dashboards and alarms. (stellar-pay/README.md)
  • Added environment variable examples for log level and CloudWatch integration. (apps/api/.env.example)

These changes significantly improve the API's observability, making it easier to trace requests, debug issues, and monitor production health.

Closes #93

@vercel
Copy link
Copy Markdown

vercel bot commented Mar 24, 2026

@Obiajulu-gif is attempting to deploy a commit to the missblue00's projects Team on Vercel.

A member of the Team first needs to authorize it.

@drips-wave
Copy link
Copy Markdown

drips-wave bot commented Mar 24, 2026

@Obiajulu-gif Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@MissBlue00
Copy link
Copy Markdown
Owner

@Obiajulu-gif the ci/cd checks failed and there are merge conflicts, please resolve

devJaja and others added 6 commits April 1, 2026 13:23
- Happy path: Registration -> Payment -> Confirmation -> Mint
- Error paths: invalid signatures, insufficient balances, rate limits
- Uses Jest and Supertest with real JwtAuthGuard/JwtStrategy
- Install jsonwebtoken as dev dep for test token generation
Adds StellarService to payments-engine for blockchain transfers. Introduces a scheduled worker in the API to process pending redemptions using a mock Repository pattern until Prisma is fully integrated. Closes MissBlue00#20.
@Obiajulu-gif
Copy link
Copy Markdown
Author

@MissBlue00 I have fix the error merge it

@Obiajulu-gif Obiajulu-gif force-pushed the setup_k8s_manifests branch from dc06161 to 3e7a346 Compare April 1, 2026 12:44
@Obiajulu-gif
Copy link
Copy Markdown
Author

Obiajulu-gif commented Apr 1, 2026

@MissBlue00 please merge my code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Set up Kubernetes deployment manifests

5 participants