Skip to content
This repository has been archived by the owner on May 28, 2021. It is now read-only.

[watcher] performance concerns & final wrap up #1412

Open
bohendo opened this issue Aug 31, 2020 · 0 comments
Open

[watcher] performance concerns & final wrap up #1412

bohendo opened this issue Aug 31, 2020 · 0 comments
Labels
Chore Devops or refactoring task p3: Features/refactors Larger enhancements driven by user needs + Refactors to improve bad patterns.

Comments

@bohendo
Copy link
Contributor

bohendo commented Aug 31, 2020

Before we turn the watcher on in prod, 2 potential performance issues should be addresses

  1. Currently watcher stores all StateProgressed and ChallengeUpdated events emitted from the watched ChallengeRegistries. We really ought to filter those out so that we only store the events that are relevant to our publicIdentifier's channels' apps.
  2. We should save the block number as lastProcessedBlock in the store at the point where we run the setup protocol & wait to start the watcher until setup finishes. We're currently starting to download event logs from the block where our challenger registry got deployed so, that's a lot of blocks to scan.

Once these ^ are done & watcher tests in modules/node/src/test/e2e/challenge.spec.ts are passing, we can re-activate the watchers by passing in the chain providers instead of an empty object in:

  • modules/client/src/connect.ts
  • modules/node/src/challenge/challenge.service.ts
@bohendo bohendo added Needs Triage Needs to be looked at and prioritized. Chore Devops or refactoring task p3: Features/refactors Larger enhancements driven by user needs + Refactors to improve bad patterns. and removed Needs Triage Needs to be looked at and prioritized. labels Aug 31, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Chore Devops or refactoring task p3: Features/refactors Larger enhancements driven by user needs + Refactors to improve bad patterns.
Projects
None yet
Development

No branches or pull requests

1 participant