datajoint-python icon indicating copy to clipboard operation
datajoint-python copied to clipboard

Transition from client side logging to server-side logging implementation

Open eywalker opened this issue 8 years ago • 2 comments
trafficstars

Currently DataJoint supports straightforward logging of query activities via dj.schema.log tables. However, this is entirely DJ client side logic, meaning that the logging of activity only happens for queries issued from DJ client. While this still has its uses, it cannot guarantee that it gives an accurate picture of database server activities. I propose that we migrate our logging functionality to more server side, using MySQL's built-in features such as trigger.

eywalker avatar Oct 22 '17 01:10 eywalker

Since MySQL does not provide triggers for DDL operations, the utility of server side logging will remain limited until we implement a DataJoint-specific server, which is still a bit farther in the future. So this is more of a long-term plan.

dimitri-yatsenko avatar Oct 22 '17 03:10 dimitri-yatsenko

Postgresql does provide DDL triggers, so another long-term possibility is to migrate to postgresql https://www.postgresql.org/docs/9.3/static/event-triggers.html

dimitri-yatsenko avatar Oct 22 '17 03:10 dimitri-yatsenko