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

perf: don't handle SitePage nodes when deleting stale nodes #39161

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pieh
Copy link
Contributor

@pieh pieh commented Nov 13, 2024

Description

When we are clearing up stale nodes (nodes that exist from previous build that were not recreated in current build), we are deleting all SitePage nodes because at this point in time site creation didn't run yet. This results in mass nodes deletion and subsequent mass node creation - other than being wasteful this tends to lead to increase in LMDB datastore file size increasing as managing disk size is not priority for it so it tends to allocate more and more space over time with data mutations even if "logical" data remains at similar volume. This PR mainly looks to avoid wasteful LMDB operations and thus trying to slow down LMDB filesize increases over time

Documentation

Tests

Related Issues

@gatsbot gatsbot bot added the status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer label Nov 13, 2024
@pieh pieh added topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine) and removed status: triage needed Issue or pull request that need to be triaged and assigned to a reviewer labels Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: core Relates to Gatsby's core (e.g. page loading, reporter, state machine)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant