From 3133d54957de31ceab53bcac42805074f75157dd Mon Sep 17 00:00:00 2001 From: c9s Date: Mon, 19 Sep 2022 19:32:16 +0800 Subject: [PATCH] config: update config for new notification switches settings --- config/bollgrid.yaml | 17 ++++------------- config/funding.yaml | 15 ++++----------- config/marketcap.yaml | 5 +++++ config/pricealert.yaml | 15 ++++----------- config/pricedrop.yaml | 14 ++++---------- config/rebalance.yaml | 4 ++++ config/support-margin.yaml | 16 ++++------------ config/support.yaml | 9 ++++----- config/swing.yaml | 16 ++++------------ config/xbalance.yaml | 20 ++++---------------- config/xgap.yaml | 20 ++++---------------- config/xmaker-btcusdt.yaml | 20 ++++---------------- config/xmaker-ethusdt.yaml | 20 ++++---------------- config/xmaker.yaml | 9 ++++----- config/xnav.yaml | 20 ++++---------------- config/xpuremaker.yaml | 12 ++++-------- 16 files changed, 65 insertions(+), 167 deletions(-) diff --git a/config/bollgrid.yaml b/config/bollgrid.yaml index bef337112..3ecfc78f7 100644 --- a/config/bollgrid.yaml +++ b/config/bollgrid.yaml @@ -3,19 +3,10 @@ notifications: slack: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - "^BNB": "bnb" - - # object routing rules - routing: - trade: "$symbol" - order: "$symbol" - submitOrder: "$session" # not supported yet - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: # binance: diff --git a/config/funding.yaml b/config/funding.yaml index 0fcd433ed..9f7e7352b 100644 --- a/config/funding.yaml +++ b/config/funding.yaml @@ -4,17 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - - # object routing rules - routing: - trade: "$symbol" - order: "$symbol" - submitOrder: "$session" # not supported yet - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: binance: diff --git a/config/marketcap.yaml b/config/marketcap.yaml index c3e7b7285..cea8ef9ea 100644 --- a/config/marketcap.yaml +++ b/config/marketcap.yaml @@ -3,6 +3,11 @@ notifications: slack: defaultChannel: "bbgo" errorChannel: "bbgo-error" + switches: + trade: true + orderUpdate: true + submitOrder: true + exchangeStrategies: - on: max diff --git a/config/pricealert.yaml b/config/pricealert.yaml index 2b7180285..1662c50d5 100644 --- a/config/pricealert.yaml +++ b/config/pricealert.yaml @@ -4,17 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - - # object routing rules - routing: - trade: "$symbol" - order: "$symbol" - submitOrder: "$session" # not supported yet - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: binance: diff --git a/config/pricedrop.yaml b/config/pricedrop.yaml index e650a981c..295a8e845 100644 --- a/config/pricedrop.yaml +++ b/config/pricedrop.yaml @@ -3,16 +3,10 @@ notifications: slack: defaultChannel: "bbgo" errorChannel: "bbgo-error" - -reportPnL: -- averageCostBySymbols: - - "BTCUSDT" - - "ETHUSDT" - - "BNBUSDT" - of: binance - when: - - "@daily" - - "@hourly" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: binance: diff --git a/config/rebalance.yaml b/config/rebalance.yaml index 6780da1d3..2038a70d2 100644 --- a/config/rebalance.yaml +++ b/config/rebalance.yaml @@ -3,6 +3,10 @@ notifications: slack: defaultChannel: "bbgo" errorChannel: "bbgo-error" + switches: + trade: true + orderUpdate: true + submitOrder: true exchangeStrategies: - on: max diff --git a/config/support-margin.yaml b/config/support-margin.yaml index bc28cea49..d04614ad2 100644 --- a/config/support-margin.yaml +++ b/config/support-margin.yaml @@ -4,18 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - "^BNB": "bnb" - - # object routing rules - routing: - trade: "$symbol" - order: "$symbol" - submitOrder: "$session" # not supported yet - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: binance_margin_linkusdt: diff --git a/config/support.yaml b/config/support.yaml index b0f1eefbd..221ea574f 100644 --- a/config/support.yaml +++ b/config/support.yaml @@ -3,11 +3,10 @@ notifications: slack: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # object routing rules - routing: - trade: "$symbol" - order: "$symbol" - submitOrder: "$session" # not supported yet + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: binance: diff --git a/config/swing.yaml b/config/swing.yaml index 764fa5a12..45625eda2 100644 --- a/config/swing.yaml +++ b/config/swing.yaml @@ -4,18 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - "^BNB": "bnb" - - # object routing rules - routing: - trade: "$symbol" - order: "$symbol" - submitOrder: "$session" # not supported yet - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: binance: diff --git a/config/xbalance.yaml b/config/xbalance.yaml index a437fc2ec..e3f88005e 100644 --- a/config/xbalance.yaml +++ b/config/xbalance.yaml @@ -4,22 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - - # if you want to route channel by exchange session - sessionChannels: - max: "bbgo-max" - binance: "bbgo-binance" - - # routing rules - routing: - trade: "$symbol" - order: "$slient" - submitOrder: "$slient" - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: max: diff --git a/config/xgap.yaml b/config/xgap.yaml index 89d732986..03b12d6d5 100644 --- a/config/xgap.yaml +++ b/config/xgap.yaml @@ -4,22 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - - # if you want to route channel by exchange session - sessionChannels: - max: "bbgo-max" - binance: "bbgo-binance" - - # routing rules - routing: - trade: "$silent" - order: "$silent" - submitOrder: "$silent" - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true persistence: json: diff --git a/config/xmaker-btcusdt.yaml b/config/xmaker-btcusdt.yaml index 6beb4bd52..4dfa95a5f 100644 --- a/config/xmaker-btcusdt.yaml +++ b/config/xmaker-btcusdt.yaml @@ -4,22 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - - # if you want to route channel by exchange session - sessionChannels: - max: "bbgo-max" - binance: "bbgo-binance" - - # routing rules - routing: - trade: "$symbol" - order: "$silent" - submitOrder: "$silent" - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true reportPnL: - averageCostBySymbols: diff --git a/config/xmaker-ethusdt.yaml b/config/xmaker-ethusdt.yaml index b7faef1f4..f4a0181d9 100644 --- a/config/xmaker-ethusdt.yaml +++ b/config/xmaker-ethusdt.yaml @@ -4,22 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - - # if you want to route channel by exchange session - sessionChannels: - max: "bbgo-max" - binance: "bbgo-binance" - - # routing rules - routing: - trade: "$symbol" - order: "$silent" - submitOrder: "$silent" - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: false + submitOrder: false persistence: json: diff --git a/config/xmaker.yaml b/config/xmaker.yaml index 293b58247..323bf130d 100644 --- a/config/xmaker.yaml +++ b/config/xmaker.yaml @@ -4,11 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # routing rules - routing: - trade: "$silent" - order: "$silent" - submitOrder: "$silent" + switches: + trade: true + orderUpdate: false + submitOrder: false persistence: json: diff --git a/config/xnav.yaml b/config/xnav.yaml index e31a54b66..2e59eef84 100644 --- a/config/xnav.yaml +++ b/config/xnav.yaml @@ -4,22 +4,10 @@ notifications: defaultChannel: "dev-bbgo" errorChannel: "bbgo-error" - # if you want to route channel by symbol - symbolChannels: - "^BTC": "btc" - "^ETH": "eth" - - # if you want to route channel by exchange session - sessionChannels: - max: "bbgo-max" - binance: "bbgo-binance" - - # routing rules - routing: - trade: "$symbol" - order: "$slient" - submitOrder: "$slient" - pnL: "bbgo-pnl" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: max: diff --git a/config/xpuremaker.yaml b/config/xpuremaker.yaml index b089a1adb..697fdfeb7 100644 --- a/config/xpuremaker.yaml +++ b/config/xpuremaker.yaml @@ -4,14 +4,10 @@ notifications: defaultChannel: "bbgo" errorChannel: "bbgo-error" -reportPnL: -- averageCostBySymbols: - - "BTCUSDT" - - "BNBUSDT" - of: binance - when: - - "@daily" - - "@hourly" + switches: + trade: true + orderUpdate: true + submitOrder: true sessions: max: