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

feat: persist and clean upgrade intent msg, ratelimit, and API #52

Merged
merged 1 commit into from
Aug 24, 2023

Conversation

hopeyen
Copy link
Collaborator

@hopeyen hopeyen commented Aug 18, 2023

Description

  • Persist a HashMap of upgrade intent messages - require unique subgraph id
  • When operator receives an ui msg, check the hashmap for the subgraph id
    • if there's no existing record, add msg to the hashmap and offchain sync
    • if there's existing record, check for the existing nonce. Do nothing if there has been a recent upgrade, otherwise replace the old message and offchain sync
  • Added Http service with optional subgraph_id filter
  • No explicit cleaning as only 1 message per topic is permitted

Issue link (if applicable)

Resolves #25
Resolves #40

Checklist

  • Are tests up-to-date with the new changes?
  • Are docs up-to-date with the new changes? (Open PR on docs repo if necessary)

@hopeyen hopeyen added the p1 High priority label Aug 18, 2023
@hopeyen hopeyen requested a review from petkodes August 18, 2023 15:09
@hopeyen hopeyen self-assigned this Aug 18, 2023
@hopeyen hopeyen force-pushed the hope/persist-upgrade-intent-msg branch 3 times, most recently from 76ba57c to 8b74fd1 Compare August 23, 2023 19:00
chriswessels
chriswessels previously approved these changes Aug 23, 2023
@hopeyen hopeyen added size:medium Medium type:feature New or enhanced functionality labels Aug 24, 2023
@hopeyen hopeyen merged commit e9a3897 into dev Aug 24, 2023
7 checks passed
@hopeyen hopeyen deleted the hope/persist-upgrade-intent-msg branch August 24, 2023 13:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p1 High priority size:medium Medium type:feature New or enhanced functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feat.Req] Ratelimit subgraph upgrades [Feat.Req] Store, serve, and clean version upgrade messages
2 participants