Skip to content

LoggingServiceProxy

LoggingServiceProxy hides the internal generated clsWSLoggingSoapClient behind a single LogException operation, mapping SAIF.Core's ApplicationExceptionDetail onto the wire ErrorInfoStruct field-by-field so callers can forward exception details to the centralized logging service without knowing the wire contract. It is invoked by EnvironmentApi's SAIFExceptionLogger.

Purpose

  • Forward application exception details (application, environment, date, message, source, machine, page, state, user) to the remote logging service (OP-WP-04).

Context

  • Namespace: SAIF.Services.Web.Proxies
  • Assembly/package: SAIF.Services.Web.Proxies (packaged in SAIF.SAIFCode.Core)

Public members

Member Signature Purpose
Constructor LoggingServiceProxy(string serviceUrl) Guards serviceUrl, then builds a default BasicHttpBinding client (WP-BR-001)
LogException void LogException(ApplicationExceptionDetail detail) Maps detail to a wire ErrorInfoStruct via Extensions.ToErrorInfoStruct, then calls wire WriteError; no value is returned
Dispose void Dispose() Closes the underlying generated clsWSLoggingSoapClient by calling Close(), without an Abort() fallback on a faulted channel*

Behavioral notes

  • The field mapping is a direct copy with no validation of detail's contents; a malformed exception detail is forwarded as-is to the remote service*.
  • ExtensionData on the wire struct is always set to null.

Constraints and usage notes

  • Callers must supply the endpoint URL; this wrapper reads no configuration of its own.

Note: Statements marked with * were inferred from code structure, naming conventions, or contextual evidence where direct confirmation was not available in source artifacts.

Sources

  • Services/SAIF.Services.Web.Proxies/LoggingServiceProxy.cs