Skip to content

feat: add database indexes to automation-action entity (#1232) - #1375

Open
Whiznificent wants to merge 2 commits into
rinafcode:mainfrom
Whiznificent:feat/add-automation-action-indexes
Open

feat: add database indexes to automation-action entity (#1232)#1375
Whiznificent wants to merge 2 commits into
rinafcode:mainfrom
Whiznificent:feat/add-automation-action-indexes

Conversation

@Whiznificent

Copy link
Copy Markdown

Add @Index decorators to AutomationAction entity for commonly queried columns:

  • workflowId (single): speeds up foreign key lookups / CASCADE deletes
  • type (single): speeds up filtering actions by type
  • order (single): speeds up ORDER BY order queries
  • deletedAt (single): speeds up soft-delete aware queries
  • workflowId + order (composite): optimised ordered action fetch per workflow
  • workflowId + type (composite): optimised type-filter per workflow

Add migration 1800000000001-add-automation-action-indexes.ts with idempotent CREATE INDEX IF NOT EXISTS / DROP INDEX IF EXISTS statements.

Closes #1232

Add @Index decorators to AutomationAction entity for commonly queried columns:
- workflowId (single): speeds up foreign key lookups / CASCADE deletes
- type (single): speeds up filtering actions by type
- order (single): speeds up ORDER BY order queries
- deletedAt (single): speeds up soft-delete aware queries
- workflowId + order (composite): optimised ordered action fetch per workflow
- workflowId + type (composite): optimised type-filter per workflow

Add migration 1800000000001-add-automation-action-indexes.ts with idempotent
CREATE INDEX IF NOT EXISTS / DROP INDEX IF EXISTS statements.

Closes rinafcode#1232
@drips-wave

drips-wave Bot commented Aug 29, 2026

Copy link
Copy Markdown

@Whiznificent 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

@RUKAYAT-CODER

Copy link
Copy Markdown
Contributor

Well done on the job done so far!
Kindly fix workflow to pass

@Whiznificent

Copy link
Copy Markdown
Author

sorry for the dely i will work on it soon

@Whiznificent

Copy link
Copy Markdown
Author

all done please merege

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.

Add database indexes to the automation-action entity

2 participants