-
Notifications
You must be signed in to change notification settings - Fork 179
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
[Access] Add implementation for transaction statuses data providers #6818
base: master
Are you sure you want to change the base?
[Access] Add implementation for transaction statuses data providers #6818
Conversation
…:The-K-R-O-K/flow-go into AndriiDiachuk/6588-events-data-provider
…:The-K-R-O-K/flow-go into AndriiDiachuk/6588-events-data-provider
…:The-K-R-O-K/flow-go into AndriiDiachuk/6588-events-data-provider
…:The-K-R-O-K/flow-go into AndriiDiachuk/6588-events-data-provider
…The-K-R-O-K/flow-go into AndriiDiachuk/6587-accounts-data-provider
…The-K-R-O-K/flow-go into AndriiDiachuk/6587-accounts-data-provider
…:The-K-R-O-K/flow-go into AndriiDiachuk/6588-events-data-provider
…:The-K-R-O-K/flow-go into AndriiDiachuk/6588-events-data-provider
…' of github.com:The-K-R-O-K/flow-go into AndriiDiachuk/6586-tx-statuses-data-providers-impl
…achuk/6588-events-data-provider
…github.com:The-K-R-O-K/flow-go into AndriiDiachuk/6586-tx-statuses-data-providers-impl
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #6818 +/- ##
==========================================
+ Coverage 40.96% 41.06% +0.09%
==========================================
Files 2093 2097 +4
Lines 184478 184956 +478
==========================================
+ Hits 75577 75950 +373
- Misses 102579 102633 +54
- Partials 6322 6373 +51
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
s.Require().NotNil(s.factory) | ||
} | ||
|
||
func (s *TransactionStatusesProviderSuite) TestTransactionStatusesDataProvider_HappyPath() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add godoc here
serverAPI, | ||
chain, | ||
stateStreamConfig.EventFilterConfig, | ||
stateStreamConfig.HeartbeatInterval) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
stateStreamConfig.HeartbeatInterval) | |
stateStreamConfig.HeartbeatInterval, | |
) |
StartBlockHeight uint64 // Height of the block to start subscription from | ||
} | ||
|
||
type TransactionStatusesDataProvider struct { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add please a few words (godoc) for this provider?
// handleResponse processes an account statuses and sends the formatted response. | ||
// | ||
// No errors are expected during normal operations. | ||
func (p *TransactionStatusesDataProvider) handleResponse() func(txResults []*access.TransactionResult) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use generic HandleResponse
from subscription
in Run()
and get rid of handleResponse()
?
Closes: #6586
In this PR
TransactionStatusesDataProvider
was implemented.New functionality was covered with tests.