Question :
Answer: SQL Server Extended Events are your friend . This example creates a Extended Event for a logon called "mylogon". When a connection based on the situations you requested a) new connection or b) connection from a connection pool
Related Articles
CREATE EVENT SESSION [Track_Logon] ON SERVER ADD EVENT sqlserver.login( ACTION(sqlserver.client_hostname,sqlserver.nt_username,sqlserver.username) WHERE ([sqlserver].[session_server_principal_name]=N'mylogon')) ADD TARGET package0.event_file(SET filename=N'C:\temp\track_logon.xel') GO ALTER EVENT SESSION [Track_Logon] ON SERVER STATE = start;