This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See https://gitlab.nuiton.org/codelutin/tutti.git commit 5dd172c426c242700993aeb99740924d7fc02fc4 Author: Benjamin POUSSIN <poussin@codelutin.com> Date: Sat Jul 30 16:29:35 2016 +0200 add file to log sql query --- tutti-persistence/pom.xml | 17 +++++++++++++++++ tutti-ui-swing/src/main/resources/spy.properties | 3 +++ 2 files changed, 20 insertions(+) diff --git a/tutti-persistence/pom.xml b/tutti-persistence/pom.xml index 776c502..8c38c5c 100644 --- a/tutti-persistence/pom.xml +++ b/tutti-persistence/pom.xml @@ -159,6 +159,23 @@ <artifactId>hsqldb</artifactId> </dependency> + <!-- + | use to trace all sql query. Config file is src/main/resources/spy.properties + | to active it, uncomment dependency and change jdbc:hsqldb:... to jdbc:p6spy:hsqldb:... + | if you don't change spy.properties, log file is /tmp/tutti-jdbc-spy.log + | you can show most used query with: + | cat /tmp/tutti-jdbc-spy.log |grep "|select" |cut -f5 -d'|' |sort |uniq -c |sort -n + | you can compute sum of time with: + | cat /tmp/tutti-jdbc-spy.log |grep "<put here your query find with previous command>" |cut -f2 -d'|' |paste -s -d+ |bc + + --> + <!-- + <dependency> + <groupId>p6spy</groupId> + <artifactId>p6spy</artifactId> + <version>2.3.1</version> + </dependency> + --> + <!-- Logging --> <dependency> <groupId>org.slf4j</groupId> diff --git a/tutti-ui-swing/src/main/resources/spy.properties b/tutti-ui-swing/src/main/resources/spy.properties new file mode 100644 index 0000000..34f5191 --- /dev/null +++ b/tutti-ui-swing/src/main/resources/spy.properties @@ -0,0 +1,3 @@ +logfile=/tmp/tutti-jdbc-spy.log +driverlist=org.hsqldb.jdbcDriver +stacktrace=true -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.