Konrad Szeromski 9 Years Ago Nice post! Thanks for sharing.It seems that page you've mentioned (http://www.irongrid.com) doesn't exists anymore and serves only ads right now The tool itself - 'IronTrackSQL' - looks like very old (2003?) profiler and unsupported since very long time but you can still get the src/bin of whle 'Iron' suite from 3rd party pages for example: http://www.cascadetg.com/hibernate/Is there any particular reason You have chosen 'IronTrackSQL' to profile SQL in Liferay? (I have very little experience with this kind of tools) Please sign in to reply. Reply as... Cancel David Zhang Konrad Szeromski 9 Years Ago Hi Konrad,Thanks for figuring out the wrong link.there are no special reasons for choosing "IronTrackSQL", but as you know there is another tool "SQL Profiler", it includes some code of "log4j" which may result in"Multiple loading problem".David. Please sign in to reply. Reply as... Cancel
David Zhang Konrad Szeromski 9 Years Ago Hi Konrad,Thanks for figuring out the wrong link.there are no special reasons for choosing "IronTrackSQL", but as you know there is another tool "SQL Profiler", it includes some code of "log4j" which may result in"Multiple loading problem".David. Please sign in to reply. Reply as... Cancel
Phil Zhang 9 Years Ago Thanks for sharing David. Helpful indeed. Please sign in to reply. Reply as... Cancel
Alfredo Del Castillo Villalba 9 Years Ago Really cool David!Useful and well-written! Thank you! Please sign in to reply. Reply as... Cancel
Scott Wilkinson 9 Years Ago Glad I'm not the only one who has this problem. I've used log4jdbcspy before, just take warning you may not want to use it in production. Please sign in to reply. Reply as... Cancel
Abhishek Suthar 9 Years Ago I have already configured portal-ext.properties as below :jdbc.default.driverClassName=com.mysql.jdbc.Driver jdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false jdbc.default.username=root jdbc.default.password=rootThen how to configure it with jdbc.default.driverClassName =” value to ”com.p6spy.engine.spy.P6SpyDriverThis? Please sign in to reply. Reply as... Cancel
Abhishek Suthar 9 Years Ago I have already configured portal-ext.properties as below :jdbc.default.driverClassName=com.mysql.jdbc.Driver jdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false jdbc.default.username=root jdbc.default.password=rootThen how to configure it with jdbc.default.driverClassName =” value to ”com.p6spy.engine.spy.P6SpyDriverThis? Please sign in to reply. Reply as... Cancel David Zhang Abhishek Suthar 9 Years Ago Hi Abhishek,right, one more thing, without "",jdbc.default.driverClassName=com.p6spy.engine.spy.P6SpyDriver.David. Please sign in to reply. Reply as... Cancel Abhishek Suthar David Zhang 9 Years Ago Then it will replace the previous property.You are asking to do below thing right?In my portal-ext.properties:jdbc.default.driverClassName=com.mysql.jdbc.Driverjdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=falsejdbc.default.username=root jdbc.default.password=rootjdbc.default.driverClassName =com.p6spy.engine.spy.P6SpyDriverThis will not work!! Please sign in to reply. Reply as... Cancel David Zhang Abhishek Suthar 9 Years Ago Hi Abhishek,replace "com.mysql.jdbc.Driver" to "com.p6spy.engine.spy.P6SpyDriver", we just change the driver,could you set up the environment the step by step ?jdbc.default.driverClassName =com.p6spy.engine.spy.P6SpyDriverjdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=falsejdbc.default.username=root jdbc.default.password=rootlet me know if you have other question.David. Please sign in to reply. Reply as... Cancel
David Zhang Abhishek Suthar 9 Years Ago Hi Abhishek,right, one more thing, without "",jdbc.default.driverClassName=com.p6spy.engine.spy.P6SpyDriver.David. Please sign in to reply. Reply as... Cancel Abhishek Suthar David Zhang 9 Years Ago Then it will replace the previous property.You are asking to do below thing right?In my portal-ext.properties:jdbc.default.driverClassName=com.mysql.jdbc.Driverjdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=falsejdbc.default.username=root jdbc.default.password=rootjdbc.default.driverClassName =com.p6spy.engine.spy.P6SpyDriverThis will not work!! Please sign in to reply. Reply as... Cancel David Zhang Abhishek Suthar 9 Years Ago Hi Abhishek,replace "com.mysql.jdbc.Driver" to "com.p6spy.engine.spy.P6SpyDriver", we just change the driver,could you set up the environment the step by step ?jdbc.default.driverClassName =com.p6spy.engine.spy.P6SpyDriverjdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=falsejdbc.default.username=root jdbc.default.password=rootlet me know if you have other question.David. Please sign in to reply. Reply as... Cancel
Abhishek Suthar David Zhang 9 Years Ago Then it will replace the previous property.You are asking to do below thing right?In my portal-ext.properties:jdbc.default.driverClassName=com.mysql.jdbc.Driverjdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=falsejdbc.default.username=root jdbc.default.password=rootjdbc.default.driverClassName =com.p6spy.engine.spy.P6SpyDriverThis will not work!! Please sign in to reply. Reply as... Cancel David Zhang Abhishek Suthar 9 Years Ago Hi Abhishek,replace "com.mysql.jdbc.Driver" to "com.p6spy.engine.spy.P6SpyDriver", we just change the driver,could you set up the environment the step by step ?jdbc.default.driverClassName =com.p6spy.engine.spy.P6SpyDriverjdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=falsejdbc.default.username=root jdbc.default.password=rootlet me know if you have other question.David. Please sign in to reply. Reply as... Cancel
David Zhang Abhishek Suthar 9 Years Ago Hi Abhishek,replace "com.mysql.jdbc.Driver" to "com.p6spy.engine.spy.P6SpyDriver", we just change the driver,could you set up the environment the step by step ?jdbc.default.driverClassName =com.p6spy.engine.spy.P6SpyDriverjdbc.default.url=jdbc:mysql://localhost/demoschema?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=falsejdbc.default.username=root jdbc.default.password=rootlet me know if you have other question.David. Please sign in to reply. Reply as... Cancel
Barani Murthy 9 Years Ago does this work on Liferay-6.2-.CE-GA2? unable to make it work for me even after following all the steps that are listed here. The file spy.log is created. But there are no contents being filled into it. Please sign in to reply. Reply as... Cancel
Alberto Chaparro 8 Years Ago Thanks David!Just one trick, if you want to print SQL log into your server's log file, set the logfile property to blank into the spy.properties file.Cheers! Please sign in to reply. Reply as... Cancel
Chry Cheng 8 Years Ago The realdriver and deregisterdrivers properties are no longer supported as of version 2.1.4 of p6spy at least. The realdriver property has been replaced by driverlist while deregisterdrivers appears to have been removed altogether. Please sign in to reply. Reply as... Cancel