Documentation ¶
Index ¶
- func GetOffchainUpdatesV1(offchainUpdates *clobtypes.OffchainUpdates) ([]ocutypes.OffChainUpdateV1, error)
- type GrpcStreamingManagerImpl
- func (sm *GrpcStreamingManagerImpl) Enabled() bool
- func (sm *GrpcStreamingManagerImpl) GetUninitializedClobPairIds() []uint32
- func (sm *GrpcStreamingManagerImpl) SendOrderbookUpdates(offchainUpdates *clobtypes.OffchainUpdates, snapshot bool, blockHeight uint32, ...)
- func (sm *GrpcStreamingManagerImpl) Subscribe(req clobtypes.StreamOrderbookUpdatesRequest, ...) (err error)
- type NoopGrpcStreamingManager
- func (sm *NoopGrpcStreamingManager) Enabled() bool
- func (sm *NoopGrpcStreamingManager) GetUninitializedClobPairIds() []uint32
- func (sm *NoopGrpcStreamingManager) SendOrderbookUpdates(updates *clobtypes.OffchainUpdates, snapshot bool, blockHeight uint32, ...)
- func (sm *NoopGrpcStreamingManager) Subscribe(req clobtypes.StreamOrderbookUpdatesRequest, ...) (err error)
- type OrderbookSubscription
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetOffchainUpdatesV1 ¶
func GetOffchainUpdatesV1(offchainUpdates *clobtypes.OffchainUpdates) ([]ocutypes.OffChainUpdateV1, error)
GetOffchainUpdatesV1 unmarshals messages in offchain updates to OffchainUpdateV1.
Types ¶
type GrpcStreamingManagerImpl ¶
GrpcStreamingManagerImpl is an implementation for managing gRPC streaming subscriptions.
func NewGrpcStreamingManager ¶
func NewGrpcStreamingManager() *GrpcStreamingManagerImpl
func (*GrpcStreamingManagerImpl) Enabled ¶
func (sm *GrpcStreamingManagerImpl) Enabled() bool
func (*GrpcStreamingManagerImpl) GetUninitializedClobPairIds ¶
func (sm *GrpcStreamingManagerImpl) GetUninitializedClobPairIds() []uint32
GetUninitializedClobPairIds returns the clob pair ids that have not been initialized.
func (*GrpcStreamingManagerImpl) SendOrderbookUpdates ¶
func (sm *GrpcStreamingManagerImpl) SendOrderbookUpdates( offchainUpdates *clobtypes.OffchainUpdates, snapshot bool, blockHeight uint32, execMode sdk.ExecMode, )
SendOrderbookUpdates groups updates by their clob pair ids and sends messages to the subscribers.
func (*GrpcStreamingManagerImpl) Subscribe ¶
func (sm *GrpcStreamingManagerImpl) Subscribe( req clobtypes.StreamOrderbookUpdatesRequest, srv clobtypes.Query_StreamOrderbookUpdatesServer, ) ( err error, )
Subscribe subscribes to the orderbook updates stream.
type NoopGrpcStreamingManager ¶
type NoopGrpcStreamingManager struct{}
func NewNoopGrpcStreamingManager ¶
func NewNoopGrpcStreamingManager() *NoopGrpcStreamingManager
func (*NoopGrpcStreamingManager) Enabled ¶
func (sm *NoopGrpcStreamingManager) Enabled() bool
func (*NoopGrpcStreamingManager) GetUninitializedClobPairIds ¶
func (sm *NoopGrpcStreamingManager) GetUninitializedClobPairIds() []uint32
func (*NoopGrpcStreamingManager) SendOrderbookUpdates ¶
func (sm *NoopGrpcStreamingManager) SendOrderbookUpdates( updates *clobtypes.OffchainUpdates, snapshot bool, blockHeight uint32, execMode sdk.ExecMode, )
func (*NoopGrpcStreamingManager) Subscribe ¶
func (sm *NoopGrpcStreamingManager) Subscribe( req clobtypes.StreamOrderbookUpdatesRequest, srv clobtypes.Query_StreamOrderbookUpdatesServer, ) ( err error, )
type OrderbookSubscription ¶
type OrderbookSubscription struct {
// contains filtered or unexported fields
}
OrderbookSubscription represents a active subscription to the orderbook updates stream.
Click to show internal directories.
Click to hide internal directories.