mirror of
https://github.com/nsnail/Ocelot.git
synced 2025-04-22 06:22:50 +08:00
This commit is contained in:
parent
f934620538
commit
0b9ff92549
@ -2,6 +2,7 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
namespace Ocelot.RateLimit
|
namespace Ocelot.RateLimit
|
||||||
{
|
{
|
||||||
@ -10,10 +11,11 @@ namespace Ocelot.RateLimit
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public struct RateLimitCounter
|
public struct RateLimitCounter
|
||||||
{
|
{
|
||||||
public RateLimitCounter(DateTime timestamp, long totalRequest)
|
[JsonConstructor]
|
||||||
|
public RateLimitCounter(DateTime timestamp, long totalRequests)
|
||||||
{
|
{
|
||||||
Timestamp = timestamp;
|
Timestamp = timestamp;
|
||||||
TotalRequests = totalRequest;
|
TotalRequests = totalRequests;
|
||||||
}
|
}
|
||||||
|
|
||||||
public DateTime Timestamp { get; private set; }
|
public DateTime Timestamp { get; private set; }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user