public HAProxyGroup(HAProxyModule module, HAProxySettings.Group group) { Module = module; Settings = group; Instances = group.Instances.Select(i => new HAProxyInstance(module, i, group) { Group = this }).ToList(); Instances.ForEach(i => i.TryAddToGlobalPollers()); }
/// <summary> /// Creates a single instance group for consistent management at a higher level. /// </summary> /// <param name="instance">The <see cref="HAProxyInstance"/> to create a single-item group for.</param> public HAProxyGroup(HAProxyModule module, HAProxySettings.Instance instance) { Module = module; Settings = new HAProxySettings.Group { Name = instance.Name, Description = instance.Description }; Instances = new List <HAProxyInstance> { new HAProxyInstance(module, instance) { Group = this } }; Instances.ForEach(i => i.TryAddToGlobalPollers()); }
public HAProxyAdmin(HAProxyModule module) { Module = module; }