When configuring a database connection to NLog, i found that it was not producing anything to the database even though i was 100% sure i had it right. I discovered the culprit was my Stackify target. When i remove the stacify target the database connection write works perfectly.
I would like to retain Stackify in my solution though. Anyone know why this is conflicting, and if i can revise the stackify target to not block/destroy my database target?
<target name="database"
xsi:type="Database"
connectionStringName="NLog"
commandText="exec dbo.InsertLog
@level,
@callSite,
@type,
@message,
@stackTrace,
@innerException,
@additionalInfo">
<parameter name="@level" layout="${level}" />
<parameter name="@callSite" layout="${callsite}" />
<parameter name="@type" layout="${exception:format=type}" />
<parameter name="@message" layout="${exception:format=message}" />
<parameter name="@stackTrace" layout="${exception:format=stackTrace}" />
<parameter name="@innerException"
layout="${exception:format=:innerFormat=ShortType,Message,Method:MaxInnerExceptionLevel=1:InnerExceptionSeparator=}" />
<parameter name="@additionalInfo" layout="${message}" />
</target>
<target name="stackify" xsi:type="StackifyTarget" layout="${logger} / ${message}" />
does NOT work, but when i remove this line database target works just fine:
<target name="stackify" xsi:type="StackifyTarget" layout="${logger} / ${message}" />
why is that? Thanks in advance for the help!