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: refresh the pool when connecting #1618

Conversation

wadeking98
Copy link
Contributor

Previously AFJ wouldn't call refresh on genesis files, this meant that the pool could be out of date and contain dead nodes. This change makes AFJ refresh the pool when connecting to it, to ensure the pool stays up to date

@wadeking98 wadeking98 requested a review from a team as a code owner October 30, 2023 20:56
Signed-off-by: wadeking98 <wkingnumber2@gmail.com>
@codecov-commenter
Copy link

codecov-commenter commented Oct 30, 2023

Codecov Report

Merging #1618 (ff2c353) into main (b2ba7c7) will decrease coverage by 6.93%.
Report is 1 commits behind head on main.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #1618      +/-   ##
==========================================
- Coverage   85.67%   78.74%   -6.93%     
==========================================
  Files         951      918      -33     
  Lines       22892    22300     -592     
  Branches     4024     3935      -89     
==========================================
- Hits        19613    17561    -2052     
- Misses       3095     4415    +1320     
- Partials      184      324     +140     
Files Coverage Δ
packages/indy-vdr/src/pool/IndyVdrPool.ts 86.88% <100.00%> (+0.21%) ⬆️

... and 188 files with indirect coverage changes

Signed-off-by: Ariel Gentile <gentilester@gmail.com>
Copy link
Contributor

@TimoGlastra TimoGlastra left a comment

Choose a reason for hiding this comment

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

I'm curious how this improves performance. As it won't store the updated genesis files, it will need to do this on every startup right?

@wadeking98
Copy link
Contributor Author

I'm curious how this improves performance. As it won't store the updated genesis files, it will need to do this on every startup right?

Yes, it will need to do this on every startup. I was thinking I could create some method pool.update() or something that would return the transactions but I couldn't figure out how to expose a method from the pool service to something using the agent

@wadeking98
Copy link
Contributor Author

I've actually made an improvement on this here: #1623

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.

4 participants