From 9585a5b6e36182bed05941ca811c52e077d114a6 Mon Sep 17 00:00:00 2001 From: Roman Shterenzon Date: Sat, 29 Apr 2023 14:38:50 +0300 Subject: [PATCH] Upgrade to RxJava 3 --- pom.xml | 6 +++--- .../bankera/BankeraStreamingExchange.java | 4 ++-- .../BankeraStreamingMarketDataService.java | 2 +- .../binance/BinanceStreamingAccountService.java | 8 ++++---- .../binance/BinanceStreamingExchange.java | 4 ++-- .../BinanceStreamingMarketDataService.java | 16 ++++++++-------- .../binance/BinanceStreamingTradeService.java | 8 ++++---- .../binance/BinanceUserDataChannel.java | 4 ++-- .../binance/BinanceUserDataStreamingService.java | 2 +- .../binance/BinanceFuturesPublicStreamsTest.java | 2 +- .../BinanceLiveFutureSubscriptionExample.java | 2 +- .../binance/BinanceLiveSubscriptionExample.java | 2 +- .../binance/BinanceManualExample.java | 2 +- .../binance/BinancePublicStreamsTest.java | 2 +- .../BitfinexStreamingAccountService.java | 2 +- .../bitfinex/BitfinexStreamingAdapters.java | 2 +- .../bitfinex/BitfinexStreamingExchange.java | 4 ++-- .../BitfinexStreamingMarketDataService.java | 2 +- .../bitfinex/BitfinexStreamingService.java | 8 ++++---- .../bitfinex/BitfinexStreamingTradeService.java | 2 +- .../bitfinex/BitfinexManualExample.java | 4 ++-- .../bitfinex/BitfinexStreamingServiceTest.java | 2 +- .../bitflyer/BitflyerStreamingExchange.java | 2 +- .../BitflyerStreamingMarketDataService.java | 2 +- .../bitmex/BitmexStreamingExchange.java | 4 ++-- .../bitmex/BitmexStreamingMarketDataService.java | 2 +- .../bitmex/BitmexStreamingService.java | 12 ++++++------ .../bitmex/BitmexStreamingTradeService.java | 2 +- .../xchangestream/bitmex/BitmexOrderIT.java | 4 ++-- .../bitrich/xchangestream/bitmex/BitmexTest.java | 14 +++++--------- .../bitstamp/v2/BitstampStreamingExchange.java | 4 ++-- .../v2/BitstampStreamingMarketDataService.java | 2 +- .../bitstamp/BitstampManualExample.java | 2 +- ...tstampStreamingMarketDataServiceBaseTest.java | 2 +- ...BitstampStreamingMarketDataServiceV2Test.java | 4 ++-- .../btcmarkets/BTCMarketsStreamingExchange.java | 4 ++-- .../BTCMarketsStreamingMarketDataService.java | 2 +- .../btcmarkets/BTCMarketsManualExample.java | 2 +- .../cexio/CexioStreamingExchange.java | 2 +- .../cexio/CexioStreamingMarketDataService.java | 4 ++-- .../cexio/CexioStreamingRawService.java | 10 +++++----- .../cexio/CexioStreamingServiceTest.java | 2 +- .../CoinbaseProStreamingExchange.java | 4 ++-- .../CoinbaseProStreamingMarketDataService.java | 2 +- .../coinbasepro/CoinbaseProStreamingService.java | 2 +- .../CoinbaseProStreamingTradeService.java | 2 +- .../coincheck/CoincheckStreamingExchange.java | 4 ++-- .../CoincheckStreamingMarketDataService.java | 6 +++--- .../coincheck/CoincheckManualExample.java | 2 +- .../coincheck/CoincheckStreamingIntegration.java | 2 +- .../coinjar/CoinjarStreamingExchange.java | 4 ++-- .../CoinjarStreamingMarketDataService.java | 2 +- .../coinjar/CoinjarStreamingService.java | 2 +- .../coinjar/CoinjarStreamingTradeService.java | 2 +- .../coinjar/CoinjarOrderChangesExample.java | 6 +++--- ...jarStreamingMarketDataServiceIntegration.java | 2 +- .../coinjar/CoinjarUserTradesExample.java | 6 +++--- .../v2/CoinmateStreamingAccountService.java | 2 +- .../coinmate/v2/CoinmateStreamingExchange.java | 2 +- .../v2/CoinmateStreamingMarketDataService.java | 2 +- .../v2/CoinmateStreamingTradeService.java | 2 +- .../CoinmateStreamingMarketDataServiceTest.java | 4 ++-- .../core/StreamingAccountService.java | 2 +- .../xchangestream/core/StreamingExchange.java | 4 ++-- .../core/StreamingMarketDataService.java | 2 +- .../core/StreamingTradeService.java | 2 +- .../dydx/dydxStreamingExchange.java | 2 +- .../xchangestream/dydx/dydxStreamingService.java | 2 +- .../v1/dydxStreamingMarketDataService.java | 2 +- .../v3/dydxStreamingMarketDataService.java | 2 +- .../xchangestream/ftx/FtxStreamingExchange.java | 4 ++-- .../ftx/FtxStreamingMarketDataService.java | 2 +- .../ftx/FtxStreamingTradeService.java | 2 +- ...FtxStreamingMarketDataServiceIntegration.java | 2 +- .../src/main/java/GateioStreamingExchange.java | 2 +- .../java/GateioStreamingMarketDataService.java | 2 +- .../src/main/java/GateioStreamingService.java | 2 +- .../src/test/java/GateioManualExample.java | 2 +- .../gemini/GeminiStreamingExchange.java | 4 ++-- .../gemini/GeminiStreamingMarketDataService.java | 2 +- .../gemini/GeminiStreamingService.java | 2 +- .../gemini/GeminiManualExample.java | 2 +- .../gemini/GeminiStreamingExchange.java | 6 +++--- .../gemini/GeminiStreamingMarketDataService.java | 4 ++-- .../gemini/GeminiStreamingService.java | 6 +++--- .../hitbtc/HitbtcStreamingExchange.java | 4 ++-- .../hitbtc/HitbtcStreamingMarketDataService.java | 2 +- .../hitbtc/HitbtcManualExample.java | 2 +- .../HitbtcStreamingMarketDataServiceTest.java | 4 ++-- .../huobi/HuobiStreamingExchange.java | 4 ++-- .../huobi/HuobiStreamingMarketDataService.java | 2 +- .../kraken/KrakenStreamingExchange.java | 4 ++-- .../kraken/KrakenStreamingMarketDataService.java | 2 +- .../kraken/KrakenStreamingService.java | 6 +++--- .../kraken/KrakenStreamingTradeService.java | 2 +- .../kraken/KrakenOrderbookExample.java | 2 +- .../kraken/KrakenTickerExample.java | 2 +- .../kraken/KrakenTradesExample.java | 2 +- .../KrakenFuturesStreamingExchange.java | 4 ++-- .../KrakenFuturesStreamingMarketDataService.java | 2 +- .../KrakenFuturesStreamingService.java | 2 +- .../KrakenFuturesStreamingTradeService.java | 2 +- .../KrakenFuturesStreamingPrivateDataTest.java | 2 +- .../KrakenFuturesStreamingPublicDataTest.java | 6 +++--- xchange-stream-kucoin/pom.xml | 2 +- .../kucoin/KucoinStreamingExchange.java | 4 ++-- .../kucoin/KucoinStreamingMarketDataService.java | 4 ++-- .../kucoin/KucoinStreamingService.java | 8 ++++---- .../kucoin/KucoinStreamingTradeService.java | 2 +- .../lgo/LgoLevel2BatchSubscription.java | 2 +- .../lgo/LgoStreamingAccountService.java | 2 +- .../xchangestream/lgo/LgoStreamingExchange.java | 4 ++-- .../lgo/LgoStreamingMarketDataService.java | 2 +- .../lgo/LgoStreamingTradeService.java | 2 +- .../lgo/LgoTradeBatchSubscription.java | 2 +- .../lgo/LgoUserBatchSubscription.java | 2 +- .../lgo/LgoStreamingAccountServiceTest.java | 6 +++--- .../lgo/LgoStreamingMarketDataServiceTest.java | 2 +- .../lgo/LgoStreamingTradeServiceTest.java | 2 +- .../okcoin/OkCoinStreamingExchange.java | 4 ++-- .../okcoin/OkCoinStreamingMarketDataService.java | 2 +- .../okcoin/OkCoinStreamingService.java | 8 ++++---- .../OkCoinStreamingMarketDataServiceTest.java | 4 ++-- .../okex/OkexStreamingExchange.java | 2 +- .../okex/OkexStreamingMarketDataService.java | 4 ++-- .../xchangestream/okex/OkexStreamingService.java | 8 ++++---- .../okex/OkexStreamingTradeService.java | 2 +- .../OkexStreamingPrivateDataIntegtration.java | 2 +- .../okex/OkexStreamingPublicDataIntegration.java | 2 +- .../poloniex2/PoloniexStreamingExchange.java | 4 ++-- .../PoloniexStreamingMarketDataService.java | 2 +- .../poloniex2/PoloniexStreamingService.java | 2 +- .../serum/SerumStreamingExchange.java | 4 ++-- xchange-stream-service-core/pom.xml | 4 ++-- .../service/ConnectableService.java | 2 +- .../service/netty/ConnectionStateModel.java | 6 +++--- .../service/netty/NettyStreamingService.java | 10 +++++----- xchange-stream-service-pubnub/pom.xml | 4 ++-- .../service/pubnub/PubnubStreamingService.java | 6 +++--- 139 files changed, 237 insertions(+), 241 deletions(-) diff --git a/pom.xml b/pom.xml index 9e3af921e02..f71afaa9035 100644 --- a/pom.xml +++ b/pom.xml @@ -342,9 +342,9 @@ - io.reactivex.rxjava2 + io.reactivex.rxjava3 rxjava - 2.2.21 + 3.1.8 com.pubnub @@ -582,4 +582,4 @@ - \ No newline at end of file + diff --git a/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingExchange.java b/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingExchange.java index 3dfa3052408..9dad6cb083c 100644 --- a/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingExchange.java +++ b/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.bankera.BankeraExchange; import org.knowm.xchange.bankera.service.BankeraMarketDataService; diff --git a/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingMarketDataService.java b/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingMarketDataService.java index 77c88da4eda..7a977bbee4d 100644 --- a/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingMarketDataService.java +++ b/xchange-stream-bankera/src/main/java/info/bitrich/xchangestream/bankera/BankeraStreamingMarketDataService.java @@ -1,7 +1,7 @@ package info.bitrich.xchangestream.bankera; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.math.BigDecimal; import java.util.ArrayList; diff --git a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingAccountService.java b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingAccountService.java index d6a655a97e1..ae7aee360dc 100644 --- a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingAccountService.java +++ b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingAccountService.java @@ -6,10 +6,10 @@ import info.bitrich.xchangestream.binance.dto.OutboundAccountPositionBinanceWebsocketTransaction; import info.bitrich.xchangestream.core.StreamingAccountService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; -import io.reactivex.subjects.BehaviorSubject; -import io.reactivex.subjects.Subject; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; +import io.reactivex.rxjava3.subjects.BehaviorSubject; +import io.reactivex.rxjava3.subjects.Subject; import org.knowm.xchange.currency.Currency; import org.knowm.xchange.dto.account.Balance; import org.knowm.xchange.exceptions.ExchangeException; diff --git a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingExchange.java b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingExchange.java index 8934e3a407c..551d44e6201 100644 --- a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingExchange.java +++ b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingExchange.java @@ -5,8 +5,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; import info.bitrich.xchangestream.util.Events; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.apache.commons.lang3.StringUtils; import org.knowm.xchange.binance.BinanceAuthenticated; import org.knowm.xchange.binance.BinanceExchange; diff --git a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingMarketDataService.java b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingMarketDataService.java index 72994362002..cf5233563af 100644 --- a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingMarketDataService.java +++ b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingMarketDataService.java @@ -14,14 +14,14 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; -import io.reactivex.Scheduler; -import io.reactivex.Single; -import io.reactivex.disposables.CompositeDisposable; -import io.reactivex.disposables.Disposable; -import io.reactivex.functions.Consumer; -import io.reactivex.schedulers.Schedulers; -import io.reactivex.subjects.BehaviorSubject; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.core.Scheduler; +import io.reactivex.rxjava3.core.Single; +import io.reactivex.rxjava3.disposables.CompositeDisposable; +import io.reactivex.rxjava3.disposables.Disposable; +import io.reactivex.rxjava3.functions.Consumer; +import io.reactivex.rxjava3.schedulers.Schedulers; +import io.reactivex.rxjava3.subjects.BehaviorSubject; import java.io.IOException; import java.util.*; import java.util.concurrent.ConcurrentHashMap; diff --git a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingTradeService.java b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingTradeService.java index c35e7c97cd7..69f2eec749c 100644 --- a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingTradeService.java +++ b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceStreamingTradeService.java @@ -7,10 +7,10 @@ import info.bitrich.xchangestream.binance.dto.ExecutionReportBinanceUserTransaction.ExecutionType; import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; -import io.reactivex.subjects.PublishSubject; -import io.reactivex.subjects.Subject; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; +import io.reactivex.rxjava3.subjects.PublishSubject; +import io.reactivex.rxjava3.subjects.Subject; import java.io.IOException; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.derivative.FuturesContract; diff --git a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataChannel.java b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataChannel.java index 7d586661305..6ce72efe186 100644 --- a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataChannel.java +++ b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataChannel.java @@ -2,8 +2,8 @@ import static java.util.concurrent.TimeUnit.SECONDS; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; import java.io.IOException; import java.util.concurrent.TimeUnit; import java.util.function.Consumer; diff --git a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataStreamingService.java b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataStreamingService.java index d143e08c245..27545efff80 100644 --- a/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataStreamingService.java +++ b/xchange-stream-binance/src/main/java/info/bitrich/xchangestream/binance/BinanceUserDataStreamingService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; import info.bitrich.xchangestream.service.netty.WebSocketClientCompressionAllowClientNoContextAndServerNoContextHandler; import io.netty.handler.codec.http.websocketx.extensions.WebSocketClientExtensionHandler; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceFuturesPublicStreamsTest.java b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceFuturesPublicStreamsTest.java index aae74bdfdea..2449c8f7f88 100644 --- a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceFuturesPublicStreamsTest.java +++ b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceFuturesPublicStreamsTest.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.junit.Before; import org.junit.Ignore; import org.junit.Test; diff --git a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveFutureSubscriptionExample.java b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveFutureSubscriptionExample.java index 0d95aca25c2..278eaf869a3 100644 --- a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveFutureSubscriptionExample.java +++ b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveFutureSubscriptionExample.java @@ -3,7 +3,7 @@ import info.bitrich.xchangestream.binancefuture.BinanceFutureStreamingExchange; import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.derivative.FuturesContract; import org.knowm.xchange.instrument.Instrument; diff --git a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveSubscriptionExample.java b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveSubscriptionExample.java index 45fbe03c75e..a06fa43f05a 100644 --- a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveSubscriptionExample.java +++ b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceLiveSubscriptionExample.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.instrument.Instrument; diff --git a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceManualExample.java b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceManualExample.java index bccf2388399..22ab60be800 100644 --- a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceManualExample.java +++ b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinanceManualExample.java @@ -3,7 +3,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; import org.slf4j.Logger; diff --git a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinancePublicStreamsTest.java b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinancePublicStreamsTest.java index 5f1cca95b24..968c64e684a 100644 --- a/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinancePublicStreamsTest.java +++ b/xchange-stream-binance/src/test/java/info/bitrich/xchangestream/binance/BinancePublicStreamsTest.java @@ -3,7 +3,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.junit.Before; import org.junit.Ignore; import org.junit.Test; diff --git a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAccountService.java b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAccountService.java index ffb808eb6e9..8ebbc9c2a0f 100644 --- a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAccountService.java +++ b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAccountService.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthBalance; import info.bitrich.xchangestream.core.StreamingAccountService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.Currency; import org.knowm.xchange.dto.account.Balance; import org.knowm.xchange.exceptions.ExchangeException; diff --git a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAdapters.java b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAdapters.java index 4152f6968c7..e6554402170 100644 --- a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAdapters.java +++ b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingAdapters.java @@ -9,7 +9,7 @@ import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthOrder; import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthPreTrade; import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthTrade; -import io.reactivex.annotations.Nullable; +import io.reactivex.rxjava3.annotations.Nullable; import java.math.BigDecimal; import java.util.stream.Stream; import org.knowm.xchange.bitfinex.service.BitfinexAdapters; diff --git a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingExchange.java b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingExchange.java index fe383894a65..05295117e33 100644 --- a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingExchange.java +++ b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingExchange.java @@ -3,8 +3,8 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.apache.commons.lang3.StringUtils; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.bitfinex.BitfinexExchange; diff --git a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingMarketDataService.java b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingMarketDataService.java index b9f9104195f..891cab24a45 100644 --- a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingMarketDataService.java +++ b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingMarketDataService.java @@ -15,7 +15,7 @@ import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebsocketUpdateTrade; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.HashMap; import java.util.Map; import org.knowm.xchange.currency.Currency; diff --git a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingService.java b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingService.java index 6161b50e115..ca51bf07942 100644 --- a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingService.java +++ b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingService.java @@ -11,10 +11,10 @@ import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketUnSubscriptionMessage; import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; import io.netty.handler.codec.http.websocketx.extensions.WebSocketClientExtensionHandler; -import io.reactivex.Completable; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; -import io.reactivex.subjects.PublishSubject; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; +import io.reactivex.rxjava3.subjects.PublishSubject; import java.io.IOException; import java.nio.charset.StandardCharsets; import java.time.Duration; diff --git a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingTradeService.java b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingTradeService.java index 4ed77a566ce..b17a0b89517 100644 --- a/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingTradeService.java +++ b/xchange-stream-bitfinex/src/main/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingTradeService.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthPreTrade; import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthTrade; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.function.Function; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.Order; diff --git a/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexManualExample.java b/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexManualExample.java index b767fc40b04..a7d4ef7c8dd 100644 --- a/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexManualExample.java +++ b/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexManualExample.java @@ -5,8 +5,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.service.ConnectableService; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; import org.apache.commons.lang3.concurrent.TimedSemaphore; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingServiceTest.java b/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingServiceTest.java index 9be00430d6e..b2a671864ed 100644 --- a/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingServiceTest.java +++ b/xchange-stream-bitfinex/src/test/java/info/bitrich/xchangestream/bitfinex/BitfinexStreamingServiceTest.java @@ -8,7 +8,7 @@ import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthOrder; import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthPreTrade; import info.bitrich.xchangestream.bitfinex.dto.BitfinexWebSocketAuthTrade; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.observers.TestObserver; import java.io.IOException; import java.math.BigDecimal; import org.junit.Before; diff --git a/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingExchange.java b/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingExchange.java index b906543dc99..49d8582710e 100644 --- a/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingExchange.java +++ b/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingExchange.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.pubnub.PubnubStreamingService; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.bitflyer.BitflyerExchange; diff --git a/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingMarketDataService.java b/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingMarketDataService.java index 4871df16369..dfcaa6abae0 100644 --- a/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingMarketDataService.java +++ b/xchange-stream-bitflyer/src/main/java/info/bitrich/xchangestream/bitflyer/BitflyerStreamingMarketDataService.java @@ -11,7 +11,7 @@ import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; import info.bitrich.xchangestream.service.pubnub.PubnubStreamingService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.HashMap; import java.util.Map; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingExchange.java b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingExchange.java index 46ed9a840b8..d9f895377df 100644 --- a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingExchange.java +++ b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.bitmex.BitmexExchange; diff --git a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingMarketDataService.java b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingMarketDataService.java index c4685995d41..375d396c86f 100644 --- a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingMarketDataService.java +++ b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingMarketDataService.java @@ -15,7 +15,7 @@ import info.bitrich.xchangestream.bitmex.dto.RawOrderBook; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.util.ArrayList; import java.util.Collections; diff --git a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingService.java b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingService.java index 17fedb32221..2c02e94df67 100644 --- a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingService.java +++ b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingService.java @@ -11,12 +11,12 @@ import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; import io.netty.handler.codec.http.DefaultHttpHeaders; import io.netty.handler.codec.http.websocketx.extensions.WebSocketClientExtensionHandler; -import io.reactivex.Completable; -import io.reactivex.CompletableSource; -import io.reactivex.Observable; -import io.reactivex.ObservableEmitter; -import io.reactivex.disposables.Disposable; -import io.reactivex.schedulers.Schedulers; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.CompletableSource; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.core.ObservableEmitter; +import io.reactivex.rxjava3.disposables.Disposable; +import io.reactivex.rxjava3.schedulers.Schedulers; import java.io.IOException; import java.text.ParseException; import java.text.SimpleDateFormat; diff --git a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingTradeService.java b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingTradeService.java index f601127b649..71afe7452aa 100644 --- a/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingTradeService.java +++ b/xchange-stream-bitmex/src/main/java/info/bitrich/xchangestream/bitmex/BitmexStreamingTradeService.java @@ -1,7 +1,7 @@ package info.bitrich.xchangestream.bitmex; import info.bitrich.xchangestream.bitmex.dto.BitmexOrder; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.Arrays; import java.util.stream.Collectors; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexOrderIT.java b/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexOrderIT.java index 39de835fcc6..7cd011fe44e 100644 --- a/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexOrderIT.java +++ b/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexOrderIT.java @@ -6,7 +6,7 @@ import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.util.LocalExchangeConfig; import info.bitrich.xchangestream.util.PropsLoader; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.math.BigDecimal; import java.util.Date; @@ -221,7 +221,7 @@ public void shouldGetExecutionOnFill() { executionObservable .test() .awaitCount(5) - .assertNever(execution -> Objects.equals(execution.getClOrdID(), clOrdId)) + .assertValue(execution -> !Objects.equals(execution.getClOrdID(), clOrdId)) .dispose(); scheduler.shutdown(); diff --git a/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexTest.java b/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexTest.java index 84069ae553c..63c7ab041b5 100644 --- a/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexTest.java +++ b/xchange-stream-bitmex/src/test/java/info/bitrich/xchangestream/bitmex/BitmexTest.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.util.BookSanityChecker; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import java.util.concurrent.TimeUnit; import org.junit.After; import org.junit.Before; @@ -49,10 +49,8 @@ private void awaitCompletable(Completable completable) { private void awaitDataCount(Observable observable) { observable .test() - .assertSubscribed() .assertNoErrors() .awaitCount(BitmexTest.MIN_DATA_COUNT) - .assertNoTimeout() .dispose(); } @@ -85,16 +83,14 @@ public void shouldHaveNoBookErrors() { streamingMarketDataService .getOrderBook(xbtUsd) .test() - .assertSubscribed() - .assertNoErrors() + .assertComplete() .awaitCount(10) - .assertNever( + .assertValue( book -> { String err = BookSanityChecker.hasErrors(book); LOG.info("err {}", err); - return err != null; + return err == null; }) - .assertNoTimeout() .dispose(); } } diff --git a/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingExchange.java b/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingExchange.java index 12a251e9a86..f1dacc87082 100644 --- a/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingExchange.java +++ b/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.bitstamp.BitstampExchange; diff --git a/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingMarketDataService.java b/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingMarketDataService.java index cc3a07695ac..dffc50f0243 100644 --- a/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingMarketDataService.java +++ b/xchange-stream-bitstamp/src/main/java/info/bitrich/xchangestream/bitstamp/v2/BitstampStreamingMarketDataService.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.bitstamp.dto.BitstampWebSocketTransaction; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.bitstamp.BitstampAdapters; import org.knowm.xchange.bitstamp.dto.marketdata.BitstampOrderBook; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampManualExample.java b/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampManualExample.java index 683785b69c8..66541db1490 100644 --- a/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampManualExample.java +++ b/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampManualExample.java @@ -7,7 +7,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.service.ConnectableService; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.apache.commons.lang3.concurrent.TimedSemaphore; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceBaseTest.java b/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceBaseTest.java index 56606d5d9f2..592788bf0cb 100644 --- a/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceBaseTest.java +++ b/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceBaseTest.java @@ -4,7 +4,7 @@ import com.fasterxml.jackson.databind.ObjectMapper; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.observers.TestObserver; import java.util.List; import org.junit.Assert; import org.knowm.xchange.dto.marketdata.OrderBook; diff --git a/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceV2Test.java b/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceV2Test.java index 7317c5841df..3aa8899b756 100644 --- a/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceV2Test.java +++ b/xchange-stream-bitstamp/src/test/java/info/bitrich/xchangestream/bitstamp/BitstampStreamingMarketDataServiceV2Test.java @@ -6,8 +6,8 @@ import com.fasterxml.jackson.databind.JsonNode; import info.bitrich.xchangestream.bitstamp.v2.BitstampStreamingMarketDataService; import info.bitrich.xchangestream.bitstamp.v2.BitstampStreamingService; -import io.reactivex.Observable; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.observers.TestObserver; import java.math.BigDecimal; import java.util.ArrayList; import java.util.Date; diff --git a/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingExchange.java b/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingExchange.java index b243199b324..152f383ff89 100644 --- a/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingExchange.java +++ b/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.btcmarkets.BTCMarketsExchange; diff --git a/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingMarketDataService.java b/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingMarketDataService.java index 96395447fe6..2bb76e1ed62 100644 --- a/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingMarketDataService.java +++ b/xchange-stream-btcmarkets/src/main/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsStreamingMarketDataService.java @@ -11,7 +11,7 @@ import info.bitrich.xchangestream.btcmarkets.dto.BTCMarketsWebSocketTradeMessage; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.marketdata.OrderBook; import org.knowm.xchange.dto.marketdata.Ticker; diff --git a/xchange-stream-btcmarkets/src/test/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsManualExample.java b/xchange-stream-btcmarkets/src/test/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsManualExample.java index 526af0b42e8..174c8fe0d24 100644 --- a/xchange-stream-btcmarkets/src/test/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsManualExample.java +++ b/xchange-stream-btcmarkets/src/test/java/info/bitrich/xchangestream/btcmarkets/BTCMarketsManualExample.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; import org.slf4j.Logger; diff --git a/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingExchange.java b/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingExchange.java index 34986919e5b..bbdf59ec78a 100644 --- a/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingExchange.java +++ b/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingExchange.java @@ -3,7 +3,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.cexio.CexIOExchange; import org.knowm.xchange.exceptions.NotYetImplementedForExchangeException; diff --git a/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingMarketDataService.java b/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingMarketDataService.java index 47c714c86da..82cae652a80 100644 --- a/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingMarketDataService.java +++ b/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingMarketDataService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.cexio.dto.CexioWebSocketOrderBookSubscribeResponse; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigInteger; import java.util.ArrayList; import java.util.Date; @@ -25,7 +25,7 @@ public CexioStreamingMarketDataService(CexioStreamingRawService streamingOrderDa } static class OrderBookUpdateConsumer - implements io.reactivex.functions.Function< + implements io.reactivex.rxjava3.functions.Function< CexioWebSocketOrderBookSubscribeResponse, OrderBook> { BigInteger prevID = null; OrderBook orderBookSoFar = diff --git a/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingRawService.java b/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingRawService.java index 2d1a40eb701..d7640b20706 100644 --- a/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingRawService.java +++ b/xchange-stream-cexio/src/main/java/info/bitrich/xchangestream/cexio/CexioStreamingRawService.java @@ -15,11 +15,11 @@ import info.bitrich.xchangestream.cexio.dto.CexioWebSocketTransactionMessage; import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Completable; -import io.reactivex.CompletableEmitter; -import io.reactivex.CompletableOnSubscribe; -import io.reactivex.Observable; -import io.reactivex.subjects.PublishSubject; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.CompletableEmitter; +import io.reactivex.rxjava3.core.CompletableOnSubscribe; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.subjects.PublishSubject; import java.io.IOException; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.Order; diff --git a/xchange-stream-cexio/src/test/java/info/bitrich/xchangestream/cexio/CexioStreamingServiceTest.java b/xchange-stream-cexio/src/test/java/info/bitrich/xchangestream/cexio/CexioStreamingServiceTest.java index 1dabde0c963..bc34a5a27f8 100644 --- a/xchange-stream-cexio/src/test/java/info/bitrich/xchangestream/cexio/CexioStreamingServiceTest.java +++ b/xchange-stream-cexio/src/test/java/info/bitrich/xchangestream/cexio/CexioStreamingServiceTest.java @@ -3,7 +3,7 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import info.bitrich.xchangestream.cexio.dto.CexioWebSocketTransaction; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.observers.TestObserver; import java.io.IOException; import java.math.BigDecimal; import java.time.Instant; diff --git a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingExchange.java b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingExchange.java index c084a224d48..212fec82192 100644 --- a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingExchange.java +++ b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingExchange.java @@ -6,8 +6,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; import info.bitrich.xchangestream.service.netty.WebSocketClientHandler; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.coinbasepro.CoinbaseProExchange; import org.knowm.xchange.coinbasepro.dto.account.CoinbaseProWebsocketAuthData; diff --git a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingMarketDataService.java b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingMarketDataService.java index 161860d633e..381a81f4851 100644 --- a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingMarketDataService.java +++ b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingMarketDataService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.coinbasepro.dto.CoinbaseProWebSocketTransaction; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.List; import java.util.Map; diff --git a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingService.java b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingService.java index a1cf2d7541e..0e5063f24e6 100644 --- a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingService.java +++ b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingService.java @@ -13,7 +13,7 @@ import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.http.websocketx.WebSocketClientHandshaker; import io.netty.handler.codec.http.websocketx.extensions.WebSocketClientExtensionHandler; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.time.Duration; import java.util.Arrays; diff --git a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingTradeService.java b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingTradeService.java index bb3fc91fbd4..6736a01ef9a 100644 --- a/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingTradeService.java +++ b/xchange-stream-coinbasepro/src/main/java/info/bitrich/xchangestream/coinbasepro/CoinbaseProStreamingTradeService.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.coinbasepro.dto.CoinbaseProWebSocketTransaction; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.Collections; import java.util.List; import org.knowm.xchange.coinbasepro.dto.trade.CoinbaseProFill; diff --git a/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingExchange.java b/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingExchange.java index e56a3261c3b..d70fdadbd1e 100644 --- a/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingExchange.java +++ b/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; import info.bitrich.xchangestream.util.Events; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import lombok.extern.slf4j.Slf4j; import org.knowm.xchange.coincheck.CoincheckExchange; diff --git a/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingMarketDataService.java b/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingMarketDataService.java index e17bbeea5ca..ade7a314387 100644 --- a/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingMarketDataService.java +++ b/xchange-stream-coincheck/src/main/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingMarketDataService.java @@ -4,9 +4,9 @@ import info.bitrich.xchangestream.coincheck.dto.CoincheckSubscriptionNames; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; -import io.reactivex.Single; -import io.reactivex.schedulers.Schedulers; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.core.Single; +import io.reactivex.rxjava3.schedulers.Schedulers; import java.util.stream.Stream; import lombok.NonNull; import lombok.RequiredArgsConstructor; diff --git a/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckManualExample.java b/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckManualExample.java index 04be09d8e05..87ce58476ff 100644 --- a/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckManualExample.java +++ b/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckManualExample.java @@ -1,7 +1,7 @@ package info.bitrich.xchangestream.coincheck; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.CompositeDisposable; +import io.reactivex.rxjava3.disposables.CompositeDisposable; import java.math.BigDecimal; import java.time.Duration; import lombok.SneakyThrows; diff --git a/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingIntegration.java b/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingIntegration.java index 266b169392f..5f37997c019 100644 --- a/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingIntegration.java +++ b/xchange-stream-coincheck/src/test/java/info/bitrich/xchangestream/coincheck/CoincheckStreamingIntegration.java @@ -3,7 +3,7 @@ import static org.assertj.core.api.Assertions.assertThat; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.CompositeDisposable; +import io.reactivex.rxjava3.disposables.CompositeDisposable; import java.time.Duration; import java.time.Instant; import java.util.concurrent.atomic.AtomicInteger; diff --git a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingExchange.java b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingExchange.java index 432f4ba7589..d3041feb527 100644 --- a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingExchange.java +++ b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingExchange.java @@ -3,8 +3,8 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.coinjar.CoinjarExchange; public class CoinjarStreamingExchange extends CoinjarExchange implements StreamingExchange { diff --git a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataService.java b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataService.java index 10da1539251..b38794f3a75 100644 --- a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataService.java +++ b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataService.java @@ -6,7 +6,7 @@ import info.bitrich.xchangestream.coinjar.dto.CoinjarWebSocketBookEvent; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.List; import java.util.Map; diff --git a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingService.java b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingService.java index 041ba8229ab..e8e08fb9713 100644 --- a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingService.java +++ b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.coinjar.dto.CoinjarWebSocketSubscribeMessage; import info.bitrich.xchangestream.coinjar.dto.CoinjarWebSocketUnsubscribeMessage; import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicInteger; diff --git a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingTradeService.java b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingTradeService.java index ed4e3a65c4c..75dd2b70265 100644 --- a/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingTradeService.java +++ b/xchange-stream-coinjar/src/main/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingTradeService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.coinjar.dto.CoinjarWebSocketUserTradeEvent; import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.Order; import org.knowm.xchange.dto.trade.UserTrade; diff --git a/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarOrderChangesExample.java b/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarOrderChangesExample.java index 0ee26fbd6d7..43712e1c85e 100644 --- a/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarOrderChangesExample.java +++ b/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarOrderChangesExample.java @@ -3,8 +3,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.disposables.Disposable; -import io.reactivex.observers.BaseTestConsumer; +import io.reactivex.rxjava3.disposables.Disposable; +import io.reactivex.rxjava3.observers.BaseTestConsumer; import org.junit.Test; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.utils.AuthUtils; @@ -28,7 +28,7 @@ public void runTest() { streamingTradeService .getOrderChanges(null) .test() - .awaitCount(10, BaseTestConsumer.TestWaitStrategy.SLEEP_100MS, 1000 * 60 * 10) + .awaitCount(10) .assertNoErrors(); disposable.dispose(); } diff --git a/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataServiceIntegration.java b/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataServiceIntegration.java index 69d8a731c80..dc078eea899 100644 --- a/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataServiceIntegration.java +++ b/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarStreamingMarketDataServiceIntegration.java @@ -3,7 +3,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.junit.Test; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.Currency; diff --git a/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarUserTradesExample.java b/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarUserTradesExample.java index 4d3cf578220..a69d438f432 100644 --- a/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarUserTradesExample.java +++ b/xchange-stream-coinjar/src/test/java/info/bitrich/xchangestream/coinjar/CoinjarUserTradesExample.java @@ -3,8 +3,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.disposables.Disposable; -import io.reactivex.observers.BaseTestConsumer; +import io.reactivex.rxjava3.disposables.Disposable; +import io.reactivex.rxjava3.observers.BaseTestConsumer; import org.junit.Test; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.utils.AuthUtils; @@ -28,7 +28,7 @@ public void runTest() { streamingTradeService .getUserTrades(null) .test() - .awaitCount(1, BaseTestConsumer.TestWaitStrategy.SLEEP_100MS, 1000 * 60 * 10) + .awaitCount(1) .assertNoErrors(); disposable.dispose(); } diff --git a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingAccountService.java b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingAccountService.java index 6840622d797..46fa1e3c44c 100644 --- a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingAccountService.java +++ b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingAccountService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.coinmate.v2.dto.CoinmateWebsocketBalance; import info.bitrich.xchangestream.core.StreamingAccountService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.ArrayList; import java.util.Arrays; import java.util.HashSet; diff --git a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingExchange.java b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingExchange.java index 4bbee51d3e9..0ef5a9ebe3d 100644 --- a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingExchange.java +++ b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingExchange.java @@ -6,7 +6,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; import org.knowm.xchange.coinmate.CoinmateExchange; public class CoinmateStreamingExchange extends CoinmateExchange implements StreamingExchange { diff --git a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataService.java b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataService.java index f369ba65552..c69d4cfe673 100644 --- a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataService.java +++ b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.coinmate.v2.dto.CoinmateWebSocketTrade; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.List; import org.knowm.xchange.coinmate.CoinmateAdapters; import org.knowm.xchange.coinmate.dto.marketdata.CoinmateOrderBook; diff --git a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingTradeService.java b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingTradeService.java index 01e8c667dda..f9b37ba2a00 100644 --- a/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingTradeService.java +++ b/xchange-stream-coinmate/src/main/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingTradeService.java @@ -7,7 +7,7 @@ import info.bitrich.xchangestream.coinmate.v2.dto.CoinmateWebsocketOpenOrder; import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.Arrays; import java.util.Collections; import java.util.List; diff --git a/xchange-stream-coinmate/src/test/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataServiceTest.java b/xchange-stream-coinmate/src/test/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataServiceTest.java index 994d5f50940..b99c3a2cba4 100644 --- a/xchange-stream-coinmate/src/test/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataServiceTest.java +++ b/xchange-stream-coinmate/src/test/java/info/bitrich/xchangestream/coinmate/v2/CoinmateStreamingMarketDataServiceTest.java @@ -6,8 +6,8 @@ import static org.mockito.Mockito.when; import com.fasterxml.jackson.databind.ObjectMapper; -import io.reactivex.Observable; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.observers.TestObserver; import java.math.BigDecimal; import java.nio.file.Files; import java.nio.file.Paths; diff --git a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingAccountService.java b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingAccountService.java index ca9c9615204..3fa540b82a9 100644 --- a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingAccountService.java +++ b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingAccountService.java @@ -1,6 +1,6 @@ package info.bitrich.xchangestream.core; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.Currency; import org.knowm.xchange.dto.account.Balance; import org.knowm.xchange.exceptions.ExchangeSecurityException; diff --git a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingExchange.java b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingExchange.java index f863996389e..d18a9f3fd75 100644 --- a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingExchange.java +++ b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingExchange.java @@ -3,8 +3,8 @@ import info.bitrich.xchangestream.service.ConnectableService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; import info.bitrich.xchangestream.service.netty.NettyStreamingService; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.Exchange; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.exceptions.NotYetImplementedForExchangeException; diff --git a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingMarketDataService.java b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingMarketDataService.java index 94055ac6507..df0459c4ed6 100644 --- a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingMarketDataService.java +++ b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingMarketDataService.java @@ -1,6 +1,6 @@ package info.bitrich.xchangestream.core; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.marketdata.*; import org.knowm.xchange.exceptions.NotYetImplementedForExchangeException; diff --git a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingTradeService.java b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingTradeService.java index 408e79c1cf6..95bd25317fc 100644 --- a/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingTradeService.java +++ b/xchange-stream-core/src/main/java/info/bitrich/xchangestream/core/StreamingTradeService.java @@ -1,6 +1,6 @@ package info.bitrich.xchangestream.core; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.Order; import org.knowm.xchange.dto.trade.UserTrade; diff --git a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingExchange.java b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingExchange.java index a6f0e7e96af..08e9ad93f33 100644 --- a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingExchange.java +++ b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingExchange.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.dydx.service.v1.dydxStreamingMarketDataService; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.dydx.dydxExchange; import org.slf4j.Logger; diff --git a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingService.java b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingService.java index e5fc3ea26ca..3223588e721 100644 --- a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingService.java +++ b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/dydxStreamingService.java @@ -9,7 +9,7 @@ import info.bitrich.xchangestream.dydx.dto.v3.dydxUpdateOrderBookMessage; import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; diff --git a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v1/dydxStreamingMarketDataService.java b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v1/dydxStreamingMarketDataService.java index 9bb3d2f8ab5..ff3d9919fc8 100644 --- a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v1/dydxStreamingMarketDataService.java +++ b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v1/dydxStreamingMarketDataService.java @@ -8,7 +8,7 @@ import info.bitrich.xchangestream.dydx.dto.v1.dydxInitialOrderBookMessage; import info.bitrich.xchangestream.dydx.dto.v1.dydxUpdateOrderBookMessage; import info.bitrich.xchangestream.dydx.dydxStreamingService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.Comparator; import java.util.List; diff --git a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v3/dydxStreamingMarketDataService.java b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v3/dydxStreamingMarketDataService.java index 27d4457f416..3ec8a94fd92 100644 --- a/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v3/dydxStreamingMarketDataService.java +++ b/xchange-stream-dydx/src/main/java/info/bitrich/xchangestream/dydx/service/v3/dydxStreamingMarketDataService.java @@ -8,7 +8,7 @@ import info.bitrich.xchangestream.dydx.dto.v3.dydxInitialOrderBookMessage; import info.bitrich.xchangestream.dydx.dto.v3.dydxUpdateOrderBookMessage; import info.bitrich.xchangestream.dydx.dydxStreamingService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.Comparator; import java.util.List; diff --git a/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingExchange.java b/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingExchange.java index c28c82d0d3c..c2b7b5c6582 100644 --- a/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingExchange.java +++ b/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingExchange.java @@ -6,8 +6,8 @@ import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.ftx.dto.FtxWebsocketCredential; import info.bitrich.xchangestream.service.netty.ConnectionStateModel; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.ftx.FtxExchange; diff --git a/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataService.java b/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataService.java index 62d53808cbd..3e64d3394a4 100644 --- a/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataService.java +++ b/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataService.java @@ -2,7 +2,7 @@ import com.google.common.collect.Lists; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.marketdata.OrderBook; import org.knowm.xchange.dto.marketdata.Ticker; diff --git a/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingTradeService.java b/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingTradeService.java index 5fc6fead895..0679c6bd5ab 100644 --- a/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingTradeService.java +++ b/xchange-stream-ftx/src/main/java/info/bitrich/xchangestream/ftx/FtxStreamingTradeService.java @@ -2,7 +2,7 @@ import com.fasterxml.jackson.databind.JsonNode; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.Order; import org.knowm.xchange.dto.trade.UserTrade; diff --git a/xchange-stream-ftx/src/test/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataServiceIntegration.java b/xchange-stream-ftx/src/test/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataServiceIntegration.java index 9d80718a5a8..bba73ad4b73 100644 --- a/xchange-stream-ftx/src/test/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataServiceIntegration.java +++ b/xchange-stream-ftx/src/test/java/info/bitrich/xchangestream/ftx/FtxStreamingMarketDataServiceIntegration.java @@ -9,7 +9,7 @@ import info.bitrich.xchangestream.core.StreamingExchangeFactory; import info.bitrich.xchangestream.ftx.dto.FtxOrderbookResponse; import info.bitrich.xchangestream.ftx.dto.FtxTickerResponse; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import java.io.IOException; import java.io.InputStream; import java.math.BigDecimal; diff --git a/xchange-stream-gateio/src/main/java/GateioStreamingExchange.java b/xchange-stream-gateio/src/main/java/GateioStreamingExchange.java index 16b1ae05677..41a7078a6c7 100644 --- a/xchange-stream-gateio/src/main/java/GateioStreamingExchange.java +++ b/xchange-stream-gateio/src/main/java/GateioStreamingExchange.java @@ -1,7 +1,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; import org.knowm.xchange.gateio.GateioExchange; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/xchange-stream-gateio/src/main/java/GateioStreamingMarketDataService.java b/xchange-stream-gateio/src/main/java/GateioStreamingMarketDataService.java index 9eb4ee34381..7bf3715e0e6 100644 --- a/xchange-stream-gateio/src/main/java/GateioStreamingMarketDataService.java +++ b/xchange-stream-gateio/src/main/java/GateioStreamingMarketDataService.java @@ -1,7 +1,7 @@ import dto.response.GateioOrderBookResponse; import dto.response.GateioTradesResponse; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.List; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.marketdata.OrderBook; diff --git a/xchange-stream-gateio/src/main/java/GateioStreamingService.java b/xchange-stream-gateio/src/main/java/GateioStreamingService.java index 878c2f13bee..e2df438894e 100644 --- a/xchange-stream-gateio/src/main/java/GateioStreamingService.java +++ b/xchange-stream-gateio/src/main/java/GateioStreamingService.java @@ -9,7 +9,7 @@ import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; import info.bitrich.xchangestream.service.netty.WebSocketClientCompressionAllowClientNoContextAndServerNoContextHandler; import io.netty.handler.codec.http.websocketx.extensions.WebSocketClientExtensionHandler; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; diff --git a/xchange-stream-gateio/src/test/java/GateioManualExample.java b/xchange-stream-gateio/src/test/java/GateioManualExample.java index be720222698..d8c1ae2dd96 100644 --- a/xchange-stream-gateio/src/test/java/GateioManualExample.java +++ b/xchange-stream-gateio/src/test/java/GateioManualExample.java @@ -1,6 +1,6 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; import org.slf4j.Logger; diff --git a/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java b/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java index b6d614f5731..b645c12bf74 100644 --- a/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java +++ b/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.exceptions.NotYetImplementedForExchangeException; import org.knowm.xchange.gemini.v1.GeminiExchange; diff --git a/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java b/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java index 76c1f597a57..6817f5684ba 100644 --- a/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java +++ b/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java @@ -2,7 +2,7 @@ import com.google.common.base.MoreObjects; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.Map; import java.util.SortedMap; diff --git a/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java b/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java index 818af4cdf06..5d08ba20acd 100644 --- a/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java +++ b/xchange-stream-gemini-v2/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java @@ -8,7 +8,7 @@ import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; import io.netty.util.internal.StringUtil; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; diff --git a/xchange-stream-gemini-v2/src/test/java/info/bitrich/xchangestream/gemini/GeminiManualExample.java b/xchange-stream-gemini-v2/src/test/java/info/bitrich/xchangestream/gemini/GeminiManualExample.java index dc5ab60bf90..64705a8b2b6 100644 --- a/xchange-stream-gemini-v2/src/test/java/info/bitrich/xchangestream/gemini/GeminiManualExample.java +++ b/xchange-stream-gemini-v2/src/test/java/info/bitrich/xchangestream/gemini/GeminiManualExample.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; import org.slf4j.Logger; diff --git a/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java b/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java index 2732cdaa146..61f2d9501ee 100644 --- a/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java +++ b/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingExchange.java @@ -4,9 +4,9 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.CompletableEmitter; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.CompletableEmitter; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.exceptions.NotYetImplementedForExchangeException; import org.knowm.xchange.gemini.v1.GeminiExchange; diff --git a/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java b/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java index d692ce5f7f2..67d35a41186 100644 --- a/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java +++ b/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingMarketDataService.java @@ -10,8 +10,8 @@ import info.bitrich.xchangestream.gemini.dto.GeminiOrderbook; import info.bitrich.xchangestream.gemini.dto.GeminiWebSocketTransaction; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; -import io.reactivex.subjects.PublishSubject; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.subjects.PublishSubject; import java.util.Date; import java.util.HashMap; import java.util.Map; diff --git a/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java b/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java index 23ad27a172c..9f3a5891a09 100644 --- a/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java +++ b/xchange-stream-gemini/src/main/java/info/bitrich/xchangestream/gemini/GeminiStreamingService.java @@ -2,9 +2,9 @@ import com.fasterxml.jackson.databind.JsonNode; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Observable; -import io.reactivex.subjects.BehaviorSubject; -import io.reactivex.subjects.Subject; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.subjects.BehaviorSubject; +import io.reactivex.rxjava3.subjects.Subject; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingExchange.java b/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingExchange.java index a987dd67e73..d71b9fa6515 100644 --- a/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingExchange.java +++ b/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.hitbtc.v2.HitbtcExchange; diff --git a/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataService.java b/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataService.java index 69556ef7b09..5e6ebabf5e2 100644 --- a/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataService.java +++ b/xchange-stream-hitbtc/src/main/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataService.java @@ -9,7 +9,7 @@ import info.bitrich.xchangestream.hitbtc.dto.HitbtcWebSocketTradeParams; import info.bitrich.xchangestream.hitbtc.dto.HitbtcWebSocketTradesTransaction; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.Arrays; import java.util.HashMap; import java.util.Map; diff --git a/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcManualExample.java b/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcManualExample.java index ae55e17c021..8bd3bbd4ede 100644 --- a/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcManualExample.java +++ b/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcManualExample.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.knowm.xchange.currency.CurrencyPair; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataServiceTest.java b/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataServiceTest.java index e89d82bce97..3b1b841f33e 100644 --- a/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataServiceTest.java +++ b/xchange-stream-hitbtc/src/test/java/info/bitrich/xchangestream/hitbtc/HitbtcStreamingMarketDataServiceTest.java @@ -5,8 +5,8 @@ import static org.mockito.Mockito.when; import com.fasterxml.jackson.databind.ObjectMapper; -import io.reactivex.Observable; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.observers.TestObserver; import java.math.BigDecimal; import java.nio.charset.StandardCharsets; import java.nio.file.Files; diff --git a/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingExchange.java b/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingExchange.java index f60b410a52c..339295aed2a 100644 --- a/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingExchange.java +++ b/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.huobi.HuobiExchange; public class HuobiStreamingExchange extends HuobiExchange implements StreamingExchange { diff --git a/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingMarketDataService.java b/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingMarketDataService.java index 9605f9bb851..ea0e8d4341d 100644 --- a/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingMarketDataService.java +++ b/xchange-stream-huobi/src/main/java/info/bitrich/xchangestream/huobi/HuobiStreamingMarketDataService.java @@ -2,7 +2,7 @@ import com.fasterxml.jackson.databind.JsonNode; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.ArrayList; import java.util.Date; diff --git a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingExchange.java b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingExchange.java index 5a635e5dbcd..b63dd49101b 100644 --- a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingExchange.java +++ b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingExchange.java @@ -9,8 +9,8 @@ import info.bitrich.xchangestream.kraken.dto.KrakenSystemStatus; import info.bitrich.xchangestream.kraken.dto.enums.KrakenEventType; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import org.apache.commons.lang3.StringUtils; diff --git a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingMarketDataService.java b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingMarketDataService.java index 7e24ba8e768..8d88c242b87 100644 --- a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingMarketDataService.java +++ b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingMarketDataService.java @@ -5,7 +5,7 @@ import com.google.common.collect.Sets; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.kraken.dto.enums.KrakenSubscriptionName; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.TreeSet; import org.apache.commons.lang3.ObjectUtils; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingService.java b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingService.java index e6dbff1a9e4..8cf3a01a9e0 100644 --- a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingService.java +++ b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingService.java @@ -25,9 +25,9 @@ import java.util.concurrent.ConcurrentHashMap; import java.util.function.Supplier; -import io.reactivex.Completable; -import io.reactivex.Observable; -import io.reactivex.ObservableEmitter; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.core.ObservableEmitter; import org.apache.commons.lang3.ArrayUtils; import org.apache.commons.lang3.StringUtils; import org.knowm.xchange.exceptions.ExchangeException; diff --git a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingTradeService.java b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingTradeService.java index 6779ce72b67..9e3faf57458 100644 --- a/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingTradeService.java +++ b/xchange-stream-kraken/src/main/java/info/bitrich/xchangestream/kraken/KrakenStreamingTradeService.java @@ -6,7 +6,7 @@ import info.bitrich.xchangestream.kraken.dto.KrakenOwnTrade; import info.bitrich.xchangestream.kraken.dto.enums.KrakenSubscriptionName; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.ArrayList; import java.util.Date; import java.util.HashMap; diff --git a/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenOrderbookExample.java b/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenOrderbookExample.java index 9d0cf317eeb..476f61e953a 100644 --- a/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenOrderbookExample.java +++ b/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenOrderbookExample.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import java.math.BigDecimal; import java.util.concurrent.TimeUnit; import org.knowm.xchange.ExchangeSpecification; diff --git a/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTickerExample.java b/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTickerExample.java index a708926b92d..eba7d09c742 100644 --- a/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTickerExample.java +++ b/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTickerExample.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import java.util.concurrent.TimeUnit; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTradesExample.java b/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTradesExample.java index 99ddafe29ae..30bf86e224d 100644 --- a/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTradesExample.java +++ b/xchange-stream-kraken/src/test/java/info/bitrich/xchangestream/kraken/KrakenTradesExample.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import java.util.concurrent.TimeUnit; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingExchange.java b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingExchange.java index aec931eb4d9..375669f7650 100644 --- a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingExchange.java +++ b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingExchange.java @@ -5,8 +5,8 @@ import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.krakenfutures.KrakenFuturesExchange; import org.slf4j.Logger; import org.slf4j.LoggerFactory; diff --git a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingMarketDataService.java b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingMarketDataService.java index 4b2898032ea..6b14f0f1f34 100644 --- a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingMarketDataService.java +++ b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingMarketDataService.java @@ -7,7 +7,7 @@ import info.bitrich.xchangestream.krakenfutures.dto.KrakenFuturesStreamingTickerResponse; import info.bitrich.xchangestream.krakenfutures.dto.KrakenFuturesStreamingTradeResponse; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.dto.Order; import org.knowm.xchange.dto.marketdata.*; import org.knowm.xchange.dto.trade.LimitOrder; diff --git a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingService.java b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingService.java index 820729163fe..bf286cee8b9 100644 --- a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingService.java +++ b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingService.java @@ -7,7 +7,7 @@ import info.bitrich.xchangestream.krakenfutures.dto.KrakenFuturesStreamingWebsocketMessage; import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; import org.apache.commons.lang3.NotImplementedException; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.krakenfutures.service.KrakenFuturesDigest; diff --git a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingTradeService.java b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingTradeService.java index 338962d9571..c68473888dc 100644 --- a/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingTradeService.java +++ b/xchange-stream-krakenfutures/src/main/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingTradeService.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.krakenfutures.dto.KrakenFuturesStreamingFillsDeltaResponse; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.dto.trade.UserTrade; import org.knowm.xchange.instrument.Instrument; diff --git a/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPrivateDataTest.java b/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPrivateDataTest.java index d83bd3ca0b9..cb5745af1e7 100644 --- a/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPrivateDataTest.java +++ b/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPrivateDataTest.java @@ -2,7 +2,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.junit.Before; import org.junit.Ignore; import org.junit.Test; diff --git a/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPublicDataTest.java b/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPublicDataTest.java index 1b13663d87e..71a44391f7b 100644 --- a/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPublicDataTest.java +++ b/xchange-stream-krakenfutures/src/test/java/info/bitrich/xchangestream/krakenfutures/KrakenFuturesStreamingPublicDataTest.java @@ -3,7 +3,7 @@ import info.bitrich.xchangestream.core.ProductSubscription; import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; import org.junit.Before; import org.junit.Test; import org.knowm.xchange.derivative.FuturesContract; @@ -47,7 +47,7 @@ public void checkStreamingTicker() { return ticker; }) .test() - .assertSubscribed() + .assertNoErrors() .awaitCount(1) .assertValue(ticker -> ticker.getInstrument().equals(instrument)) .dispose(); @@ -62,7 +62,7 @@ public void checkStreamingFundingRate() { return fundingRate; }) .test() - .assertSubscribed() + .assertNoErrors() .awaitCount(1) .assertValue(fundingRate -> fundingRate.getFundingRateEffectiveInMinutes() < 61 && fundingRate.getFundingRate1h() != null) .dispose(); diff --git a/xchange-stream-kucoin/pom.xml b/xchange-stream-kucoin/pom.xml index 33beba770dd..cbc595cc46f 100644 --- a/xchange-stream-kucoin/pom.xml +++ b/xchange-stream-kucoin/pom.xml @@ -34,4 +34,4 @@ - \ No newline at end of file + diff --git a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingExchange.java b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingExchange.java index 24c6afebaea..e736b4fa4bc 100644 --- a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingExchange.java +++ b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingExchange.java @@ -5,8 +5,8 @@ import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.service.netty.NettyStreamingService; import info.bitrich.xchangestream.util.Events; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.kucoin.KucoinExchange; import org.knowm.xchange.kucoin.dto.response.WebsocketResponse; diff --git a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingMarketDataService.java b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingMarketDataService.java index 8f7113bc7be..a5b2fb48178 100644 --- a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingMarketDataService.java +++ b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingMarketDataService.java @@ -6,8 +6,8 @@ import info.bitrich.xchangestream.kucoin.dto.KucoinOrderBookEvent; import info.bitrich.xchangestream.kucoin.dto.KucoinTickerEvent; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; -import io.reactivex.functions.Consumer; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.functions.Consumer; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.marketdata.OrderBook; import org.knowm.xchange.dto.marketdata.Ticker; diff --git a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingService.java b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingService.java index dfcf8007bea..5f14a2e1d61 100644 --- a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingService.java +++ b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingService.java @@ -7,10 +7,10 @@ import info.bitrich.xchangestream.service.netty.WebSocketClientHandler; import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.http.websocketx.WebSocketClientHandshaker; -import io.reactivex.Completable; -import io.reactivex.CompletableSource; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.CompletableSource; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; import java.io.IOException; import java.util.concurrent.TimeUnit; diff --git a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingTradeService.java b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingTradeService.java index 34a1e656ab7..d620da43cdb 100644 --- a/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingTradeService.java +++ b/xchange-stream-kucoin/src/main/java/info/bitrich/xchangestream/kucoin/KucoinStreamingTradeService.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.kucoin.dto.KucoinWebSocketOrderEvent; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.Order; import org.slf4j.Logger; diff --git a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoLevel2BatchSubscription.java b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoLevel2BatchSubscription.java index f36fc5a8671..4db4157e7d6 100644 --- a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoLevel2BatchSubscription.java +++ b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoLevel2BatchSubscription.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.lgo.domain.LgoGroupedLevel2Update; import info.bitrich.xchangestream.lgo.dto.LgoLevel2Update; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.marketdata.OrderBook; diff --git a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountService.java b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountService.java index 684e941d005..2c9fce22467 100644 --- a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountService.java +++ b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountService.java @@ -5,7 +5,7 @@ import info.bitrich.xchangestream.lgo.domain.LgoGroupedBalanceUpdate; import info.bitrich.xchangestream.lgo.dto.LgoBalanceUpdate; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.List; import org.knowm.xchange.currency.Currency; import org.knowm.xchange.dto.account.Balance; diff --git a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingExchange.java b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingExchange.java index fc5d837d0fc..b0aa26bb9eb 100644 --- a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingExchange.java +++ b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.lgo.LgoEnv; import org.knowm.xchange.lgo.LgoExchange; diff --git a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataService.java b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataService.java index ddb6ed16296..71e83feda54 100644 --- a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataService.java +++ b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataService.java @@ -1,7 +1,7 @@ package info.bitrich.xchangestream.lgo; import info.bitrich.xchangestream.core.StreamingMarketDataService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.Map; import java.util.concurrent.ConcurrentHashMap; import org.knowm.xchange.currency.CurrencyPair; diff --git a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeService.java b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeService.java index f29437725da..0db78aa8d1c 100644 --- a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeService.java +++ b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeService.java @@ -9,7 +9,7 @@ import info.bitrich.xchangestream.lgo.dto.LgoAckUpdate; import info.bitrich.xchangestream.lgo.dto.LgoSocketPlaceOrder; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.util.Collection; import java.util.Date; diff --git a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoTradeBatchSubscription.java b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoTradeBatchSubscription.java index 52152fa50bd..15a99e5044e 100644 --- a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoTradeBatchSubscription.java +++ b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoTradeBatchSubscription.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.lgo.domain.LgoGroupedTradeUpdate; import info.bitrich.xchangestream.lgo.dto.LgoTradesUpdate; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import org.knowm.xchange.currency.CurrencyPair; import org.knowm.xchange.dto.marketdata.Trade; diff --git a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoUserBatchSubscription.java b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoUserBatchSubscription.java index 8a2ae6a8f88..98fbfb0afaa 100644 --- a/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoUserBatchSubscription.java +++ b/xchange-stream-lgo/src/main/java/info/bitrich/xchangestream/lgo/LgoUserBatchSubscription.java @@ -9,7 +9,7 @@ import info.bitrich.xchangestream.lgo.dto.LgoUserSnapshot; import info.bitrich.xchangestream.lgo.dto.LgoUserUpdate; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.util.ArrayList; import java.util.Collection; import java.util.List; diff --git a/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountServiceTest.java b/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountServiceTest.java index f681612f097..99b3f9f32f6 100644 --- a/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountServiceTest.java +++ b/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingAccountServiceTest.java @@ -7,8 +7,8 @@ import static org.mockito.Mockito.when; import com.fasterxml.jackson.databind.JsonNode; -import io.reactivex.Observable; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.observers.TestObserver; import java.io.IOException; import java.math.BigDecimal; import java.util.Arrays; @@ -30,7 +30,7 @@ public void it_gives_initial_wallet_snapshot() throws IOException { TestObserver wallet = service.getWallet().test(); verify(streamingService).subscribeChannel("balance"); - wallet.assertSubscribed(); + wallet.assertNoErrors(); wallet.assertValueCount(1); wallet .values() diff --git a/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataServiceTest.java b/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataServiceTest.java index 61d5c21149d..8ddb821406b 100644 --- a/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataServiceTest.java +++ b/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingMarketDataServiceTest.java @@ -7,7 +7,7 @@ import static org.mockito.Mockito.when; import com.fasterxml.jackson.databind.JsonNode; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.math.BigDecimal; import java.text.ParseException; diff --git a/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeServiceTest.java b/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeServiceTest.java index 3b951b341e0..99d8bec119f 100644 --- a/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeServiceTest.java +++ b/xchange-stream-lgo/src/test/java/info/bitrich/xchangestream/lgo/LgoStreamingTradeServiceTest.java @@ -15,7 +15,7 @@ import info.bitrich.xchangestream.lgo.domain.LgoOrderEvent; import info.bitrich.xchangestream.lgo.domain.LgoPendingOrderEvent; import info.bitrich.xchangestream.lgo.domain.LgoReceivedOrderEvent; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.math.BigDecimal; import java.net.URISyntaxException; diff --git a/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingExchange.java b/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingExchange.java index aa51e3e38c1..b124480700f 100644 --- a/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingExchange.java +++ b/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingExchange.java @@ -4,8 +4,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.okcoin.OkCoinExchange; public class OkCoinStreamingExchange extends OkCoinExchange implements StreamingExchange { diff --git a/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataService.java b/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataService.java index afad735b045..2984e8ced42 100644 --- a/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataService.java +++ b/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataService.java @@ -6,7 +6,7 @@ import info.bitrich.xchangestream.okcoin.dto.OkCoinWebSocketTrade; import info.bitrich.xchangestream.okcoin.dto.marketdata.FutureTicker; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.HashMap; import java.util.Map; diff --git a/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingService.java b/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingService.java index b5f3318fd02..2e9ae82a95a 100644 --- a/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingService.java +++ b/xchange-stream-okcoin/src/main/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingService.java @@ -10,10 +10,10 @@ import io.netty.handler.codec.http.websocketx.BinaryWebSocketFrame; import io.netty.handler.codec.http.websocketx.WebSocketClientHandshaker; import io.netty.handler.codec.http.websocketx.WebSocketFrame; -import io.reactivex.Completable; -import io.reactivex.CompletableSource; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.CompletableSource; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; import java.io.IOException; import java.nio.charset.StandardCharsets; import java.util.concurrent.TimeUnit; diff --git a/xchange-stream-okcoin/src/test/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataServiceTest.java b/xchange-stream-okcoin/src/test/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataServiceTest.java index e33772d14f8..86ad0a771f7 100644 --- a/xchange-stream-okcoin/src/test/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataServiceTest.java +++ b/xchange-stream-okcoin/src/test/java/info/bitrich/xchangestream/okcoin/OkCoinStreamingMarketDataServiceTest.java @@ -5,8 +5,8 @@ import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; -import io.reactivex.Observable; -import io.reactivex.observers.TestObserver; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.observers.TestObserver; import java.math.BigDecimal; import java.util.ArrayList; import java.util.Date; diff --git a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingExchange.java b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingExchange.java index ff6b6c28c95..1aac419e3da 100644 --- a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingExchange.java +++ b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingExchange.java @@ -4,7 +4,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.core.StreamingTradeService; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; import org.knowm.xchange.ExchangeSpecification; import org.knowm.xchange.exceptions.NotYetImplementedForExchangeException; import org.knowm.xchange.okex.OkexExchange; diff --git a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingMarketDataService.java b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingMarketDataService.java index 0ad5a08b423..87d62f59467 100644 --- a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingMarketDataService.java +++ b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingMarketDataService.java @@ -5,8 +5,8 @@ import com.fasterxml.jackson.databind.ObjectMapper; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; -import io.reactivex.subjects.PublishSubject; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.subjects.PublishSubject; import java.sql.Timestamp; import java.util.*; import java.util.concurrent.ConcurrentHashMap; diff --git a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingService.java b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingService.java index 419a764b6a5..52d39afe99e 100644 --- a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingService.java +++ b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingService.java @@ -5,10 +5,10 @@ import info.bitrich.xchangestream.okex.dto.OkexLoginMessage; import info.bitrich.xchangestream.okex.dto.OkexSubscribeMessage; import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; -import io.reactivex.Completable; -import io.reactivex.CompletableSource; -import io.reactivex.Observable; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.CompletableSource; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.disposables.Disposable; import java.io.IOException; import java.nio.charset.StandardCharsets; import java.security.InvalidKeyException; diff --git a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingTradeService.java b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingTradeService.java index 30bdde92d1e..5689b9947c3 100644 --- a/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingTradeService.java +++ b/xchange-stream-okex/src/main/java/info/bitrich/xchangestream/okex/OkexStreamingTradeService.java @@ -3,7 +3,7 @@ import com.fasterxml.jackson.databind.ObjectMapper; import info.bitrich.xchangestream.core.StreamingTradeService; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.dto.meta.ExchangeMetaData; import org.knowm.xchange.dto.trade.UserTrade; import org.knowm.xchange.instrument.Instrument; diff --git a/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPrivateDataIntegtration.java b/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPrivateDataIntegtration.java index 4a030eaf6e7..9c6b2e4d8ac 100644 --- a/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPrivateDataIntegtration.java +++ b/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPrivateDataIntegtration.java @@ -14,7 +14,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; @Ignore public class OkexStreamingPrivateDataIntegtration { diff --git a/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPublicDataIntegration.java b/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPublicDataIntegration.java index b67deeed398..4bc39771ea1 100644 --- a/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPublicDataIntegration.java +++ b/xchange-stream-okex/src/test/java/info/bitrich/xchangestream/okex/OkexStreamingPublicDataIntegration.java @@ -12,7 +12,7 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingExchangeFactory; -import io.reactivex.disposables.Disposable; +import io.reactivex.rxjava3.disposables.Disposable; public class OkexStreamingPublicDataIntegration { diff --git a/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingExchange.java b/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingExchange.java index 3a36645ee4e..1f4193721c4 100644 --- a/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingExchange.java +++ b/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingExchange.java @@ -7,8 +7,8 @@ import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel.State; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.net.URL; import java.util.HashMap; diff --git a/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingMarketDataService.java b/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingMarketDataService.java index 65c552fa631..eb67b5e613d 100644 --- a/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingMarketDataService.java +++ b/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingMarketDataService.java @@ -17,7 +17,7 @@ import info.bitrich.xchangestream.poloniex2.dto.PoloniexWebSocketTickerTransaction; import info.bitrich.xchangestream.poloniex2.dto.PoloniexWebSocketTradeEvent; import info.bitrich.xchangestream.service.netty.StreamingObjectMapperHelper; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.math.BigDecimal; import java.util.List; import java.util.Map; diff --git a/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingService.java b/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingService.java index 98a8a47ac8a..3f22d3f13d9 100644 --- a/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingService.java +++ b/xchange-stream-poloniex2/src/main/java/info/bitrich/xchangestream/poloniex2/PoloniexStreamingService.java @@ -6,7 +6,7 @@ import info.bitrich.xchangestream.poloniex2.dto.PoloniexWebSocketOrderbookModifiedEvent; import info.bitrich.xchangestream.poloniex2.dto.PoloniexWebSocketSubscriptionMessage; import info.bitrich.xchangestream.service.netty.JsonNettyStreamingService; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Observable; import java.io.IOException; import java.util.List; import java.util.Map; diff --git a/xchange-stream-serum/src/main/java/info/bitrich/xchangestream/serum/SerumStreamingExchange.java b/xchange-stream-serum/src/main/java/info/bitrich/xchangestream/serum/SerumStreamingExchange.java index 20eeb2233ca..c946df3c05f 100644 --- a/xchange-stream-serum/src/main/java/info/bitrich/xchangestream/serum/SerumStreamingExchange.java +++ b/xchange-stream-serum/src/main/java/info/bitrich/xchangestream/serum/SerumStreamingExchange.java @@ -6,8 +6,8 @@ import info.bitrich.xchangestream.core.StreamingExchange; import info.bitrich.xchangestream.core.StreamingMarketDataService; import info.bitrich.xchangestream.service.netty.ConnectionStateModel; -import io.reactivex.Completable; -import io.reactivex.Observable; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; import org.knowm.xchange.ExchangeSpecification; public class SerumStreamingExchange extends SerumExchange implements StreamingExchange { diff --git a/xchange-stream-service-core/pom.xml b/xchange-stream-service-core/pom.xml index 9a2a333617b..584b8633bba 100644 --- a/xchange-stream-service-core/pom.xml +++ b/xchange-stream-service-core/pom.xml @@ -15,9 +15,9 @@ - io.reactivex.rxjava2 + io.reactivex.rxjava3 rxjava - \ No newline at end of file + diff --git a/xchange-stream-service-core/src/main/java/info/bitrich/xchangestream/service/ConnectableService.java b/xchange-stream-service-core/src/main/java/info/bitrich/xchangestream/service/ConnectableService.java index ff2aa44b3e3..6939a964cfa 100644 --- a/xchange-stream-service-core/src/main/java/info/bitrich/xchangestream/service/ConnectableService.java +++ b/xchange-stream-service-core/src/main/java/info/bitrich/xchangestream/service/ConnectableService.java @@ -1,6 +1,6 @@ package info.bitrich.xchangestream.service; -import io.reactivex.Completable; +import io.reactivex.rxjava3.core.Completable; /** Base class of streaming services, declares connect() method including before connection logic */ public abstract class ConnectableService { diff --git a/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/ConnectionStateModel.java b/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/ConnectionStateModel.java index 2b0599169d1..273d94c4840 100644 --- a/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/ConnectionStateModel.java +++ b/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/ConnectionStateModel.java @@ -1,8 +1,8 @@ package info.bitrich.xchangestream.service.netty; -import io.reactivex.Observable; -import io.reactivex.subjects.BehaviorSubject; -import io.reactivex.subjects.Subject; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.subjects.BehaviorSubject; +import io.reactivex.rxjava3.subjects.Subject; import java.util.concurrent.atomic.AtomicReference; /** diff --git a/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/NettyStreamingService.java b/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/NettyStreamingService.java index 925d9ad1e53..2b9e4dc6d86 100644 --- a/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/NettyStreamingService.java +++ b/xchange-stream-service-netty/src/main/java/info/bitrich/xchangestream/service/netty/NettyStreamingService.java @@ -36,11 +36,11 @@ import io.netty.handler.timeout.IdleStateHandler; import io.netty.util.internal.SocketUtils; import io.netty.util.internal.StringUtil; -import io.reactivex.Completable; -import io.reactivex.Observable; -import io.reactivex.ObservableEmitter; -import io.reactivex.subjects.PublishSubject; -import io.reactivex.subjects.Subject; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.core.ObservableEmitter; +import io.reactivex.rxjava3.subjects.PublishSubject; +import io.reactivex.rxjava3.subjects.Subject; import java.io.IOException; import java.net.URI; import java.net.URISyntaxException; diff --git a/xchange-stream-service-pubnub/pom.xml b/xchange-stream-service-pubnub/pom.xml index 6f73e624a4f..1d531196635 100644 --- a/xchange-stream-service-pubnub/pom.xml +++ b/xchange-stream-service-pubnub/pom.xml @@ -19,7 +19,7 @@ - io.reactivex.rxjava2 + io.reactivex.rxjava3 rxjava @@ -29,4 +29,4 @@ - \ No newline at end of file + diff --git a/xchange-stream-service-pubnub/src/main/java/info/bitrich/xchangestream/service/pubnub/PubnubStreamingService.java b/xchange-stream-service-pubnub/src/main/java/info/bitrich/xchangestream/service/pubnub/PubnubStreamingService.java index 6880c4e6080..86966cd215b 100644 --- a/xchange-stream-service-pubnub/src/main/java/info/bitrich/xchangestream/service/pubnub/PubnubStreamingService.java +++ b/xchange-stream-service-pubnub/src/main/java/info/bitrich/xchangestream/service/pubnub/PubnubStreamingService.java @@ -15,9 +15,9 @@ import com.pubnub.api.models.consumer.pubsub.objects.PNMembershipResult; import com.pubnub.api.models.consumer.pubsub.objects.PNSpaceResult; import com.pubnub.api.models.consumer.pubsub.objects.PNUserResult; -import io.reactivex.Completable; -import io.reactivex.Observable; -import io.reactivex.ObservableEmitter; +import io.reactivex.rxjava3.core.Completable; +import io.reactivex.rxjava3.core.Observable; +import io.reactivex.rxjava3.core.ObservableEmitter; import java.io.IOException; import java.util.Collections; import java.util.Map;