Skip to content

Comments

feat(nimbus): only log jetstream fetches on new data#14171

Merged
jaredlockhart merged 1 commit intomainfrom
14163
Dec 11, 2025
Merged

feat(nimbus): only log jetstream fetches on new data#14171
jaredlockhart merged 1 commit intomainfrom
14163

Conversation

@jaredlockhart
Copy link
Collaborator

Becuase

  • We recently added changelogs on jetstream fetches to improve visibility on successful or failed jetstream fetches
  • We logged on every fetch attempt, so many unnecessary changelogs were created
  • Large numbers of changelogs can cause pages to load slowly or not at all
  • We only need to log if the data has changed

This commit

  • Deletes all existing jetstream fetch changelogs
  • Updates the logic to only create a changelog if the results data changed

fixes #14163

from django.db import migrations


def delete_results_fetched_changelogs(apps, _schema_editor):
Copy link
Contributor

Choose a reason for hiding this comment

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

This isn't going to clear out all the changelogs whenever the migration gets applied, right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Migrations run only once, so it'll happen once, we'll lose all the jetstream changelogs from the last few weeks, and then start getting filled in from land time forward.

Becuase

* We recently added changelogs on jetstream fetches to improve visibility on successful or failed jetstream fetches
* We logged on every fetch attempt, so many unnecessary changelogs were created
* Large numbers of changelogs can cause pages to load slowly or not at all
* We only need to log if the data has changed

This commit

* Deletes all existing jetstream fetch changelogs
* Updates the logic to only create a changelog if the results data changed

fixes #14163
@jaredlockhart jaredlockhart added this pull request to the merge queue Dec 11, 2025
Merged via the queue into main with commit 943c581 Dec 11, 2025
17 checks passed
@jaredlockhart jaredlockhart deleted the 14163 branch December 11, 2025 22:48
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.

Too many jetstream changelogs

2 participants