aboutsummaryrefslogtreecommitdiff
path: root/lib/Plugins.Essentials.ServiceStack/src/HttpServiceStack.cs
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Plugins.Essentials.ServiceStack/src/HttpServiceStack.cs')
-rw-r--r--lib/Plugins.Essentials.ServiceStack/src/HttpServiceStack.cs10
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/Plugins.Essentials.ServiceStack/src/HttpServiceStack.cs b/lib/Plugins.Essentials.ServiceStack/src/HttpServiceStack.cs
index 71db38f..2f1bb0b 100644
--- a/lib/Plugins.Essentials.ServiceStack/src/HttpServiceStack.cs
+++ b/lib/Plugins.Essentials.ServiceStack/src/HttpServiceStack.cs
@@ -30,6 +30,7 @@ using System.Collections.Generic;
using VNLib.Utils;
using VNLib.Net.Http;
using VNLib.Utils.Logging;
+using VNLib.Plugins.Essentials.ServiceStack.Plugins;
namespace VNLib.Plugins.Essentials.ServiceStack
{
@@ -39,7 +40,7 @@ namespace VNLib.Plugins.Essentials.ServiceStack
/// </summary>
public sealed class HttpServiceStack : VnDisposeable
{
- private readonly LinkedList<IHttpServer> _servers;
+ private readonly IReadOnlyCollection<IHttpServer> _servers;
private readonly ServiceDomain _serviceDomain;
private readonly PluginManager _plugins;
@@ -49,7 +50,7 @@ namespace VNLib.Plugins.Essentials.ServiceStack
/// <summary>
/// A collection of all loaded servers
/// </summary>
- public IReadOnlyCollection<IHttpServer> Servers => _servers;
+ public IEnumerable<IHttpServer> Servers => _servers;
/// <summary>
/// Gets the internal <see cref="IHttpPluginManager"/> that manages plugins for the entire
@@ -62,7 +63,7 @@ namespace VNLib.Plugins.Essentials.ServiceStack
/// generate servers to listen for services exposed by the
/// specified host context
/// </summary>
- internal HttpServiceStack(LinkedList<IHttpServer> servers, ServiceDomain serviceDomain, IPluginInitializer plugins)
+ internal HttpServiceStack(IReadOnlyCollection<IHttpServer> servers, ServiceDomain serviceDomain, IPluginInitializer plugins)
{
_servers = servers;
_serviceDomain = serviceDomain;
@@ -130,9 +131,6 @@ namespace VNLib.Plugins.Essentials.ServiceStack
_cts?.Dispose();
_plugins.Dispose();
-
- //remove all lists
- _servers.Clear();
}
}
}