Extending the Semantic Logging Log data

Topics: Semantic Logging Application Block
May 27, 2013 at 6:05 PM
I downloaded one aExpense application from msdn site for sample Semantic Logging implementation. But the table schema it creates is a different one that what SemanticLogging-svc.exe creates or uses.

This schema logs other OS level details like ThreadId, ProcessName, MachineName, AppDomainName, ProcessId, etc.

I also need to log this OS level information along with the DB schema created by the out-of-process Semantic Logging service.

Do I have to over ride any write classes or there is some in built way to log this OS level information. If we have to change the schema of Traces table in Logging database, then what is the best way to do it? In the sense, how will the logging framework allow me to log additional OS level data?

Thank you,
Himanshu Patel
May 28, 2013 at 2:40 AM

From your description, it looks like you are comparing the Logging table used by LAB with the Traces table used by SLAB. If so, then the Traces table schema should be identical to the schema used by the SQL sink you may use with the out-of-process Semantic Logging service.
Now regarding your last question, you may set the OS data you want to log as separate arguments of your event so the will be part of your payload and written to 'Payload' column JSON formatted.
May 28, 2013 at 5:46 PM
Thank you very much for the input. This helps.