Procházet zdrojové kódy

fix: health check path is changed to 'cap/api/health' (#921)

master
wu před 3 roky
committed by GitHub
rodič
revize
470d0e9d26
V databázi nebyl nalezen žádný známý klíč pro tento podpis ID GPG klíče: 4AEE18F83AFDEB23
2 změnil soubory, kde provedl 9 přidání a 9 odebrání
  1. +7
    -7
      src/DotNetCore.CAP.Dashboard/CapCache.cs
  2. +2
    -2
      src/DotNetCore.CAP.Dashboard/NodeDiscovery/INodeDiscoveryProvider.Consul.cs

+ 7
- 7
src/DotNetCore.CAP.Dashboard/CapCache.cs Zobrazit soubor

@@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
@@ -15,7 +15,7 @@ namespace DotNetCore.CAP.Dashboard
/// </summary>
// ReSharper disable once InheritdocConsiderUsage
// ReSharper disable once InconsistentNaming
internal class Cache<K, T> : IDisposable
public class Cache<K, T> : IDisposable
{
#region Constructor and class members

@@ -121,7 +121,7 @@ namespace DotNetCore.CAP.Dashboard

private void RemoveByTimer(object state)
{
Remove((K) state);
Remove((K)state);
}

#endregion
@@ -251,8 +251,8 @@ namespace DotNetCore.CAP.Dashboard
try
{
var removers = (from k in _cache.Keys.Cast<K>()
where keyPattern(k)
select k).ToList();
where keyPattern(k)
select k).ToList();

foreach (var workKey in removers)
{
@@ -354,7 +354,7 @@ namespace DotNetCore.CAP.Dashboard
/// instance.
/// The <c>.Global</c> member is lazy instanciated.
/// </summary>
internal class CapCache : Cache<string, object>
public class CapCache : Cache<string, object>
{
#region Static Global Cache instance

@@ -372,4 +372,4 @@ namespace DotNetCore.CAP.Dashboard
}

#endregion
}
}

+ 2
- 2
src/DotNetCore.CAP.Dashboard/NodeDiscovery/INodeDiscoveryProvider.Consul.cs Zobrazit soubor

@@ -77,7 +77,7 @@ namespace DotNetCore.CAP.Dashboard.NodeDiscovery
};

if (_options.Scheme.Equals("http", StringComparison.OrdinalIgnoreCase))
healthCheck.HTTP = $"http://{_options.CurrentNodeHostName}:{_options.CurrentNodePort}{_options.MatchPath}/health";
healthCheck.HTTP = $"http://{_options.CurrentNodeHostName}:{_options.CurrentNodePort}{_options.MatchPath}/api/health";
else if (_options.Scheme.Equals("https", StringComparison.OrdinalIgnoreCase))
healthCheck.TCP = $"{_options.CurrentNodeHostName}:{_options.CurrentNodePort}";

@@ -114,4 +114,4 @@ namespace DotNetCore.CAP.Dashboard.NodeDiscovery
}
}
}
}
}

Načítá se…
Zrušit
Uložit