File tree Expand file tree Collapse file tree 1 file changed +3
-15
lines changed
Src/StackifyLib/Internal/Logs Expand file tree Collapse file tree 1 file changed +3
-15
lines changed Original file line number Diff line number Diff line change @@ -197,24 +197,12 @@ public void QueueLogMessage(Models.LogMsg msg)
197197 var callContextType = midTypes . Where ( type => type . Name . Contains ( "StackifyCallContext" ) ) . First ( ) ;
198198 var traceCtxType = midTypes . Where ( type => type . Name . Contains ( "TraceContext" ) ) . First ( ) ;
199199 var traceContextProp = callContextType . GetProperty ( "TraceContext" ) ;
200- var traceFields = Convert . ChangeType ( traceContextProp . GetValue ( null ) , traceCtxType ) ;
200+ var traceFields = traceContextProp . GetValue ( null ) ;
201201 if ( traceFields != null )
202202 {
203- // var tFields = traceFields.RequestID ;
204- Console . WriteLine ( "Testing" ) ;
203+ //var tFields = traceCtxType.GetField("RequestId").GetValue(traceFields) ;
204+ msg . TransID = traceCtxType . GetProperty ( "RequestId" ) . GetValue ( traceFields ) . ToString ( ) ;
205205 }
206- //var ctxType = Type.GetType("Stackify.Agent.Threading.StackifyCallContext");
207-
208-
209- // check if using log4net or NLog
210- /*
211- var correltionManagerId = CallContext.LogicalGetData("E2ETrace.ActivityID");
212-
213- if (correltionManagerId != null && correltionManagerId is Guid && ((Guid)correltionManagerId) != Guid.Empty)
214- {
215- msg.TransID = correltionManagerId.ToString();
216- }
217- */
218206 }
219207#endif
220208
You can’t perform that action at this time.
0 commit comments