Skip to content

Yasix new - #29

Open
Yasith763 wants to merge 75 commits into
mainfrom
yasix-new
Open

Yasix new#29
Yasith763 wants to merge 75 commits into
mainfrom
yasix-new

Conversation

@Yasith763

Copy link
Copy Markdown
Collaborator

No description provided.

Yasith763 and others added 30 commits August 4, 2025 19:11
create backend of catagory and services
migrate entire codebase from JavaScript to TypeScript
refactor: update Dockerfile to install TypeScript and run transpiled …
…on Prisma client pattern and enhancing connection pool configuration

docs: add troubleshooting guide for database connection issues and optimizations implemented

perf: optimize backend performance by implementing caching, response compression, and database indexing

feat: create comprehensive monitoring for connection pool and performance metrics

chore: add tests for connection pool and database performance to ensure stability and efficiency
…th checks

- Added @types/aws-sdk to dependencies for TypeScript support.
- Removed unused quick-db-test.js, performance.middleware.ts, connection-monitor.ts, and related test files.
- Simplified health route by removing unnecessary database stats and connection time logging.
- Updated user.service.ts to improve performance by counting services instead of fetching them.
- Cleaned up database connection logic in database.ts and removed retry logic.
- Removed various test scripts related to admin and connection testing.
- Created a new empty dev.db file for Prisma.
indunil-k and others added 29 commits September 6, 2025 01:25
… reviews by rating, and show rating distribution.
- Created Admin model in Prisma schema with fields: id, username, password, firstName, lastName.
- Implemented admin authentication middleware to protect routes and validate JWT tokens.
- Developed AdminController with methods for registration, login, profile retrieval, and updates.
- Added validation schemas for admin registration, login, and updates using Joi.
- Updated routes to include admin-specific endpoints for registration, login, profile management, and admin listing.
- Created admin service for handling database operations related to admin users.
- Added SQL migration for creating the Admin table in the database.
- Implemented unit tests for user registration, login, profile retrieval, and updates in user.service.test.ts.
- Added integration tests for user authentication and management endpoints in user.test.ts.
- Created a validation script (validate-tests.js) to check the integrity of the test setup and dependencies.
- Included error handling and edge case tests for user registration and login processes.
- Ensured password management and user search functionalities are thoroughly tested.
Upgraded @aws-sdk/client-s3 and related AWS SDK packages to ^3.896.0, updated express-rate-limit, and added socket.io and @types/socket.io to dependencies for improved real-time communication support.
Changed the JWT token expiration for admin users from 24 hours to 1 hour to enhance security by limiting token validity.
Moved all admin-related controllers, middlewares, routes, services, and validators into a new 'Admin' directory for better organization. Updated import paths throughout the codebase to reflect the new structure.
Introduced a new controller method, service function, and route to allow admins to retrieve a list of all customers. The endpoint returns customer details along with related counts and is protected by admin authentication middleware.
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.

3 participants