@@ -14,7 +14,6 @@ import (
14
14
"github.com/spf13/viper"
15
15
16
16
"github.com/c9s/bbgo/pkg/cache"
17
- "github.com/c9s/bbgo/pkg/core"
18
17
"github.com/c9s/bbgo/pkg/exchange/retry"
19
18
"github.com/c9s/bbgo/pkg/util/templateutil"
20
19
@@ -120,8 +119,6 @@ type ExchangeSession struct {
120
119
// indicators is the v2 api indicators
121
120
indicators map [string ]* IndicatorSet
122
121
123
- orderStores map [string ]* core.OrderStore
124
-
125
122
usedSymbols map [string ]struct {}
126
123
initializedSymbols map [string ]struct {}
127
124
@@ -150,7 +147,6 @@ func NewExchangeSession(name string, exchange types.Exchange) *ExchangeSession {
150
147
marketDataStores : make (map [string ]* MarketDataStore ),
151
148
standardIndicatorSets : make (map [string ]* StandardIndicatorSet ),
152
149
indicators : make (map [string ]* IndicatorSet ),
153
- orderStores : make (map [string ]* core.OrderStore ),
154
150
usedSymbols : make (map [string ]struct {}),
155
151
initializedSymbols : make (map [string ]struct {}),
156
152
logger : log .WithField ("session" , name ),
@@ -439,11 +435,6 @@ func (session *ExchangeSession) initSymbol(ctx context.Context, environ *Environ
439
435
position .BindStream (session .UserDataStream )
440
436
session .positions [symbol ] = position
441
437
442
- orderStore := core .NewOrderStore (symbol )
443
- orderStore .AddOrderUpdate = true
444
- orderStore .BindStream (session .UserDataStream )
445
- session .orderStores [symbol ] = orderStore
446
-
447
438
marketDataStore := NewMarketDataStore (symbol )
448
439
if ! disableMarketDataStore {
449
440
if _ , ok := session .marketDataStores [symbol ]; ! ok {
@@ -665,15 +656,6 @@ func (session *ExchangeSession) SetMarkets(markets types.MarketMap) {
665
656
session .markets = markets
666
657
}
667
658
668
- func (session * ExchangeSession ) OrderStore (symbol string ) (store * core.OrderStore , ok bool ) {
669
- store , ok = session .orderStores [symbol ]
670
- return store , ok
671
- }
672
-
673
- func (session * ExchangeSession ) OrderStores () map [string ]* core.OrderStore {
674
- return session .orderStores
675
- }
676
-
677
659
// Subscribe save the subscription info, later it will be assigned to the stream
678
660
func (session * ExchangeSession ) Subscribe (
679
661
channel types.Channel , symbol string , options types.SubscribeOptions ,
@@ -876,7 +858,6 @@ func (session *ExchangeSession) InitExchange(name string, ex types.Exchange) err
876
858
session .positions = make (map [string ]* types.Position )
877
859
session .standardIndicatorSets = make (map [string ]* StandardIndicatorSet )
878
860
session .indicators = make (map [string ]* IndicatorSet )
879
- session .orderStores = make (map [string ]* core.OrderStore )
880
861
session .OrderExecutor = & ExchangeOrderExecutor {
881
862
// copy the notification system so that we can route
882
863
Session : session ,
0 commit comments