Skip to content

Attribute reference

The [Log] attribute and its properties ([Sensitive], [NoLog], EntryExitLevel, ObjectLogMode, etc.) are now documented in the AOP package:

See: AOP — Log Attribute for the full [Log] reference.

Interpolation configuration (ILogConfigurator)

Section titled “Interpolation configuration (ILogConfigurator)”

Settings for logger.LogXxx($"...") interpolated-string logging go through ILogConfigurator:

public sealed class LogConfig : ILogConfigurator
{
public void Configure(ILogBuilder b)
{
b.Interpolation(i => i.PropertyNameCasing = ZibLogPropertyCasing.CamelCase);
}
}
PropertyDefaultDescription
PropertyNameCasingPascalCaseCasing of structured property names in log templates (PascalCase or CamelCase)

With using ZibStack.NET.Log;, standard LogXxx methods accept $"..." with structured logging:

MethodDescription
_logger.LogTrace($"...")Trace level with structured properties
_logger.LogDebug($"...")Debug level
_logger.LogInformation($"...")Information level
_logger.LogWarning($"...")Warning level
_logger.LogError($"...")Error level
_logger.LogError(ex, $"...")Error level with exception
_logger.LogCritical($"...")Critical level
_logger.LogCritical(ex, $"...")Critical level with exception
  • .NET 8.0 or later (uses C# interceptors)

That’s it. The package’s build/.props enables InterceptorsNamespaces automatically — you don’t need to touch your .csproj.

No open items. Have a feature request? Open an issue.

MIT