Skip to main content
net10.0net8.0net9.0

OPC UA distributed server Kubernetes integration for leader election, peer discovery, and readiness.

Published
Sep 30, 2026
20d ago
Total Downloads
195
195

Install

dotnet add package OPCFoundation.NetStandard.Opc.Ua.Redundancy.Kubernetes --version 2.0.0-preview.6
ProductVersions
.NET
net10.0net8.0net9.0

README

OPC UA .NET Standard — Kubernetes Distributed Server Integration

OPCFoundation.NetStandard.Opc.Ua.Redundancy.Kubernetes adds opt-in Kubernetes integration to OPCFoundation.NetStandard.Opc.Ua.Redundancy.Server.

Overview

The package keeps Kubernetes concerns outside the base high-availability package. It provides Lease-backed leader election, peer discovery from EndpointSlices, an HTTP readiness/liveness bridge driven by OPC UA ServiceLevel, and a strongly-consistent multi-node Raft consensus wiring (UseKubernetesRaftConsensus, RaftCs over NanoMsg with an optional file WAL).

Getting started

services.AddOpcUa()
    .AddServer(...)
    .UseDistributedAddressSpace(options => options.UseLeaderElection = true)
    .UseKubernetesLeaderElection(options => options.LeaseName = "opcua-ha")
    .UseKubernetesPeerDiscovery(options => options.ServiceName = "opcua-ha-headless")
    .UseKubernetesReadiness(options => options.Port = 8080);

For strong consistency, wire a Raft cluster from the StatefulSet ordinals and compose it with UseRedundancyConsistency:

services.AddOpcUa()
    .AddServer(...)
    .UseKubernetesRaftConsensus(o =>
    {
        o.HeadlessServiceName = "opcua-ha-headless";
        o.ReplicaCount = 3;                      // static membership; odd for quorum
        o.StoragePath = "/var/lib/opcua/raft";   // PersistentVolume mount for the WAL
    })
    .UseRedundancyConsistency(RedundancyConsistencyMode.Strong);

Target frameworks

net8.0, net9.0, net10.0. .NET Framework and netstandard consumers use the base distributed package without Kubernetes integration.

Additional documentation

See the Kubernetes high availability deployment guide for RBAC, Service, StatefulSet, readiness, and time-sync guidance.

Changes from Previous Version

No structural changes between v2.0.0-preview.5 and v2.0.0-preview.6.

Adoption Assessment

A verified publisher signal is available. Assess fit from the package's supported frameworks, license and dependency graph rather than popularity alone.

This version is marked prerelease. Validate its API and upgrade path before production use.No SPDX license expression is published. Review the license text and your organisation's policy before redistribution.Compatibility metadata lists 3 target frameworks; confirm the exact target used by your application.The published metadata declares 72 direct dependency entries across framework groups. Inspect the resolved dependency graph for your target framework.

Related Guides & Workflows

Learn how to evaluate, integrate, or audit this package in your .NET project.