You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Account data provider should be implemented as part of the new WebSocket pub/sub system based on the [Draft design of new WebSockets] (#6508).
Requirements:
Account data provider constructors should be implemented. The constructor should create a corresponding subscription.Subscription based on input arguments, and store topic, subscription and other necessary parameters in a newly created instance. These constructors should be called in a DataProviderFactory::NewDataProvider method.
Run should be implemented. It will start in a forever loop until the subscription is closed. This method collects streaming data from the subscription, similar to how we do it, for example in SubscribeAccountStatusesFromStartBlockID:
Guitarheroua
changed the title
[Access] Add implementation AccountSubscriptionHandler for account subscriptions
[Access] Add implementation for accounts data providers
Nov 12, 2024
Account data provider should be implemented as part of the new WebSocket pub/sub system based on the [Draft design of new WebSockets] (#6508).
Requirements:
Account data provider constructors should be implemented. The constructor should create a corresponding
subscription.Subscription
based on input arguments, and storetopic
,subscription
and other necessary parameters in a newly created instance. These constructors should be called in aDataProviderFactory::NewDataProvider
method.Run
should be implemented. It will start in a forever loop until the subscription is closed. This method collects streaming data from the subscription, similar to how we do it, for example inSubscribeAccountStatusesFromStartBlockID
:flow-go/engine/access/state_stream/backend/handler.go
Lines 518 to 544 in 3496c0f
Then the data is formatted in response messages for the client and written to the
send
callback.Also,
MessageIndex
should be included in the response.The
Close
method should be implemented to gracefully shut down the subscription.ID
andTopic
getters should returnUUID
and the topic respectively.The text was updated successfully, but these errors were encountered: