diff --git a/protocol/app/app.go b/protocol/app/app.go index 9ecc1399bc..69ec1704e7 100644 --- a/protocol/app/app.go +++ b/protocol/app/app.go @@ -458,6 +458,9 @@ func New( if app.SlinkyClient != nil { app.SlinkyClient.Stop() } + if app.GrpcStreamingManager != nil { + app.GrpcStreamingManager.Stop() + } return nil }, ) diff --git a/protocol/streaming/grpc/grpc_streaming_manager.go b/protocol/streaming/grpc/grpc_streaming_manager.go index 25a009f5c8..f976274c71 100644 --- a/protocol/streaming/grpc/grpc_streaming_manager.go +++ b/protocol/streaming/grpc/grpc_streaming_manager.go @@ -72,7 +72,6 @@ func NewGrpcStreamingManager( for { select { case <-grpcStreamingManager.ticker.C: - // fix this with values grpcStreamingManager.FlushStreamUpdates() case <-grpcStreamingManager.done: return diff --git a/protocol/streaming/grpc/noop_streaming_manager.go b/protocol/streaming/grpc/noop_streaming_manager.go index 424871b4c3..c117a48058 100644 --- a/protocol/streaming/grpc/noop_streaming_manager.go +++ b/protocol/streaming/grpc/noop_streaming_manager.go @@ -46,3 +46,6 @@ func (sm *NoopGrpcStreamingManager) SendOrderbookFillUpdates( func (sm *NoopGrpcStreamingManager) GetUninitializedClobPairIds() []uint32 { return []uint32{} } + +func (sm *NoopGrpcStreamingManager) Stop() { +} diff --git a/protocol/streaming/grpc/types/manager.go b/protocol/streaming/grpc/types/manager.go index 9b5af0c093..3a14f201a2 100644 --- a/protocol/streaming/grpc/types/manager.go +++ b/protocol/streaming/grpc/types/manager.go @@ -7,7 +7,7 @@ import ( type GrpcStreamingManager interface { Enabled() bool - + Stop() // L3+ Orderbook updates. Subscribe( req clobtypes.StreamOrderbookUpdatesRequest,