28 lines
1.2 KiB
C#
28 lines
1.2 KiB
C#
namespace ZB.MOM.WW.Telemetry.Serilog;
|
|
|
|
/// <summary>
|
|
/// Canonical Serilog property name constants for the identity enrichers stamped by
|
|
/// <see cref="ZbSerilogExtensions.AddZbSerilog"/>. Use these constants — not literal strings —
|
|
/// when querying properties in sinks or tests. Each property mirrors a shared OTel Resource
|
|
/// attribute so logs and metrics/traces from the same node carry identical dimensions.
|
|
/// </summary>
|
|
public static class ZbLogEnricherNames
|
|
{
|
|
/// <summary>
|
|
/// Serilog property: physical or logical site identifier. Matches OTel Resource <c>site.id</c>.
|
|
/// </summary>
|
|
public const string SiteId = "SiteId";
|
|
|
|
/// <summary>
|
|
/// Serilog property: node function (<c>central</c>, <c>site</c>, <c>hub</c>, <c>standalone</c>).
|
|
/// Matches OTel Resource <c>node.role</c>.
|
|
/// </summary>
|
|
public const string NodeRole = "NodeRole";
|
|
|
|
/// <summary>
|
|
/// Serilog property: machine name (<see cref="System.Environment.MachineName"/>).
|
|
/// Matches OTel Resource <c>host.name</c>. Populated automatically — not a caller-supplied option.
|
|
/// </summary>
|
|
public const string NodeHostname = "NodeHostname";
|
|
}
|