cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Capturing log message from ILogger

Andrew.Draut
Producer

The documenation says that loggers that implement ILogger are supported, but no where does it describe how to capture those messages.  Our on-prem controller is version 21.4 and our agents are all 22.1 or later.  We have the .net Microsoft.Extensions.Logging.Console logger setup and it is outputting messages.  How do we configure AppD to capture those messages?

10 REPLIES 10

Ryan.Paredez
Community Manager

Hi, @Andrew.Draut 

 

Can you share the link to the Docs page you were looking at? If things are ever unclear, I can share that feedback with our Docs team to have things fixed to be more helpful.

 

 


Thanks,

Ryan, Cisco AppDynamics Community Manager




Found something helpful? Click the Accept as Solution button to help others find answers faster.

Liked something? Click the Thumbs Up button.



Check out Observabiity in Action

new deep dive videos weekly in the Knowledge Base.

Supported Loggers for the .NET Agent.
Error Configuration for .NET.

 

"Agents running on .NET Core can also instrument calls using loggers that implement the Microsoft.Extensions.Logging.ILogger API".  It says they can do it.  So how do we enable it?  Is it enabled by default?  Do I have to define a custom logger?


Errors and exceptions logging through loggers that implement ILogger do not seem to be appearing in AppD anywhere for any of our ASP.Net Core applications.  Since an error HTTP code is not being returned the BT does not get flagged as an error so it looks like everything is running smoothing when really it isn't.

Hi, @Andrew.Draut 

 

Thanks for sharing those. I have passed this feedback to the Docs team. I will report back when I have an update to share.

 

In the meantime, let's see if the Community can help out. Alternatively, if you happen to figure anything out, please do come back here and share those learnings.

 

[Internal use only: DOCS-10022]

 


Thanks,

Ryan, Cisco AppDynamics Community Manager




Found something helpful? Click the Accept as Solution button to help others find answers faster.

Liked something? Click the Thumbs Up button.



Check out Observabiity in Action

new deep dive videos weekly in the Knowledge Base.

Hi @Andrew.Draut,

 

So I heard back and it turns out this is a bug and it's currently being investigated. I don't have any sort of time frame for a fix, but when I do, I'll report back here and the Documentation will also be updated.


Thanks,

Ryan, Cisco AppDynamics Community Manager




Found something helpful? Click the Accept as Solution button to help others find answers faster.

Liked something? Click the Thumbs Up button.



Check out Observabiity in Action

new deep dive videos weekly in the Knowledge Base.

Thanks for the update.

Hi @Andrew.Draut,

 

I've received some new intel.

 

It appears the Error Detection on 22.2 is working mostly as expected. Transactions are being marked as Error when the checkbox for Log4Net is checked and when using an ILogger and the agent is ignoring loggers when ignore rules are applied. However, there are new additional points that we discovered during the call.

  • If you use this code, logger.Error("trackerlogging", new ObjectDisposedException("test")), and have an ignore rule only for the message "trackerlogging" the transaction will still be marked as Error due to the creation of a new ObjectDisposedException. Once you ignore the exception ObjectDisposedException the transaction is marked as Normal but the exception count on the Exception Page still tracks the ObjectDisposedException. Only the count of the initialization of this exception is tracked meaning no snapshots or stack traces are shown on the Exception page.

 

No additional configurations are needed, the checkboxes for log4net and ILogger are checked by default.

 


Thanks,

Ryan, Cisco AppDynamics Community Manager




Found something helpful? Click the Accept as Solution button to help others find answers faster.

Liked something? Click the Thumbs Up button.



Check out Observabiity in Action

new deep dive videos weekly in the Knowledge Base.

"Error Detection on 22.2".  Does the controller version affect this at all?  We are on 21.4

Hi @Andrew.Draut 

 

I'm following up - will report back!


Thanks,

Ryan, Cisco AppDynamics Community Manager




Found something helpful? Click the Accept as Solution button to help others find answers faster.

Liked something? Click the Thumbs Up button.



Check out Observabiity in Action

new deep dive videos weekly in the Knowledge Base.

Hi @Andrew.Draut,

 

Controller Version does not matter.


Thanks,

Ryan, Cisco AppDynamics Community Manager




Found something helpful? Click the Accept as Solution button to help others find answers faster.

Liked something? Click the Thumbs Up button.



Check out Observabiity in Action

new deep dive videos weekly in the Knowledge Base.

Join Us On December 10
Learn how Splunk and AppDynamics are redefining observability


Register Now!

Observe and Explore
Dive into our Community Blog for the Latest Insights and Updates!


Read the blog here
Top Kudoed Authors