Merged
Conversation
Replace POSTGRES_/DATABASE_URL usage with DB_USER/DB_PASSWORD/DB_NAME/DB_URL across docs, docker-compose files, and scripts. Load .env.dev in drizzle.config and construct the DB URL from DB_* variables. Add Drizzle meta snapshot and journal files.
Co-authored-by: mathieusouflis <39670015+mathieusouflis@users.noreply.github.com>
Move Drizzle schema into modules/tape and export via modules/index.schemas Introduce PostgresClient and new TapeRepository under modules/tape Update drizzle.config to point to ./src/modules/index.schemas.ts Remove legacy database client/index/repository infra files Add TS path alias @/* in backend tsconfig
- Reorganize codebase into module-based structure (src/modules/tape/) - Move tape domain, application, and infrastructure into tape module - Update routes to use plugin-based architecture - Update database client and repository implementations
# Conflicts: # apps/backend/TESTING.md # apps/backend/package.json # apps/backend/src/index.ts # apps/backend/src/infrastructure/database/schema.ts
Replace POSTGRES_/DATABASE_URL usage with DB_USER/DB_PASSWORD/DB_NAME/DB_URL across docs, docker-compose files, and scripts. Load .env.dev in drizzle.config and construct the DB URL from DB_* variables. Add Drizzle meta snapshot and journal files.
Co-authored-by: mathieusouflis <39670015+mathieusouflis@users.noreply.github.com>
Move Drizzle schema into modules/tape and export via modules/index.schemas Introduce PostgresClient and new TapeRepository under modules/tape Update drizzle.config to point to ./src/modules/index.schemas.ts Remove legacy database client/index/repository infra files Add TS path alias @/* in backend tsconfig
- Reorganize codebase into module-based structure (src/modules/tape/) - Move tape domain, application, and infrastructure into tape module - Update routes to use plugin-based architecture - Update database client and repository implementations
- Recreate infrastructure/database/index.ts with findById method and createDatabaseClient - Fix index.ts to properly initialize fastify server - Add adapter for TapeRepository to support both old and new API - Fix repository-mocks.ts import
…ouflis/turing-app-clean-architecture into fix/backend-modules-application # Conflicts: # apps/backend/package.json # apps/backend/src/infrastructure/database/index.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix: Backend Modules Application Structure
Problem
The backend application layer had an inconsistent structure with controllers and use cases scattered across different directories, making it difficult to maintain and follow clean architecture principles.
Solution
Refactored the backend to use a modular structure where each domain (e.g.,
tape) contains its own application layer with controllers, following a more organized and maintainable architecture.Changes
modules/tape/application/)TapeControllerclassImpact