|
hi guys,
cobertura crashes with the following output, resulting in a much too low coverage value. we are running kernel 2.6.32. i put in '[XXX]' myself for privacy reasons. 09:46:30 java.lang.reflect.InvocationTargetException 09:46:30 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 09:46:30 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) 09:46:30 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) 09:46:30 at java.lang.reflect.Method.invoke(Method.java:597) 09:46:30 at net.sourceforge.cobertura.util.FileLocker.lock(FileLocker.java:124) 09:46:30 at net.sourceforge.cobertura.coveragedata.ProjectData.saveGlobalProjectData(ProjectData.java:331) 09:46:30 at net.sourceforge.cobertura.coveragedata.SaveTimer.run(SaveTimer.java:31) 09:46:30 at java.lang.Thread.run(Thread.java:662) 09:46:30 Caused by: java.nio.channels.OverlappingFileLockException 09:46:30 at sun.nio.ch.FileChannelImpl$SharedFileLockTable.checkList(FileChannelImpl.java:1166) 09:46:30 at sun.nio.ch.FileChannelImpl$SharedFileLockTable.add(FileChannelImpl.java:1068) 09:46:30 at sun.nio.ch.FileChannelImpl.lock(FileChannelImpl.java:824) 09:46:30 at java.nio.channels.FileChannel.lock(FileChannel.java:860) 09:46:30 ... 8 more 09:46:30 --------------------------------------- 09:46:30 --------------------------------------- 09:46:30 Unable to get lock on /var/lib/jenkins/jobs/[XXX]/target/cobertura/cobertura.ser.lock: null 09:46:30 java.lang.reflect.InvocationTargetException 09:46:30 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 09:46:30 at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) 09:46:30 at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) 09:46:30 at java.lang.reflect.Method.invoke(Method.java:597) 09:46:30 at net.sourceforge.cobertura.util.FileLocker.lock(FileLocker.java:124) 09:46:30 at net.sourceforge.cobertura.coveragedata.ProjectData.saveGlobalProjectData(ProjectData.java:331) 09:46:30 at net.sourceforge.cobertura.coveragedata.SaveTimer.run(SaveTimer.java:31) 09:46:30 at java.lang.Thread.run(Thread.java:662) 09:46:30 Caused by: java.nio.channels.OverlappingFileLockException 09:46:30 at sun.nio.ch.FileChannelImpl$SharedFileLockTable.checkList(FileChannelImpl.java:1166) 09:46:30 at sun.nio.ch.FileChannelImpl$SharedFileLockTable.add(FileChannelImpl.java:1068) 09:46:30 at sun.nio.ch.FileChannelImpl.lock(FileChannelImpl.java:824) 09:46:30 at java.nio.channels.FileChannel.lock(FileChannel.java:860) 09:46:30 ... 8 more 09:46:30 --------------------------------------- 09:46:30 This is known to happen on Linux kernel 2.6.20. 09:46:30 Unable to get lock on /var/lib/jenkins/jobs/[XXX] /target/cobertura/cobertura.ser.lock: null 09:46:30 Make sure cobertura.jar is in the root classpath of the jvm 09:46:30 This is known to happen on Linux kernel 2.6.20. 09:46:30 process running the instrumented code. If the instrumented code 09:46:30 Make sure cobertura.jar is in the root classpath of the jvm 09:46:30 is running in a web server, this means cobertura.jar should be in 09:46:30 process running the instrumented code. If the instrumented code 09:46:30 the web server's lib directory. 09:46:30 is running in a web server, this means cobertura.jar should be in 09:46:30 Don't put multiple copies of cobertura.jar in different WEB-INF/lib directories. 09:46:30 the web server's lib directory. 09:46:30 Only one classloader should load cobertura. It should be the root classloader. 09:46:30 --------------------------------------- 09:46:30 Don't put multiple copies of cobertura.jar in different WEB-INF/lib directories. 09:46:30 Only one classloader should load cobertura. It should be the root classloader. 09:46:30 --------------------------------------- 09:46:30 lock file could not be deleted 09:46:31 Cobertura: Loaded information on 69 classes. 09:46:31 Cobertura: Saved information on 69 classes. 09:46:31 lock file could not be deleted Thanks Alex -- Alexander Lorenz | Test Engineer Traffic | TomTom Content Production Unit Berlin | [hidden email] | +49-30-756543-194 | www.tomtom.com |
|
Hi,
Since it's clear that problem comes from Cobertura - could you try another coverage tool, i.e. JaCoCo ?
On Wed, Jun 27, 2012 at 9:05 PM, Alexander Lorenz <[hidden email]> wrote:
Best regards, Evgeny Mandrikov aka Godin <http://godin.net.ru> http://twitter.com/_godin_ |
|
In reply to this post by Alexander Lorenz-2
Hi Alex
If you are in love with cobertura and you're using Maven for your analysis take a look at this:http://jira.codehaus.org/browse/SONAR-172
You might find it useful Regards Patroklos 2012/6/27 Alexander Lorenz <[hidden email]>
|
| Powered by Nabble | Edit this page |
