Skip to content

Commit

Permalink
bump nbxplorer
Browse files Browse the repository at this point in the history
  • Loading branch information
luislng committed Nov 21, 2018
1 parent b19c196 commit 59bde2c
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion BTCPayServer.Tests/UnitTest1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,7 @@ public void CanRBFPayment()
output.ScriptPubKey = invoiceAddress.ScriptPubKey;

using (var cts = new CancellationTokenSource(10000))
using (var listener = tester.ExplorerClient.CreateNotificationSession())
using (var listener = tester.ExplorerClient.CreateWebsocketNotificationSession())
{
listener.ListenAllDerivationSchemes();
var replaced = tester.ExplorerNode.SignRawTransaction(tx);
Expand Down
2 changes: 1 addition & 1 deletion BTCPayServer.Tests/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ services:


nbxplorer:
image: nicolasdorier/nbxplorer:1.1.0.18
image: nicolasdorier/nbxplorer:2.0.0.0
restart: unless-stopped
ports:
- "32838:32838"
Expand Down
2 changes: 1 addition & 1 deletion BTCPayServer/BTCPayServer.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
<PackageReference Include="NBitcoin" Version="4.1.1.71" />
<PackageReference Include="NBitpayClient" Version="1.0.0.30" />
<PackageReference Include="DBreeze" Version="1.92.0" />
<PackageReference Include="NBXplorer.Client" Version="1.0.3.11" />
<PackageReference Include="NBXplorer.Client" Version="2.0.0" />
<PackageReference Include="NicolasDorier.CommandLine" Version="1.0.0.2" />
<PackageReference Include="NicolasDorier.CommandLine.Configuration" Version="1.0.0.3" />
<PackageReference Include="NicolasDorier.RateLimits" Version="1.0.0.3" />
Expand Down
6 changes: 3 additions & 3 deletions BTCPayServer/Payments/Bitcoin/NBXplorerListener.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public NBXplorerListener(ExplorerClientProvider explorerClients,
}

CompositeDisposable leases = new CompositeDisposable();
ConcurrentDictionary<string, NotificationSession> _SessionsByCryptoCode = new ConcurrentDictionary<string, NotificationSession>();
ConcurrentDictionary<string, WebsocketNotificationSession> _SessionsByCryptoCode = new ConcurrentDictionary<string, WebsocketNotificationSession>();
private Timer _ListenPoller;

TimeSpan _PollInterval;
Expand Down Expand Up @@ -114,7 +114,7 @@ private async Task Listen(BTCPayWallet wallet)
return;
if (_Cts.IsCancellationRequested)
return;
var session = await client.CreateNotificationSessionAsync(_Cts.Token).ConfigureAwait(false);
var session = await client.CreateWebsocketNotificationSessionAsync(_Cts.Token).ConfigureAwait(false);
if (!_SessionsByCryptoCode.TryAdd(network.CryptoCode, session))
{
await session.DisposeAsync();
Expand Down Expand Up @@ -187,7 +187,7 @@ await Task.WhenAll((await _InvoiceRepository.GetPendingInvoices())
if (cleanup)
{
Logs.PayServer.LogInformation($"Disconnected from WebSocket of NBXplorer ({network.CryptoCode})");
_SessionsByCryptoCode.TryRemove(network.CryptoCode, out NotificationSession unused);
_SessionsByCryptoCode.TryRemove(network.CryptoCode, out WebsocketNotificationSession unused);
if (_SessionsByCryptoCode.Count == 0 && _Cts.IsCancellationRequested)
{
_RunningTask.TrySetResult(true);
Expand Down
4 changes: 2 additions & 2 deletions BTCPayServer/Services/Wallets/BTCPayWallet.cs
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ private async Task<UTXOChanges> GetUTXOChanges(DerivationStrategyBase strategy,
UTXOChanges result = null;
try
{
result = await _Client.GetUTXOsAsync(strategy, null, false, cancellation).ConfigureAwait(false);
result = await _Client.GetUTXOsAsync(strategy, cancellation).ConfigureAwait(false);
}
catch
{
Expand Down Expand Up @@ -153,7 +153,7 @@ private async Task<UTXOChanges> GetUTXOChanges(DerivationStrategyBase strategy,

public Task<GetTransactionsResponse> FetchTransactions(DerivationStrategyBase derivationStrategyBase)
{
return _Client.GetTransactionsAsync(derivationStrategyBase, null, false);
return _Client.GetTransactionsAsync(derivationStrategyBase);
}

public Task<BroadcastResult[]> BroadcastTransactionsAsync(List<Transaction> transactions)
Expand Down

0 comments on commit 59bde2c

Please sign in to comment.