feat(migrations): add initial migration setup and performance indexes

- Introduced .pgmrc.json and migrate.json for node-pg-migrate configuration.
- Added multiple migration files to create performance indexes for tasks and related entities.
- Implemented functions for optimized task sorting and manual progress tracking.
- Updated package.json to include migration scripts and dependencies for node-pg-migrate.
- Created README.md for migration guidelines and best practices.
This commit is contained in:
chamiakJ
2025-07-22 22:06:07 +05:30
parent e3c002b088
commit b105661623
9 changed files with 610 additions and 440 deletions

View File

@@ -25,6 +25,13 @@ CREATE TABLE IF NOT EXISTS pg_sessions (
expire TIMESTAMP(6) NOT NULL
);
-- Create pgmigrations table for node-pg-migrate
CREATE TABLE IF NOT EXISTS pgmigrations (
id SERIAL PRIMARY KEY,
name VARCHAR(255) NOT NULL,
run_on TIMESTAMP WITH TIME ZONE NOT NULL
);
CREATE TABLE IF NOT EXISTS project_access_levels (
id UUID DEFAULT uuid_generate_v4() NOT NULL,
name TEXT NOT NULL,