Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimized activity clean-up query #423

Merged
merged 1 commit into from
Nov 6, 2024

Conversation

martastain
Copy link
Member

@martastain martastain commented Nov 5, 2024

Refactored activity clean-up query, that caused timeouts in the clean-up process. Now it should not.

Testing

  • BACKUP!!!!!!
  • Start ayon
  • Wait a couple of minutes
  • Validate that activities of existing entities weren't deleted

More testing

clean-up does not touch activities that were updated or their parent entities were deleted in last 10 days.

You may therefore:

  • Find an entity with 10 days or older comment
  • Delete that entity
  • Delete related entity.xxxxx.deleted event from the events table
  • Restart the server and wait a couple of minutes
  • In the server log, you should see Deleted {count} orphaned activities from {project_name}

@martastain martastain self-assigned this Nov 5, 2024
@martastain martastain requested review from BigRoy and 64qam November 5, 2024 13:45
@martastain martastain added the type: bug Something isn't working label Nov 5, 2024
@martastain martastain merged commit c0fe6c7 into develop Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant