-
Notifications
You must be signed in to change notification settings - Fork 814
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Add WorkflowExecution.started index (#3026)
- Loading branch information
1 parent
5846e46
commit 160d442
Showing
2 changed files
with
30 additions
and
1 deletion.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
keep/api/models/db/migrations/versions/2025-01-14-18-41_416155f25854.py
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
"""Add workflowexecution.started index | ||
Revision ID: 416155f25854 | ||
Revises: 1c117f1accff | ||
Create Date: 2025-01-14 18:41:45.817371 | ||
""" | ||
|
||
from alembic import op | ||
|
||
# revision identifiers, used by Alembic. | ||
revision = "416155f25854" | ||
down_revision = "1c117f1accff" | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade() -> None: | ||
# ### commands auto generated by Alembic - please adjust! ### | ||
|
||
with op.batch_alter_table("workflowexecution", schema=None) as batch_op: | ||
batch_op.create_index( | ||
batch_op.f("ix_workflowexecution_started"), ["started"], unique=False | ||
) | ||
|
||
|
||
def downgrade() -> None: | ||
with op.batch_alter_table("workflowexecution", schema=None) as batch_op: | ||
batch_op.drop_index(batch_op.f("ix_workflowexecution_started")) |
This file contains 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