mirror of
https://github.com/btcpayserver/btcpayserver.git
synced 2025-02-22 22:25:28 +01:00
Add debug messages
This commit is contained in:
parent
b47b4b10cb
commit
5ba322ea6a
3 changed files with 7 additions and 1 deletions
|
@ -25,6 +25,7 @@ using Microsoft.Extensions.Caching.Memory;
|
||||||
using BTCPayServer.Eclair;
|
using BTCPayServer.Eclair;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using BTCPayServer.Models.StoreViewModels;
|
using BTCPayServer.Models.StoreViewModels;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
namespace BTCPayServer.Tests
|
namespace BTCPayServer.Tests
|
||||||
{
|
{
|
||||||
|
|
|
@ -412,6 +412,7 @@ namespace BTCPayServer.HostedServices
|
||||||
{
|
{
|
||||||
if (invoiceId == null)
|
if (invoiceId == null)
|
||||||
throw new ArgumentNullException(nameof(invoiceId));
|
throw new ArgumentNullException(nameof(invoiceId));
|
||||||
|
Logs.PayServer.LogInformation($"Watching {invoiceId}");
|
||||||
_WatchRequests.Add(invoiceId);
|
_WatchRequests.Add(invoiceId);
|
||||||
var invoice = await _InvoiceRepository.GetInvoice(null, invoiceId);
|
var invoice = await _InvoiceRepository.GetInvoice(null, invoiceId);
|
||||||
try
|
try
|
||||||
|
@ -485,6 +486,7 @@ namespace BTCPayServer.HostedServices
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
Logs.PayServer.LogInformation($"Updating {i}");
|
||||||
await UpdateInvoice(i, cancellation);
|
await UpdateInvoice(i, cancellation);
|
||||||
}
|
}
|
||||||
catch (Exception ex) when (!cancellation.IsCancellationRequested)
|
catch (Exception ex) when (!cancellation.IsCancellationRequested)
|
||||||
|
@ -492,7 +494,9 @@ namespace BTCPayServer.HostedServices
|
||||||
Logs.PayServer.LogCritical(ex, $"Error in the InvoiceWatcher loop (Invoice {i})");
|
Logs.PayServer.LogCritical(ex, $"Error in the InvoiceWatcher loop (Invoice {i})");
|
||||||
await Task.Delay(2000, cancellation);
|
await Task.Delay(2000, cancellation);
|
||||||
}
|
}
|
||||||
finally { executing.TryRemove(i, out Task useless); }
|
finally {
|
||||||
|
Logs.PayServer.LogInformation($"Updated {i}");
|
||||||
|
executing.TryRemove(i, out Task useless); }
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,6 +45,7 @@ namespace BTCPayServer
|
||||||
.ConfigureLogging(l =>
|
.ConfigureLogging(l =>
|
||||||
{
|
{
|
||||||
l.AddFilter("Microsoft", LogLevel.Error);
|
l.AddFilter("Microsoft", LogLevel.Error);
|
||||||
|
l.AddFilter("Microsoft.AspNetCore.Antiforgery.Internal", LogLevel.Critical);
|
||||||
l.AddProvider(new CustomConsoleLogProvider(processor));
|
l.AddProvider(new CustomConsoleLogProvider(processor));
|
||||||
})
|
})
|
||||||
.UseStartup<Startup>()
|
.UseStartup<Startup>()
|
||||||
|
|
Loading…
Add table
Reference in a new issue