Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-3352

Sonar analysis on an Oracle database with reviews fails with Fail to decorate 'XXX': Invalid column type: 1111

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.14
    • Fix Version/s: 3.0
    • Component/s: Database
    • Labels:
      None
    • Environment:
      Java version 1.6.0_26
      Oracle JDBC driver version 11.2.0.1.0
      Oracle Database 11g Release 11.1.0.7.0 - Production

      Description

      When running an analysis on a project containing reviews, the analysis fails with the following error:

      [INFO] ------------------------------------------------------------------------
      [ERROR] BUILD ERROR
      [INFO] ------------------------------------------------------------------------
      [INFO] Can not execute Sonar
      
      Embedded error: Fail to decorate 'com.secutix.tnac.facade.list.ListServiceBean'
      Invalid column type: 1111
      [INFO] ------------------------------------------------------------------------
      [INFO] Trace
      org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
             at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
             at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
             at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
             at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
             at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
             at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
             at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
             at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
             at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
             at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
             at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
             at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
             at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
             at java.lang.reflect.Method.invoke(Method.java:597)
             at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
             at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
             at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
             at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
      Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
             at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
             at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
             at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
             at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
             at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
             ... 17 more
      Caused by: org.sonar.api.utils.SonarException: Fail to decorate
      'com.secutix.tnac.facade.list.ListServiceBean'
             at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
             at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
             at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:63)
             at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:63)
             at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
             at org.sonar.batch.phases.Phases.execute(Phases.java:94)
             at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:143)
             at org.sonar.batch.bootstrap.Module.start(Module.java:83)
             at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
             at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
             at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
             at org.sonar.batch.bootstrap.Module.start(Module.java:83)
             at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:102)
             at org.sonar.batch.bootstrap.Module.start(Module.java:83)
             at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:71)
             at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:58)
             at org.sonar.maven.SonarMojo.execute(SonarMojo.java:151)
             at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
             at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
             ... 21 more
      Caused by: org.apache.ibatis.exceptions.PersistenceException:
      ### Error updating database.  Cause:
      org.apache.ibatis.type.TypeException: Error setting null parameter.
      Most JDBC drivers require that the JdbcType must be specified for all
      nullable parameters. Cause: java.sql.SQLException: Invalid column
      type: 1111
      ### The error may involve org.sonar.core.review.ReviewMapper.update-Inline
      ### The error occurred while setting parameters
      ### Cause: org.apache.ibatis.type.TypeException: Error setting null
      parameter.  Most JDBC drivers require that the JdbcType must be
      specified for all nullable parameters. Cause: java.sql.SQLException:
      Invalid column type: 1111
             at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:8)
             at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:124)
             at org.sonar.core.persistence.BatchSession.update(BatchSession.java:121)
             at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:62)
             at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:25)
             at $Proxy53.update(Unknown Source)
             at org.sonar.core.review.ReviewDao.update(ReviewDao.java:89)
             at org.sonar.plugins.core.sensors.ReviewWorkflowDecorator.persistUpdates(ReviewWorkflowDecorator.java:85)
             at org.sonar.plugins.core.sensors.ReviewWorkflowDecorator.decorate(ReviewWorkflowDecorator.java:79)
             at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
             ... 39 more
      Caused by: org.apache.ibatis.type.TypeException: Error setting null
      parameter.  Most JDBC drivers require that the JdbcType must be
      specified for all nullable parameters. Cause: java.sql.SQLException:
      Invalid column type: 1111
             at org.apache.ibatis.type.BaseTypeHandler.setParameter(BaseTypeHandler.java:17)
             at org.apache.ibatis.executor.parameter.DefaultParameterHandler.setParameters(DefaultParameterHandler.java:73)
             at org.apache.ibatis.executor.statement.PreparedStatementHandler.parameterize(PreparedStatementHandler.java:61)
             at org.apache.ibatis.executor.statement.RoutingStatementHandler.parameterize(RoutingStatementHandler.java:43)
             at org.apache.ibatis.executor.BatchExecutor.doUpdate(BatchExecutor.java:50)
             at org.apache.ibatis.executor.BaseExecutor.update(BaseExecutor.java:88)
             at org.apache.ibatis.executor.CachingExecutor.update(CachingExecutor.java:43)
             at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:122)
             ... 47 more
      Caused by: java.sql.SQLException: Invalid column type: 1111
             at oracle.jdbc.driver.OracleStatement.getInternalType(OracleStatement.java:3900)
             at oracle.jdbc.driver.OraclePreparedStatement.setNullCritical(OraclePreparedStatement.java:4406)
             at oracle.jdbc.driver.OraclePreparedStatement.setNull(OraclePreparedStatement.java:4388)
             at oracle.jdbc.driver.OraclePreparedStatementWrapper.setNull(OraclePreparedStatementWrapper.java:1281)
             at org.apache.commons.dbcp.DelegatingPreparedStatement.setNull(DelegatingPreparedStatement.java:108)
             at org.apache.commons.dbcp.DelegatingPreparedStatement.setNull(DelegatingPreparedStatement.java:108)
             at org.apache.ibatis.type.BaseTypeHandler.setParameter(BaseTypeHandler.java:15)
             ... 54 more
      

        Attachments

          Activity

            People

            Assignee:
            fabemn OLD - Fabrice Bellingard
            Reporter:
            rborer Reynald Borer
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: