Hi Thomas and others,

I've patched the current H2 source to extend the usage of JMX. If JMX
is enabled for a database, then it sends a notification whenever a
query starts and whenever a query ends.

Is this something you'd consider adding to the H2 trunk? If so, I'll
finalise my patch and submit it.

Currently it is a proof of concept but I envisage adding notifications
for all DML and DDL commands.

My use case is tracking long running schema manipulation queries such
as "ALTER TABLE ADD COLUMN", which actually performs several commands,
including "CREATE TABLE", "DROP TABLE", "CREATE INDEX". Currently
these can't be tracked in their entirety to give users helpful
feedback. I also envisage this being a way to eventually track long-
running SELECT queries, by sending a notification after every x rows
are handled.

Alternatively I could modify the existing DatabaseEventListener to do
this, but as that would require changing an existing API, I think this
would not be a good approach.

Regards,

Steve


-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to