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

Add indexes to available_at and max_visits #122

Merged
merged 1 commit into from
Jan 3, 2025
Merged

Add indexes to available_at and max_visits #122

merged 1 commit into from
Jan 3, 2025

Conversation

cesargb
Copy link
Owner

@cesargb cesargb commented Dec 25, 2024

Add indexes to available_at and max_visits

Reason

The self-cleaning process of the magiclink logs causes latency when the logs do not expire.

see: #120

Caution

Stack migration adding indexes may take 2 or more seconds for a volume of 400,000 records.

Install

composer update cesargb/laravel-magiclink
php artisan vendor:publish --provider="MagicLink\MagicLinkServiceProvider" --tag="migrations"
php artisan migrate

@cesargb cesargb linked an issue Dec 25, 2024 that may be closed by this pull request
@cesargb cesargb changed the title add indexes to available_at and max_visits Add indexes to available_at and max_visits Dec 25, 2024
@cesargb cesargb merged commit b93bbdf into master Jan 3, 2025
26 checks passed
@cesargb cesargb deleted the indexes branch January 3, 2025 16:38
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.

Slow DB Query for deleting the previous magic links
1 participant