Quantcast

exception in sonar

classic Classic list List threaded Threaded
17 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

exception in sonar

Alexander Lorenz-2
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | +49-30-756543-194 | www.tomtom.com 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

New Flex metrics

Jean-Hervé Laveau

Hello,

 

In version 1.2 of Flex PMD, we have implemented 2 new metrics:

·        Blank lines, which give the number of blank lines

·        Import lines, which gives the number of imports lines

With new version of Sonar Flex plugin using sslr, is it possible to do the same?

 

Thank you for your answers

 

Best regards

 

Jean-Hervé

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Timeline widget question / New xxx usage

Jean-Hervé Laveau
In reply to this post by Alexander Lorenz-2

Hello,

 

When using timeline widget, we track evolution of “Lines of code” and “Blocker violations” numbers as follow :

But if I try to track “New Blocker violations” instead of “Blocker violations”,

Timeline disappears as following:

 

Is it a normal behavior? Did I something wrong?

 


Best regards

 

Jean-Hervé

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: New Flex metrics

Dinesh Bolkensteyn-2
In reply to this post by Jean-Hervé Laveau
Hi Jean-Hervé,
 
It should be fairly straightforward.
 
Blank lines IMO can be computed from the already existing metrics.
 
In order to count the number of import lines, I guess that a very easy approach would be to simply call the number of "importDefinition" nodes in the file.
 
To do that, you create a new visitor, subscribe to the "importDefinition" node, and simply increment a counter by 1 each time "visitNode" is called.
 
However, instead of creating your own visitor, you can simply reuse the "CounterVisitor" from sslr-squid-bridge, and inject it in the FlexAstScanner.
 
Note that you'll probably have to define your own metric and save it in Sonar.
 
Please let me know if you have any issue.

--
Dinesh Bolkensteyn
www.SonarSource.com
twitter.com/DBolkensteyn



On Wed, Jul 11, 2012 at 6:03 PM, JHL Qualixo <[hidden email]> wrote:

Hello,

 

In version 1.2 of Flex PMD, we have implemented 2 new metrics:

·        Blank lines, which give the number of blank lines

·        Import lines, which gives the number of imports lines

With new version of Sonar Flex plugin using sslr, is it possible to do the same?

 

Thank you for your answers

 

Best regards

 

Jean-Hervé


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Freddy Mallet
In reply to this post by Alexander Lorenz-2
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: New Flex metrics

Jean-Hervé Laveau
In reply to this post by Dinesh Bolkensteyn-2

Thank you Dinesh for those complete explanations.
I will soon come back to the community with that implementations.

 

Best regards

 

Jean-Hervé

 

De : Dinesh Bolkensteyn [mailto:[hidden email]]
Envoyé : mercredi 11 juillet 2012 18:40
À : [hidden email]
Cc : JHL Qualixo
Objet : Re: [sonar-user] New Flex metrics

 

Hi Jean-Hervé,

 

It should be fairly straightforward.

 

Blank lines IMO can be computed from the already existing metrics.

 

In order to count the number of import lines, I guess that a very easy approach would be to simply call the number of "importDefinition" nodes in the file.

 

To do that, you create a new visitor, subscribe to the "importDefinition" node, and simply increment a counter by 1 each time "visitNode" is called.

 

However, instead of creating your own visitor, you can simply reuse the "CounterVisitor" from sslr-squid-bridge, and inject it in the FlexAstScanner.

 

Note that you'll probably have to define your own metric and save it in Sonar.

 

Please let me know if you have any issue.

--
Dinesh Bolkensteyn
www.SonarSource.com

twitter.com/DBolkensteyn


On Wed, Jul 11, 2012 at 6:03 PM, JHL Qualixo <[hidden email]> wrote:

Hello,

 

In version 1.2 of Flex PMD, we have implemented 2 new metrics:

·        Blank lines, which give the number of blank lines

·        Import lines, which gives the number of imports lines

With new version of Sonar Flex plugin using sslr, is it possible to do the same?

 

Thank you for your answers

 

Best regards

 

Jean-Hervé

 

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Alexander Lorenz-2
In reply to this post by Freddy Mallet
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex



On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | +49-30-756543-194 | www.tomtom.com 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Timeline widget question / New xxx usage

David Racodon-2
In reply to this post by Jean-Hervé Laveau
Hi Jean-Hervé,

Yes it is a logical behavior.

Indeed, new xxxx violations are specific kinds of metrics. They computes deltas between the current snapshot and previous ones.
Thus those metrics have different measures for the same snapshot (ex: delta from previous version, delta from version x.y, etc.).
The first question then would be: which one of those measures to display?
The second one would be: what would be the point of having history of deltas between milestones that change?
As we have no answers to those question, no history is kept on those metrics and thus nothing can be displayed in the timeline widget.

My question then: what use case are you trying to achieve by wanting to display history on New xxxx violations?

Thank you

Regards,


David RACODON | SonarSource
Senior Consultant



On 11 July 2012 18:17, JHL Qualixo <[hidden email]> wrote:

Hello,

 

When using timeline widget, we track evolution of “Lines of code” and “Blocker violations” numbers as follow :

But if I try to track “New Blocker violations” instead of “Blocker violations”,

Timeline disappears as following:

 

Is it a normal behavior? Did I something wrong?

 


Best regards

 

Jean-Hervé


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Freddy Mallet
In reply to this post by Alexander Lorenz-2
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Alexander Lorenz-2
hi freddy,

i got more info from the guys this project belongs to.
apparently this happened when they had triggered a build on jenkins which included a sonar analysis, and this build triggered a downstream build which analyzed the same project via sonar. sometimes, the second build then failed with aforementioned exception.

i always thought jenkins only tags a build as finished when sonar is completely done.
it seems like sometimes there is still some background sonar activity running when the second build reaches its sonar analysis stage.


best

lx


On 07/13/2012 10:57 AM, Freddy Mallet wrote:
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | +49-30-756543-194 | www.tomtom.com 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Ann Campbell
One build can trigger another as either a "downstream" build (build B after A is done) or as a Build Step. And that Build Step can run either in Blocking or non-Blocking mode. 

So it sounds like it was run as a non-blocking build step. I.e. concurrent. :-(


On Mon, Jul 16, 2012 at 8:26 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,

i got more info from the guys this project belongs to.
apparently this happened when they had triggered a build on jenkins which included a sonar analysis, and this build triggered a downstream build which analyzed the same project via sonar. sometimes, the second build then failed with aforementioned exception.

i always thought jenkins only tags a build as finished when sonar is completely done.
it seems like sometimes there is still some background sonar activity running when the second build reaches its sonar analysis stage.


best

lx


On 07/13/2012 10:57 AM, Freddy Mallet wrote:
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Alexander Lorenz-2
hi ann,


it is not triggered as a build step
it is configured as "build after other projects are built", so classical downstream.


best

alex


On 07/16/2012 02:36 PM, Ann Campbell wrote:
One build can trigger another as either a "downstream" build (build B after A is done) or as a Build Step. And that Build Step can run either in Blocking or non-Blocking mode. 

So it sounds like it was run as a non-blocking build step. I.e. concurrent. :-(


On Mon, Jul 16, 2012 at 8:26 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,

i got more info from the guys this project belongs to.
apparently this happened when they had triggered a build on jenkins which included a sonar analysis, and this build triggered a downstream build which analyzed the same project via sonar. sometimes, the second build then failed with aforementioned exception.

i always thought jenkins only tags a build as finished when sonar is completely done.
it seems like sometimes there is still some background sonar activity running when the second build reaches its sonar analysis stage.


best

lx


On 07/13/2012 10:57 AM, Freddy Mallet wrote:
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | +49-30-756543-194 | www.tomtom.com 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Ann Campbell
And is your analysis Mvn (post-build) or non-Mvn (build step)?

On Mon, Jul 16, 2012 at 8:51 AM, Alexander Lorenz <[hidden email]> wrote:
hi ann,


it is not triggered as a build step
it is configured as "build after other projects are built", so classical downstream.


best

alex


On 07/16/2012 02:36 PM, Ann Campbell wrote:
One build can trigger another as either a "downstream" build (build B after A is done) or as a Build Step. And that Build Step can run either in Blocking or non-Blocking mode. 

So it sounds like it was run as a non-blocking build step. I.e. concurrent. :-(


On Mon, Jul 16, 2012 at 8:26 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,

i got more info from the guys this project belongs to.
apparently this happened when they had triggered a build on jenkins which included a sonar analysis, and this build triggered a downstream build which analyzed the same project via sonar. sometimes, the second build then failed with aforementioned exception.

i always thought jenkins only tags a build as finished when sonar is completely done.
it seems like sometimes there is still some background sonar activity running when the second build reaches its sonar analysis stage.


best

lx


On 07/13/2012 10:57 AM, Freddy Mallet wrote:
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Alexander Lorenz-2
it's non mvn, just the "sonar" check in the jenkins config.
 

On 07/16/2012 02:57 PM, Ann Campbell wrote:
And is your analysis Mvn (post-build) or non-Mvn (build step)?

On Mon, Jul 16, 2012 at 8:51 AM, Alexander Lorenz <[hidden email]> wrote:
hi ann,


it is not triggered as a build step
it is configured as "build after other projects are built", so classical downstream.


best

alex


On 07/16/2012 02:36 PM, Ann Campbell wrote:
One build can trigger another as either a "downstream" build (build B after A is done) or as a Build Step. And that Build Step can run either in Blocking or non-Blocking mode. 

So it sounds like it was run as a non-blocking build step. I.e. concurrent. :-(


On Mon, Jul 16, 2012 at 8:26 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,

i got more info from the guys this project belongs to.
apparently this happened when they had triggered a build on jenkins which included a sonar analysis, and this build triggered a downstream build which analyzed the same project via sonar. sometimes, the second build then failed with aforementioned exception.

i always thought jenkins only tags a build as finished when sonar is completely done.
it seems like sometimes there is still some background sonar activity running when the second build reaches its sonar analysis stage.


best

lx


On 07/13/2012 10:57 AM, Freddy Mallet wrote:
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | +49-30-756543-194 | www.tomtom.com 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Ann Campbell
... Your description makes it sound like a Post-build Action(?)


On Mon, Jul 16, 2012 at 10:31 AM, Alexander Lorenz <[hidden email]> wrote:
it's non mvn, just the "sonar" check in the jenkins config.

 

On 07/16/2012 02:57 PM, Ann Campbell wrote:
And is your analysis Mvn (post-build) or non-Mvn (build step)?

On Mon, Jul 16, 2012 at 8:51 AM, Alexander Lorenz <[hidden email]> wrote:
hi ann,


it is not triggered as a build step
it is configured as "build after other projects are built", so classical downstream.


best

alex


On 07/16/2012 02:36 PM, Ann Campbell wrote:
One build can trigger another as either a "downstream" build (build B after A is done) or as a Build Step. And that Build Step can run either in Blocking or non-Blocking mode. 

So it sounds like it was run as a non-blocking build step. I.e. concurrent. :-(


On Mon, Jul 16, 2012 at 8:26 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,

i got more info from the guys this project belongs to.
apparently this happened when they had triggered a build on jenkins which included a sonar analysis, and this build triggered a downstream build which analyzed the same project via sonar. sometimes, the second build then failed with aforementioned exception.

i always thought jenkins only tags a build as finished when sonar is completely done.
it seems like sometimes there is still some background sonar activity running when the second build reaches its sonar analysis stage.


best

lx


On 07/13/2012 10:57 AM, Freddy Mallet wrote:
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 


--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Alexander Lorenz-2
yes, it's post-build.


On 07/16/2012 05:03 PM, Ann Campbell wrote:
... Your description makes it sound like a Post-build Action(?)


On Mon, Jul 16, 2012 at 10:31 AM, Alexander Lorenz <[hidden email]> wrote:
it's non mvn, just the "sonar" check in the jenkins config.

 

On 07/16/2012 02:57 PM, Ann Campbell wrote:
And is your analysis Mvn (post-build) or non-Mvn (build step)?

On Mon, Jul 16, 2012 at 8:51 AM, Alexander Lorenz <[hidden email]> wrote:
hi ann,


it is not triggered as a build step
it is configured as "build after other projects are built", so classical downstream.


best

alex


On 07/16/2012 02:36 PM, Ann Campbell wrote:
One build can trigger another as either a "downstream" build (build B after A is done) or as a Build Step. And that Build Step can run either in Blocking or non-Blocking mode. 

So it sounds like it was run as a non-blocking build step. I.e. concurrent. :-(


On Mon, Jul 16, 2012 at 8:26 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,

i got more info from the guys this project belongs to.
apparently this happened when they had triggered a build on jenkins which included a sonar analysis, and this build triggered a downstream build which analyzed the same project via sonar. sometimes, the second build then failed with aforementioned exception.

i always thought jenkins only tags a build as finished when sonar is completely done.
it seems like sometimes there is still some background sonar activity running when the second build reaches its sonar analysis stage.


best

lx


On 07/13/2012 10:57 AM, Freddy Mallet wrote:
Hi Alexander,

So let's state that you don't have any concurrent builds. Could you describe what you mean by "every second build" ? Are you able to reproduce this issue easily ?

thanks
Freddy
-----
Sonar for Continuous Inspection



On Thu, Jul 12, 2012 at 10:22 AM, Alexander Lorenz <[hidden email]> wrote:
hi freddy,


we are using 3.1 .

i know of no reason why two analysis should run in parallel: only one jenkins to trigger, and no concurrent builds activated.
maybe there is some general concurrency problem on process or thread level involved?


best regards

alex




On 07/11/2012 09:22 PM, Freddy Mallet wrote:
Hi Alex,

Which Sonar version are you using ?

If you're using Sonar 2.14 or greater, this error can only happen when two analysis on the same project (or on a project and on one of its module) are executed concurrently : http://jira.codehaus.org/browse/SONAR-2761 

Kind regards,
Freddy
-----
Sonar for Continuous Inspection



On Wed, Jul 11, 2012 at 5:10 PM, Alexander Lorenz <[hidden email]> wrote:
hello,


every second build, we get the following exception in sonar. with the next build, about 5 minutes later, everything is fine again.


14:29:58  [INFO] [16:29:58.348] Execute decorators...
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [ERROR] BUILD ERROR
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Can not execute Sonar
14:29:58  
14:29:58  Embedded error: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author],qualifier=BRC]'
14:29:58  Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  [INFO] ------------------------------------------------------------------------
14:29:58  [INFO] Trace
14:29:58  org.apache.maven.lifecycle.LifecycleExecutionException: Can not execute Sonar
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:284)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
14:29:58  	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
14:29:58  	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
14:29:58  	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
14:29:58  	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
14:29:58  	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
14:29:58  	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
14:29:58  	at java.lang.reflect.Method.invoke(Method.java:597)
14:29:58  	at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
14:29:58  	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
14:29:58  	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
14:29:58  	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
14:29:58  Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:103)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:79)
14:29:58  	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:88)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
14:29:58  	... 17 more
14:29:58  Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.Project@4a685810[id=9884,key=[removed by mail author]
,qualifier=BRC]'
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:84)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:70)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:55)
14:29:58  	at org.sonar.batch.phases.Phases.execute(Phases.java:94)
14:29:58  	at org.sonar.batch.bootstrap.ProjectModule.doStart(ProjectModule.java:139)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:115)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.analyze(BatchModule.java:110)
14:29:58  	at org.sonar.batch.bootstrap.BatchModule.doStart(BatchModule.java:105)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrap.BootstrapModule.doStart(BootstrapModule.java:111)
14:29:58  	at org.sonar.batch.bootstrap.Module.start(Module.java:83)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.startBatch(Batch.java:73)
14:29:58  	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:60)
14:29:58  	at org.sonar.maven.SonarMojo.execute(SonarMojo.java:150)
14:29:58  	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
14:29:58  	at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:98)
14:29:58  	... 21 more
14:29:58  Caused by: javax.persistence.EntityNotFoundException: Unable to find org.sonar.api.database.model.Snapshot with id 1458024
14:29:58  	at org.hibernate.ejb.Ejb3Configuration$Ejb3EntityNotFoundDelegate.handleEntityNotFound(Ejb3Configuration.java:113)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.checkTargetState(AbstractLazyInitializer.java:154)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.initialize(AbstractLazyInitializer.java:143)
14:29:58  	at org.hibernate.proxy.AbstractLazyInitializer.getImplementation(AbstractLazyInitializer.java:174)
14:29:58  	at org.hibernate.proxy.pojo.javassist.JavassistLazyInitializer.invoke(JavassistLazyInitializer.java:190)
14:29:58  	at org.sonar.api.database.model.Snapshot_$$_javassist_14.setPeriodMode(Snapshot_$$_javassist_14.java)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.persistConfiguration(TimeMachineConfigurationPersister.java:58)
14:29:58  	at org.sonar.plugins.core.timemachine.TimeMachineConfigurationPersister.decorate(TimeMachineConfigurationPersister.java:50)
14:29:58  	at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:79)
14:29:58  	... 38 more



thanks

alex

-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | <a moz-do-not-send="true" href="tel:%2B49-30-756543-194" value="+4930756543194" target="_blank">+49-30-756543-194 | www.tomtom.com 


--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************



-- 
Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | +49-30-756543-194 | www.tomtom.com 
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: exception in sonar

Ann Campbell
So it looks like Jenkins kicks off "post build" processes (including your Sonar analysis, which is by definition Mvn if it's post-build, BTW) in a non-blocking manner. I've always kinda wondered about the distinction between a build step and a "Post-build Action." I guess now I know.

It looks like your options are to:
1) segregate the analysis of this project into a separate Jenkins job 
2) remove analysis from the downstream job (probably a good idea anyway)
3) bypass the Sonar plugin and trigger your mvn analysis manually as a build step - which likely means you give up the benefits of the centrally-configured Sonar details & have to explicitly re-configure them in your job
4) convert to a non-Mvn, build-step analysis, meaning that you don't have to re-configure the Sonar server details within the job, but you do give up some of the features that maven users get that the rest of us don't.



--
G. Ann Campbell
Sr. Systems Engineer, IS Production Systems - Shop Floor Systems
Shaw Industries Inc,
201 S. Hamilton St.
Dalton Ga 30720


**********************************************************
Privileged and/or confidential information may be contained in this message. If you are not the addressee indicated in this message (or are not responsible for delivery of this message to that person) , you may not copy or deliver this message to anyone. In such case, you should destroy this message and notify the sender by reply e-mail.
If you or your employer do not consent to Internet e-mail for messages of this kind, please advise the sender.
Shaw Industries does not provide or endorse any opinions, conclusions or other information in this message that do not relate to the official business of the company  or its subsidiaries.
**********************************************************

Loading...