NodeAgentConfig class
Configuration for a NodeAgent.
Constructors
-
NodeAgentConfig({required Uri hubUri, required String nodeId, required CredentialProvider credentials, String nodeMount = '/node', String displayName = '', Map<
String, String> labels = const {}, SecurityContext? securityContext, bool onBadCertificate(X509Certificate cert, String host, int port)?, Duration heartbeatInterval = const Duration(seconds: 15), ReconnectPolicy reconnect = const ReconnectPolicy(), Clock clock = const SystemClock(), String agentVersion = omnyServerVersion, StatusProvider? statusProvider, CapabilityProvider? capabilityProvider, FormulaHandler? formulaHandler, PresetHandler? presetHandler, ServiceHandler? serviceHandler, NodeControlHandler? nodeControlHandler, void logger(String message)?, bool verbose = false}) - Creates a node-agent configuration.
Properties
- agentVersion → String
-
The agent version reported in the descriptor.
final
- capabilityProvider → CapabilityProvider?
-
Supplies detected capabilities at registration.
final
- clock → Clock
-
Time source.
final
- controlUri → Uri
-
The control-channel URL the agent actually dials: hubUri with
nodeMount as its path.
no setter
- credentials → CredentialProvider
-
Produces the credential answering the Hub's auth challenge.
final
- displayName → String
-
A human-friendly display name.
final
- formulaHandler → FormulaHandler?
-
Handles formula-run requests (null ⇒ unsupported).
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- heartbeatInterval → Duration
-
How often to send heartbeats, if the Hub does not say.
final
- hubUri → Uri
-
The Hub
wss://URL to dial (e.g.wss://hub.example.com:8443).final -
labels
→ Map<
String, String> -
Operator-supplied labels.
final
- logger → void Function(String message)?
-
Optional log sink.
final
- nodeControlHandler → NodeControlHandler?
-
Handles node-control requests (null ⇒ ack success without acting).
final
- nodeId → String
-
The operator-chosen node id.
final
- nodeMount → String
-
The path the Hub mounts its node control channel at.
final
- onBadCertificate → bool Function(X509Certificate cert, String host, int port)?
-
Escape hatch for certificate pinning / self-signed dev certs.
final
- presetHandler → PresetHandler?
-
Handles preset-apply requests (null ⇒ unsupported).
final
- reconnect → ReconnectPolicy
-
The reconnection backoff policy.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- securityContext → SecurityContext?
-
TLS trust context (e.g. trusting the Hub's CA).
final
- serviceHandler → ServiceHandler?
-
Handles service-control requests (null ⇒ unsupported).
final
- statusProvider → StatusProvider?
-
Supplies the live status snapshot for heartbeats/reports.
final
- verbose → bool
-
Whether to surface the runtime's own lifecycle logging (connection
attempts, handshakes) and not just its warnings/failures. Off by default:
a healthy node is quiet, and a failing one still reports the failure.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited