Parent
What to build
Provide an optional NetOffice adapter for Microsoft Extensions Logging (MEL). A final application supplies an application-owned ILoggerFactory; the adapter exposes it through the provider-neutral NetOffice logging contract without adding MEL to NetOfficeFw.Core.
The adapter creates and caches one MEL ILogger for each NetOffice category. It maps every NetOffice level to the corresponding MEL LogLevel, maps the stable NetOffice event identifier and name to MEL EventId, forwards the original exception object, and preserves the original named message template and arguments so configured providers receive structured properties rather than a preformatted string.
The adapter delegates filtering to the category logger's IsEnabled result before constructing avoidable state. It does not add providers, establish global filters, own scopes that NetOffice did not create, flush providers, or dispose the supplied factory. Applications remain responsible for all provider configuration and lifetime management.
The package depends only on NetOfficeFw.Core and Microsoft.Extensions.Logging.Abstractions; it must not depend on a concrete provider. Its public configuration API must make the ownership rule explicit and allow a specific Core instance to be configured. It must remain compatible with the repository's .NET Framework and strong-name requirements.
Serilog and NLog users may use this adapter through their official MEL providers. Documentation must distinguish that route from the native NetOffice adapters and warn against enabling both routes for the same Core.
Acceptance criteria
Blocked by
Parent
What to build
Provide an optional NetOffice adapter for Microsoft Extensions Logging (MEL). A final application supplies an application-owned
ILoggerFactory; the adapter exposes it through the provider-neutral NetOffice logging contract without adding MEL toNetOfficeFw.Core.The adapter creates and caches one MEL
ILoggerfor each NetOffice category. It maps every NetOffice level to the corresponding MELLogLevel, maps the stable NetOffice event identifier and name to MELEventId, forwards the original exception object, and preserves the original named message template and arguments so configured providers receive structured properties rather than a preformatted string.The adapter delegates filtering to the category logger's
IsEnabledresult before constructing avoidable state. It does not add providers, establish global filters, own scopes that NetOffice did not create, flush providers, or dispose the supplied factory. Applications remain responsible for all provider configuration and lifetime management.The package depends only on
NetOfficeFw.CoreandMicrosoft.Extensions.Logging.Abstractions; it must not depend on a concrete provider. Its public configuration API must make the ownership rule explicit and allow a specificCoreinstance to be configured. It must remain compatible with the repository's .NET Framework and strong-name requirements.Serilog and NLog users may use this adapter through their official MEL providers. Documentation must distinguish that route from the native NetOffice adapters and warn against enabling both routes for the same
Core.Acceptance criteria
NetOfficeFw.Core.Corefrom an application-ownedILoggerFactory.EventId.IsEnabledprevents avoidable formatting, state creation, and provider invocation.ILoggerProviderto verify categories, levels, event IDs, structured properties, exception identity, filtering, and provider failure isolation.Blocked by