sonarqube - Sonar analysis fails with NullPointerException in sonar.log -


we have been using sonar 5.1 under java 1.7.0_76 on unix system month on large multi-project repository (mostly java 7, jsp, js, xml , css files). have noticed sonar runner executions failing in cases. please see error sonarqube log below. info:

  • this happening different files in different projects – .java file, .js file -- seems happen consistently same file on each run.
  • the file seems asking in fact exist in our repository.
  • all projects being analyzed same user, has “see source code” permission (actually, has permission).

can tell may causing these failures, , how can prevent them? thanks!


on server side (in sonar.log)

2015.05.26 02:58:56 error web[o.s.s.w.webserviceengine] fail process request http://sonar.era.nih.gov/api/sources/hash?key=pracs%3asrc%2fjava%2fgov%2fnih%2fera%2fpracs%2fbeans%2fuploadeddocument.java java.lang.nullpointerexception: null                 @ com.google.common.io.charstreams.copy(charstreams.java:202) ~[guava-10.0.1.jar:na]                 @ org.sonar.server.source.ws.hashaction$hashfunction.apply(hashaction.java:99) ~[sonar-server-5.1.jar:na]                 @ org.sonar.server.source.ws.hashaction$hashfunction.apply(hashaction.java:84) ~[sonar-server-5.1.jar:na]                 @ org.sonar.core.source.db.filesourcedao.readlinehashesstream(filesourcedao.java:94) ~[sonar-core-5.1.jar:na]                 @ org.sonar.server.source.ws.hashaction.handle(hashaction.java:74) ~[sonar-server-5.1.jar:na]                 @ org.sonar.server.ws.webserviceengine.execute(webserviceengine.java:84) ~[sonar-server-5.1.jar:na]                 @ sun.reflect.generatedmethodaccessor177.invoke(unknown source) ~[na:na]                 @ sun.reflect.delegatingmethodaccessorimpl.invoke(unknown source) ~[na:1.7.0_76]                 @ java.lang.reflect.method.invoke(unknown source) ~[na:1.7.0_76]                 @ org.jruby.javasupport.javamethod.invokedirectwithexceptionhandling(javamethod.java:425) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.javasupport.javamethod.invokedirect(javamethod.java:292) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.java.invokers.instancemethodinvoker.call(instancemethodinvoker.java:44) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.runtime.callsite.cachingcallsite.call(cachingcallsite.java:70) [jruby-complete-1.7.9.jar:na]                 @ rubyjit.api::javawscontroller$$index_18af0797cd66b4e310384a14e2b9ee369902e67f103261525.__file__(/home/sonarqube/apps/sonarqube/sonarqube-5.1/web/web-inf/app/controllers/api/java_ws_controller.rb:30) [jruby-complete-1.7.9.jar:na]                 @ rubyjit.api::javawscontroller$$index_18af0797cd66b4e310384a14e2b9ee369902e67f103261525.__file__(/home/sonarqube/apps/sonarqube/sonarqube-5.1/web/web-inf/app/controllers/api/java_ws_controller.rb) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.internal.runtime.methods.jittedmethod.call(jittedmethod.java:161) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.rubyclass.finvoke(rubyclass.java:527) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.rubybasicobject.send(rubybasicobject.java:2590) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.rubykernel.send(rubykernel.java:2223) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.rubykernel$invoker$s$send.call(rubykernel$invoker$s$send.gen) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.internal.runtime.methods.javamethod$javamethodoneornblock.call(javamethod.java:350) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.runtime.callsite.cachingcallsite.cacheandcall(cachingcallsite.java:326) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.runtime.callsite.cachingcallsite.call(cachingcallsite.java:170) [jruby-complete-1.7.9.jar:na]                 @ rubyjit.actioncontroller::base$$perform_action_da0fc0a901dd1257ec969db0c482dd8514b8f04b103261525.__file__(/home/sonarqube/apps/sonarqube/sonarqube-5.1/web/web-inf/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:1333) [jruby-complete-1.7.9.jar:na]                 @ rubyjit.actioncontroller::base$$perform_action_da0fc0a901dd1257ec969db0c482dd8514b8f04b103261525.__file__(/home/sonarqube/apps/sonarqube/sonarqube-5.1/web/web-inf/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.internal.runtime.methods.jittedmethod.call(jittedmethod.java:141) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.internal.runtime.methods.defaultmethod.call(defaultmethod.java:185) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.internal.runtime.methods.aliasmethod.call(aliasmethod.java:56) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.runtime.callsite.cachingcallsite.cacheandcall(cachingcallsite.java:306) [jruby-complete-1.7.9.jar:na]                 @ org.jruby.runtime.callsite.cachingcallsite.call(cachingcallsite.java:136) [jruby-complete-1.7.9.jar:na]                 @ … 

on client-side (sonar-runner)

the resulting error has following lines output sonar-runner (i’ll send full thing if need it, seems real problem npe):

[sonar-runner] info: execution failure [sonar-runner] info: ------------------------------------------------------------------------ [sonar-runner] total time: 2:50.798s [sonar-runner] error: error during sonar runner execution [sonar-runner] org.sonar.runner.impl.runnerexception: unable execute sonar [sonar-runner]     @ org.sonar.runner.impl.batchlauncher$1.delegateexecution(batchlauncher.java:91) … [sonar-runner] caused by: org.sonar.api.utils.sonarexception: fail decorate 'org.sonar.api.resources.file@1a89552[key=src/java/gov/nih/era/pracs/beans/uploadeddocument.java,path=src/java/gov/nih/era/pracs/beans/uploadeddocument.java,filename=uploadeddocument.java,language=java]' [sonar-runner]     @ org.sonar.batch.phases.decoratorsexecutor.executedecorator(decoratorsexecutor.java:104) … [sonar-runner] caused by: java.lang.illegalstateexception: fail execute request [code=500, url=http://sonar.era.nih.gov/api/sources/hash?key=pracs%3asrc%2fjava%2fgov%2fnih%2fera%2fpracs%2fbeans%2fuploadeddocument.java] [sonar-runner]     @ org.sonar.batch.bootstrap.serverclient.handlehttpexception(serverclient.java:139) … [sonar-runner] caused by: org.sonar.api.utils.httpdownloader$httpexception: fail download [http://sonar.era.nih.gov/api/sources/hash?key=pracs%3asrc%2fjava%2fgov%2fnih%2fera%2fpracs%2fbeans%2fuploadeddocument.java]. response code: 500 [sonar-runner]     @ org.sonar.api.utils.httpdownloader$basehttpdownloader$httpinputsupplier.getinput(httpdownloader.java:305) 


Comments

Popular posts from this blog

Java 3D LWJGL collision -

spring - SubProtocolWebSocketHandler - No handlers -

methods - python can't use function in submodule -