diff options
author | Simon Brandhof <simon.brandhof@gmail.com> | 2012-07-11 17:02:59 +0200 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@gmail.com> | 2012-07-11 17:03:17 +0200 |
commit | 713a024a1cc38874b5fb709ede64c13a4f21ec53 (patch) | |
tree | 5bc3695a625c8b5c89387647d00b52591ee1e33b /sonar-batch | |
parent | 4a6b9541a01065121b6472360c178708c5697f38 (diff) | |
download | sonarqube-713a024a1cc38874b5fb709ede64c13a4f21ec53.tar.gz sonarqube-713a024a1cc38874b5fb709ede64c13a4f21ec53.zip |
Fix support of sonar.showSqlResults with MyBatis 3.1
Diffstat (limited to 'sonar-batch')
3 files changed, 9 insertions, 9 deletions
diff --git a/sonar-batch/src/main/java/org/sonar/batch/bootstrap/BootstrapModule.java b/sonar-batch/src/main/java/org/sonar/batch/bootstrap/BootstrapModule.java index 61a01cb36cf..11adc8adcd3 100644 --- a/sonar-batch/src/main/java/org/sonar/batch/bootstrap/BootstrapModule.java +++ b/sonar-batch/src/main/java/org/sonar/batch/bootstrap/BootstrapModule.java @@ -29,6 +29,7 @@ import org.sonar.batch.RemoteServerMetadata; import org.sonar.batch.ServerMetadata; import org.sonar.batch.config.BatchDatabaseSettingsLoader; import org.sonar.batch.config.BatchSettings; +import org.sonar.core.config.Logback; import org.sonar.core.i18n.I18nManager; import org.sonar.core.i18n.RuleI18nManager; import org.sonar.core.persistence.DaoUtils; @@ -59,6 +60,7 @@ public class BootstrapModule extends Module { addCoreSingleton(new PropertiesConfiguration()); addCoreSingleton(BatchSettings.class); addCoreSingleton(DryRun.class); + addCoreSingleton(Logback.class); addCoreSingleton(ServerMetadata.class);// registered here because used by BootstrapClassLoader addCoreSingleton(TempDirectories.class);// registered here because used by BootstrapClassLoader addCoreSingleton(HttpDownloader.class);// registered here because used by BootstrapClassLoader diff --git a/sonar-batch/src/main/resources/org/sonar/batch/bootstrapper/logback.xml b/sonar-batch/src/main/resources/org/sonar/batch/bootstrapper/logback.xml index 13135d01be9..12a7e1db673 100644 --- a/sonar-batch/src/main/resources/org/sonar/batch/bootstrapper/logback.xml +++ b/sonar-batch/src/main/resources/org/sonar/batch/bootstrapper/logback.xml @@ -42,15 +42,10 @@ <logger name="org.hibernate.SQL"> <level value="${SQL_LOGGER_LEVEL:-ERROR}"/> </logger> - <logger name="org.apache.ibatis"> - <level value="${SQL_LOGGER_LEVEL:-WARN}"/> - </logger> - <logger name="java.sql"> - <level value="${SQL_LOGGER_LEVEL:-WARN}"/> - </logger> - <logger name="java.sql.ResultSet"> - <level value="${SQL_RESULTS_LOGGER_LEVEL:-WARN}"/> - </logger> + <logger name="org.mybatis"> + <level value="${SQL_LOGGER_LEVEL:-WARN}"/> + </logger> + <!-- see also org.sonar.core.persistence.MyBatis#configureLogback() --> <root> <!-- sonar.verbose --> diff --git a/sonar-batch/src/main/resources/org/sonar/batch/logback.xml b/sonar-batch/src/main/resources/org/sonar/batch/logback.xml index 8c2d0cefc91..4171dcb6e34 100644 --- a/sonar-batch/src/main/resources/org/sonar/batch/logback.xml +++ b/sonar-batch/src/main/resources/org/sonar/batch/logback.xml @@ -41,6 +41,9 @@ <logger name="org.apache.ibatis"> <level value="${SQL_LOGGER_LEVEL:-WARN}"/> </logger> + <logger name="org.mybatis"> + <level value="${SQL_LOGGER_LEVEL:-WARN}"/> + </logger> <logger name="java.sql"> <level value="${SQL_LOGGER_LEVEL:-WARN}"/> </logger> |