Extended Events session that writes to a file? The volume should be low enough that you can get away with later writing the file to a table or load up an SB queue that does more work if you need to respond immediately with a heavier set of logic.
edit: file then table/queue
There are no special teachers of virtue, because virtue is taught by the whole community.
--Plato