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

prune old contract subscriptions #490

Open
boudra opened this issue Mar 14, 2024 · 0 comments
Open

prune old contract subscriptions #490

boudra opened this issue Mar 14, 2024 · 0 comments

Comments

@boudra
Copy link
Contributor

boudra commented Mar 14, 2024

at the moment we keep all contracts we subscribe to, which means the getLogs call grows larger and larger without limits

we have a contract pruner src/contractSubscriptionPruner.ts that deletes contracts after X days, this doesn't work for all rounds, as some rounds might run longer than that, so it's disabled at the moment

i think we should use the business logic of rounds to our advantage, some ideas:

  • we can assign a default reasonable TTL of 6 months to rounds?
  • when a round is paid out, we can immediately unsubscribe
  • if a QF round doesn't have votes in weeks, we can unsuscribe
@boudra boudra changed the title redesign contract pruner prune old contract subscriptions May 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant