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

Cache network settings #251

Conversation

smallhive
Copy link
Contributor

Closes #247.

Copy link

codecov bot commented Oct 22, 2024

Codecov Report

Attention: Patch coverage is 35.71429% with 36 lines in your changes missing coverage. Please review.

Project coverage is 23.61%. Comparing base (02e0776) to head (309119b).
Report is 7 commits behind head on master.

Files with missing lines Patch % Lines
handlers/auth.go 0.00% 10 Missing ⚠️
handlers/containers.go 0.00% 9 Missing ⚠️
internal/cache/networkinfo.go 74.07% 6 Missing and 1 partial ⚠️
handlers/util.go 0.00% 4 Missing ⚠️
handlers/network.go 0.00% 2 Missing ⚠️
handlers/objects.go 0.00% 2 Missing ⚠️
handlers/api.go 0.00% 1 Missing ⚠️
handlers/newObjects.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #251      +/-   ##
==========================================
+ Coverage   22.79%   23.61%   +0.81%     
==========================================
  Files          18       19       +1     
  Lines        3672     4731    +1059     
==========================================
+ Hits          837     1117     +280     
- Misses       2677     3455     +778     
- Partials      158      159       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@roman-khimov roman-khimov left a comment

Choose a reason for hiding this comment

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

Do we have any other places where network info is used? Can they reuse this cache?

internal/cache/networkinfo.go Outdated Show resolved Hide resolved
@smallhive smallhive force-pushed the 247-rest-gw-doesnt-take-into-account-updated-network-settings branch from d29fdfe to 6a0bccb Compare October 22, 2024 10:57
@smallhive smallhive force-pushed the 247-rest-gw-doesnt-take-into-account-updated-network-settings branch from 6a0bccb to e1cf560 Compare October 22, 2024 11:27
internal/cache/networkinfo.go Show resolved Hide resolved
internal/cache/networkinfo.go Outdated Show resolved Hide resolved
Copy link
Member

@roman-khimov roman-khimov left a comment

Choose a reason for hiding this comment

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

Please also update getEpochDurations and getCurrentEpoch.

handlers/containers.go Show resolved Hide resolved
@smallhive smallhive force-pushed the 247-rest-gw-doesnt-take-into-account-updated-network-settings branch from e1cf560 to 2b5cecd Compare October 22, 2024 13:26
@roman-khimov
Copy link
Member

In general it's OK, but now some tests fail here: https://rest.fs.neo.org/7ZVSQHtioVRiDT2btN9xEmQhczXV9vryCEAHUawfD8Sc/141-1729604693/index.html#suites/21ade783424f8b7f50534d1bb781c71b/2824020f8d392ae/

@evgeniiz321, is there any forced epoch tick there? Can they be fixed to handle cached epochs?

@roman-khimov roman-khimov merged commit e1b12eb into master Oct 23, 2024
13 of 14 checks passed
@roman-khimov roman-khimov deleted the 247-rest-gw-doesnt-take-into-account-updated-network-settings branch October 23, 2024 09:58
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.

rest gw doesn't take into account updated network settings
2 participants