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.
Pull Request Description
This PR addresses the following requirements:
CRUD Endpoints for Images: Implemented endpoints for uploading, retrieving, and deleting image files, facilitating their management.
Thumbnail Generation: Upon uploading an image, two thumbnails of 60x60 and 120x120 pixels are automatically generated for use in different contexts.
Mock Authentication: Created a mock authentication guard that logs who uploaded the files and when, storing this information in the
File
entity in PostgreSQL.Caching with Redis: Implemented caching using Redis, improving performance by reducing access time to stored images.
Environment Variable Validation: Added validations to ensure that environment variable configurations are correct, thereby ensuring the stability of the service.
Separation of Firebase Logic: Reorganized the code to decouple the logic for interacting with Firebase, resulting in a cleaner and more maintainable design.
Documentation with Swagger: All endpoints are documented using the Swagger module provided by NestJS, allowing for a more intuitive understanding and use.
Automated Tests: Implemented automated tests
Automatic Migration with TypeORM: Automatically generated a migration file using the commands
npm run migration:generate
andnpm run migration:run
.Best regards.