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

[subgraph] configurable history pruning #1954

Merged
merged 5 commits into from
Jun 11, 2024
Merged

Conversation

kasparkallas
Copy link
Contributor

@kasparkallas kasparkallas commented Jun 11, 2024

Why?

We want to index subgraphs to Goldsky with less entities created in the database.

How?

To do so, we will indroduce history pruning.

Other

Updated subgraph tooling and spec.

Warning!

If you rely on time-travel queries then this will be a breaking change. Contact us if you need continued access to time-travel queries!

Example of a time-travel query:

{
  challenges(block: { number: 8000000 }) {
    challenger
    outcome
    application {
      id
    }
  }
}

Read more:

- limit the schema deps by what is available on goldsky currently
@kasparkallas kasparkallas requested review from d10r and mmd-afegbua June 11, 2024 10:51
@kasparkallas kasparkallas requested review from hellwolf and a team as code owners June 11, 2024 10:51
Copy link

github-actions bot commented Jun 11, 2024

Changelog Reminder

Reminder to update the CHANGELOG.md for any of the modified packages in this PR.

  • CHANGELOG.md modified
  • Double check before merge

@@ -41,6 +52,7 @@ function main() {
nativeAssetSuperTokenAddress: networkMetadata.nativeTokenWrapper,
constantOutflowNFTAddress: networkMetadata.contractsV1.constantOutflowNFT || ADDRESS_ZERO,
constantInflowNFTAddress: networkMetadata.contractsV1.constantInflowNFT || ADDRESS_ZERO,
indexerHints_prune: vendorHistoryPruning[vendorName] || "never",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

default to "never" (previous behavior)

@kasparkallas kasparkallas enabled auto-merge June 11, 2024 13:46
@kasparkallas kasparkallas added this pull request to the merge queue Jun 11, 2024
Merged via the queue into dev with commit f8b4fe6 Jun 11, 2024
17 of 18 checks passed
@kasparkallas kasparkallas deleted the subgraph-history-pruning branch June 11, 2024 19:31
Copy link

XKCD Comic Relif

Link: https://xkcd.com/1954
https://xkcd.com/1954

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.

2 participants