private void KlineListen() { try { WebSocketClient.SubscribeKlineStream(this.Symbol.Key.ToLower(), KlineInterval.OneMinute, HandleKlineEvent); } catch (Exception ex) { Logger.Error("Exception during KlineListen: " + BinanceMarketApi.GetExceptionErrorInfo(ex)); } }
private void PartialDepthListen() { try { WebSocketClient.SubscribePartialDepthStream(this.Symbol.Key.ToLower(), PartialDepthLevels.Five, HandlePartialDepthUpdate); } catch (Exception ex) { Logger.Error("Exception during PartialDepthListen: " + BinanceMarketApi.GetExceptionErrorInfo(ex)); } }
public override async Task Update(TimeSlice slice) { foreach (var op in Algo.ActiveOperations) { try { await ManageOperation(op); } catch (Exception ex) { var msg = BinanceMarketApi.GetExceptionErrorInfo(ex); Logger.Error($"SimpleStopLossRiskManager: exception while managin {op.ToString("c")}\n Error: {msg}"); } } }