Skip to content

Add snapshot version tracking and improve logging#7233

Merged
davidfowl merged 7 commits intomainfrom
davidfowl/use-snapshot-ids
Jan 24, 2025
Merged

Add snapshot version tracking and improve logging#7233
davidfowl merged 7 commits intomainfrom
davidfowl/use-snapshot-ids

Conversation

@davidfowl
Copy link
Copy Markdown
Contributor

  • Introduced a new Id property in CustomResourceSnapshot for unique identification of snapshots.
  • Updated WatchAsync to filter resource events based on the maximum snapshot ID.
  • Modified PublishUpdateAsync to increment the snapshot ID for new states.
  • Enhanced logging in PublishUpdateAsync to include the new snapshot ID for better traceability.

- Introduced a new `Id` property in `CustomResourceSnapshot` for unique identification of snapshots.
- Updated `WatchAsync` to filter resource events based on the maximum snapshot ID.
- Modified `PublishUpdateAsync` to increment the snapshot ID for new states.
- Enhanced logging in `PublishUpdateAsync` to include the new snapshot ID for better traceability.
Comment thread src/Aspire.Hosting/ApplicationModel/ResourceNotificationService.cs Outdated
Comment thread src/Aspire.Hosting/ApplicationModel/ResourceNotificationService.cs Outdated
Comment thread src/Aspire.Hosting/ApplicationModel/CustomResourceSnapshot.cs Outdated
@davidfowl davidfowl changed the title Add snapshot ID tracking and improve logging Add snapshot version tracking and improve logging Jan 24, 2025
Copy link
Copy Markdown
Member

@JamesNK JamesNK left a comment

Choose a reason for hiding this comment

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

I think this is ok.

I think we should consider having some kind of stress test for the notification service that blasts it with load in various situations and verifies it still works. Doesn't need to happen now.

Comment thread src/Aspire.Hosting/ApplicationModel/ResourceNotificationService.cs
Comment thread src/Aspire.Hosting/ApplicationModel/ResourceNotificationService.cs Outdated
@davidfowl davidfowl merged commit 36ba678 into main Jan 24, 2025
@davidfowl davidfowl deleted the davidfowl/use-snapshot-ids branch January 24, 2025 08:12
@github-actions github-actions Bot locked and limited conversation to collaborators Feb 23, 2025
@github-actions github-actions Bot added the area-app-model Issues pertaining to the APIs in Aspire.Hosting, e.g. DistributedApplication label Mar 10, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-app-model Issues pertaining to the APIs in Aspire.Hosting, e.g. DistributedApplication

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants