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

.NET Framework Windows Service and SQL Statements

bruno_camara
Visitor

I have a .NET Framework windows service with Deep Monitoring. Basically this windows service retrieve messages from a MSMQ queue and saves a record in a SQL Server database.

I can find traces originated from this process group while consuming messages from queue, but i can't find the SQL statements that are being sent to the target the database, like I would see if it was an application hosted in IIS, for example.

Any idea why the SQL  statements are not being collected inside a windows service that has Deep monitoring?

 

Thanks in advance

6 REPLIES 6

AntonPineiro
DynaMight Guru
DynaMight Guru

Hi,

I would say:

  1. Deep monitoring enabled + process restarted.
  2. Database framework supported.

Best regards

❤️ Emacs ❤️ Vim ❤️ Bash ❤️ Perl

Thank you @AntonPineiro 

Regarding 1, checked.

Regarding 2, could you please provide the link where you get that table? 

The windows service that is beinf deep monitored was build tartgeting .NET Framework v4.8, and is using vanilla ADO.NET to communicate with the database. 

When hosting a service in IIS, targeting the same .NET framework, and using ADO.NET, we can see the statements being collected. In case of the windows service, we cannot. So, there's something here that I might be missing.

Hi,

I have just edited my before comment because table was not correct. ADO.NET is supported, you can see it here

AntonPineiro_0-1742998294313.png

Best regards

❤️ Emacs ❤️ Vim ❤️ Bash ❤️ Perl

Mizső
DynaMight Guru
DynaMight Guru

Hi @bruno_camara ,

Sometimes the automatic instrumentation does not work. In this case I always try to use custom service detection to see missing requests and database calls.

But in your case maybe there is another issue if you can see the call details in the trace expect the database calls.

Best regards,

János

Dynatrace Community RockStar 2024, Certified Dynatrace Professional

Thank you.

I didn't know about Custom Service Identification. It seems exactly what I need, since I want to see instances of windows service as "Services" in Dynatrace lingo. I'm gonna try to define the custom service (entry point and methods)

I just want to confirm that I managed to monitor the database calls inside the windows service, by using a custom servide definition as suggested by @Mizső 

Thanks for all your help.

Featured Posts