feat(cluster): AkkaHostedService and DI extension
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
namespace ZB.MOM.WW.OtOpcUa.Cluster;
|
||||
|
||||
public sealed class AkkaClusterOptions
|
||||
{
|
||||
public const string SectionName = "Cluster";
|
||||
|
||||
public string SystemName { get; set; } = "otopcua";
|
||||
public string Hostname { get; set; } = "0.0.0.0";
|
||||
public int Port { get; set; } = 4053;
|
||||
|
||||
/// <summary>
|
||||
/// Hostname advertised in cluster gossip. Must be reachable by other nodes.
|
||||
/// In docker-compose this is the container DNS name; in bare metal it's the
|
||||
/// host's stable LAN address.
|
||||
/// </summary>
|
||||
public string PublicHostname { get; set; } = "127.0.0.1";
|
||||
|
||||
public string[] SeedNodes { get; set; } = Array.Empty<string>();
|
||||
|
||||
/// <summary>
|
||||
/// Cluster roles for this node. When empty the role list comes from
|
||||
/// <c>OTOPCUA_ROLES</c> via <see cref="RoleParser"/>. Allowed values:
|
||||
/// <c>admin</c>, <c>driver</c>, <c>dev</c>.
|
||||
/// </summary>
|
||||
public string[] Roles { get; set; } = Array.Empty<string>();
|
||||
}
|
||||
Reference in New Issue
Block a user