SonarOpenCommunity / sonar-cxx

SonarQube C++ Community plugin (cxx plugin): This plugin adds C++ support to SonarQube with the focus on integration of existing C++ tools.
GNU Lesser General Public License v3.0
998 stars 365 forks source link

javax.persistence.PersistenceException #171

Closed guwirth closed 10 years ago

guwirth commented 10 years ago

With current master (6420ed4c6c0bc47d72a7a4ae7740d8519867255a) I get exception below. Is latest version working on your machines?

wrapper  | --> Wrapper Started as Console
wrapper  | Launching a JVM...
jvm 1    | Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org
jvm 1    |   Copyright 1999-2006 Tanuki Software, Inc.  All Rights Reserved.
jvm 1    | 
jvm 1    | 2014-04-16 09:33:13.435:INFO:oejs.Server:jetty-7.6.11.v20130520
jvm 1    | 2014-04-16 09:33:25.015:WARN:oejw.WebAppContext:Failed startup of context o.e.j.w.WebAppContext{/,file:/D:/Sonar/sonar-3.7.3/war/sonar-server/},file:/D:/Sonar/sonar-3.7.3/war/sonar-server
jvm 1    | javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
jvm 1    |  at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:614)
jvm 1    |  at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:226)
jvm 1    |  at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130)
jvm 1    |  at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110)
jvm 1    |  at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225)
jvm 1    |  at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119)
jvm 1    |  at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92)
jvm 1    |  at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at java.lang.reflect.Method.invoke(Unknown Source)
jvm 1    |  at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
jvm 1    |  at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
jvm 1    |  at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
jvm 1    |  at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
jvm 1    |  at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
jvm 1    |  at org.picocontainer.behaviors.Stored.start(Stored.java:110)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766)
jvm 1    |  at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)
jvm 1    |  at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399)
jvm 1    |  at org.sonar.server.platform.Platform.start(Platform.java:206)
jvm 1    |  at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34)
jvm 1    |  at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746)
jvm 1    |  at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238)
jvm 1    |  at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240)
jvm 1    |  at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689)
jvm 1    |  at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482)
jvm 1    |  at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
jvm 1    |  at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229)
jvm 1    |  at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
jvm 1    |  at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95)
jvm 1    |  at org.eclipse.jetty.server.Server.doStart(Server.java:281)
jvm 1    |  at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
jvm 1    |  at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67)
jvm 1    |  at org.sonar.application.StartServer.main(StartServer.java:48)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at java.lang.reflect.Method.invoke(Unknown Source)
jvm 1    |  at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
jvm 1    |  at java.lang.Thread.run(Unknown Source)
jvm 1    | Caused by: 
jvm 1    | org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
jvm 1    |  at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:94)
jvm 1    |  at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
jvm 1    |  at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:64)
jvm 1    |  at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176)
jvm 1    |  at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656)
jvm 1    |  at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71)
jvm 1    |  at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
jvm 1    |  at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321)
jvm 1    |  at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204)
jvm 1    |  at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130)
jvm 1    |  at org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49)
jvm 1    |  at org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154)
jvm 1    |  at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110)
jvm 1    |  at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61)
jvm 1    |  at org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646)
jvm 1    |  at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620)
jvm 1    |  at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624)
jvm 1    |  at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220)
jvm 1    |  at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130)
jvm 1    |  at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110)
jvm 1    |  at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225)
jvm 1    |  at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119)
jvm 1    |  at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92)
jvm 1    |  at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at java.lang.reflect.Method.invoke(Unknown Source)
jvm 1    |  at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
jvm 1    |  at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
jvm 1    |  at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
jvm 1    |  at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
jvm 1    |  at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
jvm 1    |  at org.picocontainer.behaviors.Stored.start(Stored.java:110)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766)
jvm 1    |  at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)
jvm 1    |  at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399)
jvm 1    |  at org.sonar.server.platform.Platform.start(Platform.java:206)
jvm 1    |  at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34)
jvm 1    |  at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746)
jvm 1    |  at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238)
jvm 1    |  at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240)
jvm 1    |  at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689)
jvm 1    |  at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482)
jvm 1    |  at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
jvm 1    |  at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229)
jvm 1    |  at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
jvm 1    |  at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95)
jvm 1    |  at org.eclipse.jetty.server.Server.doStart(Server.java:281)
jvm 1    |  at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
jvm 1    |  at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67)
jvm 1    |  at org.sonar.application.StartServer.main(StartServer.java:48)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at java.lang.reflect.Method.invoke(Unknown Source)
jvm 1    |  at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
jvm 1    |  at java.lang.Thread.run(Unknown Source)
jvm 1    | Caused by: 
jvm 1    | org.h2.jdbc.JdbcSQLException: Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement:|insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172]<|?at org.h2.message.DbException.getJdbcSQLException(DbException.java:329)<|?at org.h2.message.DbException.get(DbException.java:169)<|?at org.h2.message.DbException.get(DbException.java:146)<|?at org.h2.index.BaseIndex.getDuplicateKeyException(BaseIndex.java:83)<|?at org.h2.index.PageBtree.find(PageBtree.java:121)<|?at org.h2.index.PageBtreeLeaf.addRow(PageBtreeLeaf.java:148)<|?at org.h2.index.PageBtreeLeaf.addRowTry(PageBtreeLeaf.java:101)<|?at org.h2.index.PageBtreeNode.addRowTry(PageBtreeNode.java:201)<|?at org.h2.index.PageBtreeNode.addRowTry(PageBtreeNode.java:201)<|?at org.h2.index.PageBtreeIndex.addRow(PageBtreeIndex.java:104)<|?at org.h2.index.PageBtreeIndex.add(PageBtreeIndex.java:95)<|?at org.h2.table.RegularTable.addRow(RegularTable.java:124)<|?at org.h2.command.dml.Insert.insertRows(Insert.java:126)<|?at org.h2.command.dml.Insert.update(Insert.java:86)<|?at org.h2.command.CommandContainer.update(CommandContainer.java:79)<|?at org.h2.command.Command.executeUpdate(Command.java:235)<|?at org.h2.server.TcpServerThread.process(TcpServerThread.java:335)<|?at org.h2.server.TcpServerThread.run(TcpServerThread.java:151)<|?at java.lang.Thread.run(Unknown Source)<|
jvm 1    |  at org.h2.engine.SessionRemote.done(SessionRemote.java:579)
jvm 1    |  at org.h2.command.CommandRemote.executeUpdate(CommandRemote.java:186)
jvm 1    |  at org.h2.jdbc.JdbcPreparedStatement.executeUpdateInternal(JdbcPreparedStatement.java:154)
jvm 1    |  at org.h2.jdbc.JdbcPreparedStatement.executeUpdate(JdbcPreparedStatement.java:140)
jvm 1    |  at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
jvm 1    |  at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
jvm 1    |  at org.hibernate.id.IdentityGenerator$GetGeneratedKeysDelegate.executeAndExtract(IdentityGenerator.java:94)
jvm 1    |  at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:57)
jvm 1    |  at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176)
jvm 1    |  at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656)
jvm 1    |  at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71)
jvm 1    |  at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
jvm 1    |  at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321)
jvm 1    |  at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204)
jvm 1    |  at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130)
jvm 1    |  at org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49)
jvm 1    |  at org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154)
jvm 1    |  at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110)
jvm 1    |  at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61)
jvm 1    |  at org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646)
jvm 1    |  at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620)
jvm 1    |  at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624)
jvm 1    |  at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220)
jvm 1    |  at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130)
jvm 1    |  at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110)
jvm 1    |  at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225)
jvm 1    |  at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119)
jvm 1    |  at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92)
jvm 1    |  at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
jvm 1    |  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
jvm 1    |  at java.lang.reflect.Method.invoke(Unknown Source)
jvm 1    |  at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
jvm 1    |  at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
jvm 1    |  at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
jvm 1    |  at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
jvm 1    |  at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
jvm 1    |  at org.picocontainer.behaviors.Stored.start(Stored.java:110)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008)
jvm 1    |  at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766)
jvm 1    |  at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)
jmecosta commented 10 years ago

Can you check the server log On Apr 16, 2014 10:39 AM, "Günter Wirth" notifications@github.com wrote:

With current master (6420ed4https://github.com/wenns/sonar-cxx/commit/6420ed4c6c0bc47d72a7a4ae7740d8519867255a) I get exception below. Is latest version working on your machines?

wrapper | --> Wrapper Started as Console wrapper | Launching a JVM... jvm 1 | Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org jvm 1 | Copyright 1999-2006 Tanuki Software, Inc. All Rights Reserved. jvm 1 | jvm 1 | 2014-04-16 09:33:13.435:INFO:oejs.Server:jetty-7.6.11.v20130520 jvm 1 | 2014-04-16 09:33:25.015:WARN:oejw.WebAppContext:Failed startup of context o.e.j.w.WebAppContext{/,file:/D:/Sonar/sonar-3.7.3/war/sonar-server/},file:/D:/Sonar/sonar-3.7.3/war/sonar-server jvm 1 | javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule] jvm 1 | at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:614) jvm 1 | at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:226) jvm 1 | at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130) jvm 1 | at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110) jvm 1 | at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225) jvm 1 | at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119) jvm 1 | at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92) jvm 1 | at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at java.lang.reflect.Method.invoke(Unknown Source) jvm 1 | at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110) jvm 1 | at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89) jvm 1 | at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84) jvm 1 | at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169) jvm 1 | at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132) jvm 1 | at org.picocontainer.behaviors.Stored.start(Stored.java:110) jvm 1 | at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015) jvm 1 | at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008) jvm 1 | at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766) jvm 1 | at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91) jvm 1 | at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399) jvm 1 | at org.sonar.server.platform.Platform.start(Platform.java:206) jvm 1 | at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34) jvm 1 | at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746) jvm 1 | at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238) jvm 1 | at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240) jvm 1 | at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689) jvm 1 | at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482) jvm 1 | at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) jvm 1 | at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229) jvm 1 | at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) jvm 1 | at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95) jvm 1 | at org.eclipse.jetty.server.Server.doStart(Server.java:281) jvm 1 | at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) jvm 1 | at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67) jvm 1 | at org.sonar.application.StartServer.main(StartServer.java:48) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at java.lang.reflect.Method.invoke(Unknown Source) jvm 1 | at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240) jvm 1 | at java.lang.Thread.run(Unknown Source) jvm 1 | Caused by: jvm 1 | org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule] jvm 1 | at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:94) jvm 1 | at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66) jvm 1 | at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:64) jvm 1 | at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176) jvm 1 | at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656) jvm 1 | at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71) jvm 1 | at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279) jvm 1 | at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321) jvm 1 | at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204) jvm 1 | at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130) jvm 1 | at org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49) jvm 1 | at org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154) jvm 1 | at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110) jvm 1 | at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61) jvm 1 | at org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646) jvm 1 | at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620) jvm 1 | at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624) jvm 1 | at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220) jvm 1 | at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130) jvm 1 | at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110) jvm 1 | at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225) jvm 1 | at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119) jvm 1 | at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92) jvm 1 | at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at java.lang.reflect.Method.invoke(Unknown Source) jvm 1 | at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110) jvm 1 | at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89) jvm 1 | at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84) jvm 1 | at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169) jvm 1 | at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132) jvm 1 | at org.picocontainer.behaviors.Stored.start(Stored.java:110) jvm 1 | at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015) jvm 1 | at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008) jvm 1 | at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766) jvm 1 | at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91) jvm 1 | at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399) jvm 1 | at org.sonar.server.platform.Platform.start(Platform.java:206) jvm 1 | at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34) jvm 1 | at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746) jvm 1 | at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238) jvm 1 | at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240) jvm 1 | at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689) jvm 1 | at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482) jvm 1 | at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) jvm 1 | at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229) jvm 1 | at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) jvm 1 | at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95) jvm 1 | at org.eclipse.jetty.server.Server.doStart(Server.java:281) jvm 1 | at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) jvm 1 | at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67) jvm 1 | at org.sonar.application.StartServer.main(StartServer.java:48) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at java.lang.reflect.Method.invoke(Unknown Source) jvm 1 | at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240) jvm 1 | at java.lang.Thread.run(Unknown Source) jvm 1 | Caused by: jvm 1 | org.h2.jdbc.JdbcSQLException: Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement:|insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172]<|?at org.h2.message.DbException.getJdbcSQLException(DbException.java:329)<|?at org.h2.message.DbException.get(DbException.java:169)<|?at org.h2.message.DbException.get(DbException.java:146)<|?at org.h2.index.BaseIndex.getDuplicateKeyException(BaseIndex.java:83)<|?at org.h2.index.PageBtree.find(PageBtree.java:121)<|?at org.h2.index.PageBtreeLeaf.addRow(PageBtreeLeaf.java:148)<|?at org.h2.index.PageBtreeLeaf.addRowTry(PageBtreeLeaf.java:101)<|?at org.h2.index.PageBtreeNode.addRowTry(PageBtreeNode.java:201)<|?at org.h2.index.PageBtreeNode.addRowTry(PageBtreeNode.java:2 01)<|?at org.h2.index.PageBtreeIndex.addRow(PageBtreeIndex.java:104)<|?at org.h2.index.PageBtreeIndex.add(PageBtreeIndex.java:95)<|?at org.h2.table.RegularTable.addRow(RegularTable.java:124)<|?at org.h2.command.dml.Insert.insertRows(Insert.java:126)<|?at org.h2.command.dml.Insert.update(Insert.java:86)<|?at org.h2.command.CommandContainer.update(CommandContainer.java:79)<|?at org.h2.command.Command.executeUpdate(Command.java:235)<|?at org.h2.server.TcpServerThread.process(TcpServerThread.java:335)<|?at org.h2.server.TcpServerThread.run(TcpServerThread.java:151)<|?at java.lang.Thread.run(Unknown Source)<| jvm 1 | at org.h2.engine.SessionRemote.done(SessionRemote.java:579) jvm 1 | at org.h2.command.CommandRemote.executeUpdate(CommandRemote.java:186) jvm 1 | at org.h2.jdbc.JdbcPreparedStatement.executeUpdateInternal(JdbcPreparedStatement.java:154) jvm 1 | at org.h2.jdbc.JdbcPreparedStatement.executeUpdate(JdbcPreparedStatement.java:140) jvm 1 | at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105) jvm 1 | at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105) jvm 1 | at org.hibernate.id.IdentityGenerator$GetGeneratedKeysDelegate.executeAndExtract(IdentityGenerator.java:94) jvm 1 | at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:57) jvm 1 | at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176) jvm 1 | at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656) jvm 1 | at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71) jvm 1 | at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279) jvm 1 | at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321) jvm 1 | at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204) jvm 1 | at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130) jvm 1 | at org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49) jvm 1 | at org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154) jvm 1 | at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110) jvm 1 | at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61) jvm 1 | at org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646) jvm 1 | at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620) jvm 1 | at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624) jvm 1 | at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220) jvm 1 | at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130) jvm 1 | at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110) jvm 1 | at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225) jvm 1 | at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119) jvm 1 | at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92) jvm 1 | at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) jvm 1 | at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) jvm 1 | at java.lang.reflect.Method.invoke(Unknown Source) jvm 1 | at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110) jvm 1 | at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89) jvm 1 | at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84) jvm 1 | at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169) jvm 1 | at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132) jvm 1 | at org.picocontainer.behaviors.Stored.start(Stored.java:110) jvm 1 | at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015) jvm 1 | at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008) jvm 1 | at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766) jvm 1 | at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)

— Reply to this email directly or view it on GitHubhttps://github.com/wenns/sonar-cxx/issues/171 .

guwirth commented 10 years ago

Server log:

STATUS | wrapper  | 2014/04/16 13:24:12 | --> Wrapper Started as Console
STATUS | wrapper  | 2014/04/16 13:24:12 | Launching a JVM...
INFO   | jvm 1    | 2014/04/16 13:24:13 | Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org
INFO   | jvm 1    | 2014/04/16 13:24:13 |   Copyright 1999-2006 Tanuki Software, Inc.  All Rights Reserved.
INFO   | jvm 1    | 2014/04/16 13:24:13 | 
INFO   | jvm 1    | 2014/04/16 13:24:13 | 2014-04-16 13:24:13.751:INFO:oejs.Server:jetty-7.6.11.v20130520
2014.04.16 13:24:18 INFO  o.s.s.p.ServerImpl  SonarQube Server / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:21 INFO  o.s.s.d.EmbeddedDatabase  Starting embedded database on port 9092 with url jdbc:h2:tcp://localhost:9092/sonar
2014.04.16 13:24:21 INFO  o.s.s.d.EmbeddedDatabase  Embedded database started. Data stored in: D:\Sonar\sonar-3.7.3\data
2014.04.16 13:24:21 WARN  o.s.c.p.DefaultDatabase  H2 database should be used for evaluation purpose only
2014.04.16 13:24:21 INFO  o.s.c.p.Database  Create JDBC datasource for jdbc:h2:tcp://localhost:9092/sonar
2014.04.16 13:24:21 INFO  o.s.s.p.DefaultServerFileSystem  SonarQube home: D:\Sonar\sonar-3.7.3
2014.04.16 13:24:21 INFO  o.s.s.p.DefaultServerFileSystem  Deploy dir: D:\Sonar\sonar-3.7.3\war\sonar-server\deploy
2014.04.16 13:24:21 INFO  org.sonar.INFO  Install plugins...
2014.04.16 13:24:22 INFO  o.s.s.p.PluginDeployer  Deploy plugin Findbugs / 1.3 / 4d7d78e9340e39f53bbf202ed16d1253e6507c36
2014.04.16 13:24:22 INFO  o.s.s.p.PluginDeployer  Deploy plugin DPL / 0.5
2014.04.16 13:24:22 INFO  o.s.s.p.PluginDeployer  Deploy plugin JaCoCo / 1.3 / 4d7d78e9340e39f53bbf202ed16d1253e6507c36
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin English Pack / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin Maven Batch Plugin / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin Surefire / 1.3 / 4d7d78e9340e39f53bbf202ed16d1253e6507c36
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin Duplications / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin C++ (Community) / 1.0-SNAPSHOT / 0
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin Checkstyle / 1.3 / 4d7d78e9340e39f53bbf202ed16d1253e6507c36
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin PMD / 1.3 / 4d7d78e9340e39f53bbf202ed16d1253e6507c36
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin Java / 1.3 / 4d7d78e9340e39f53bbf202ed16d1253e6507c36
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin Core / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:23 INFO  o.s.s.p.PluginDeployer  Deploy plugin Database Cleaner / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:24 INFO  o.s.s.p.PluginDeployer  Deploy plugin Squid for Java / 1.3 / 4d7d78e9340e39f53bbf202ed16d1253e6507c36
2014.04.16 13:24:24 INFO  o.s.s.p.PluginDeployer  Deploy plugin Technical Debt / 1.2.1
2014.04.16 13:24:24 INFO  o.s.s.p.PluginDeployer  Deploy plugin Email notifications / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:24 INFO  o.s.s.p.PluginDeployer  Deploy plugin Design / 3.7.3 / b241d9e47bbe7694cbe7574817240cef214fd316
2014.04.16 13:24:24 INFO  org.sonar.INFO  Install plugins done: 2566 ms
2014.04.16 13:24:24 INFO  o.s.s.p.ApplicationDeployer  Deploy Ruby on Rails applications
2014.04.16 13:24:24 INFO  org.sonar.INFO  Start components...
2014.04.16 13:24:24 INFO  o.s.j.s.AbstractDatabaseConnector  Initializing Hibernate
2014.04.16 13:24:25 INFO  o.s.s.p.UpdateCenterClient  Update center: http://update.sonarsource.org/update-center.properties (no proxy)
2014.04.16 13:24:25 INFO  o.s.s.n.NotificationService  Notification service started (delay 60 sec.)
2014.04.16 13:24:25 INFO  org.sonar.INFO  Deploy GWT plugins...
2014.04.16 13:24:25 INFO  org.sonar.INFO  Deploy org.sonar.plugins.design.ui.libraries.LibrariesPage to D:\Sonar\sonar-3.7.3\war\sonar-server\deploy\gwt
2014.04.16 13:24:26 INFO  org.sonar.INFO  Deploy org.sonar.plugins.design.ui.page.DesignPage to D:\Sonar\sonar-3.7.3\war\sonar-server\deploy\gwt
2014.04.16 13:24:26 INFO  org.sonar.INFO  Deploy GWT plugins done: 200 ms
2014.04.16 13:24:26 INFO  org.sonar.INFO  Load metrics...
2014.04.16 13:24:26 INFO  o.s.s.s.RegisterMetrics  cleaning alert thresholds...
2014.04.16 13:24:26 INFO  org.sonar.INFO  Load metrics done: 281 ms
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [findbugs/java]...
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [findbugs/java] done: 288 ms
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [rats/c++]...
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [rats/c++] done: 129 ms
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [cppcheck/c++]...
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [cppcheck/c++] done: 114 ms
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [pclint/c++]...
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [pclint/c++] done: 377 ms
2014.04.16 13:24:27 INFO  org.sonar.INFO  Register rules [compiler/c++]...
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [compiler/c++] done: 184 ms
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [compiler-gcc/c++]...
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [compiler-gcc/c++] done: 89 ms
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [vera++/c++]...
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [vera++/c++] done: 8 ms
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [valgrind/c++]...
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [valgrind/c++] done: 5 ms
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [cxxexternal/c++]...
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [cxxexternal/c++] done: 0 ms
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [cxx/c++]...
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [cxx/c++] done: 61 ms
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [checkstyle/java]...
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [checkstyle/java] done: 294 ms
2014.04.16 13:24:28 INFO  org.sonar.INFO  Register rules [pmd/java]...
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [pmd/java] done: 403 ms
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [pmd-unit-tests/java]...
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [pmd-unit-tests/java] done: 18 ms
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [squid/java]...
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [squid/java] done: 115 ms
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [common-c++/c++]...
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [common-c++/c++] done: 2 ms
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [compiler/c++]...
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [compiler/c++] done: 30 ms
2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [compiler-gcc/c++]...
2014.04.16 13:24:29 WARN  o.h.u.JDBCExceptionReporter  SQL Error: 23505, SQLState: 23505
2014.04.16 13:24:29 ERROR o.h.u.JDBCExceptionReporter  Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement:
insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172]
2014.04.16 13:24:29 ERROR o.s.s.p.Platform  org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
    at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:614) ~[hibernate-entitymanager-3.4.0.GA.jar:3.4.0.GA]
    at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:226) ~[hibernate-entitymanager-3.4.0.GA.jar:3.4.0.GA]
    at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130) ~[sonar-core-3.7.3.jar:na]
    at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110) ~[sonar-core-3.7.3.jar:na]
    at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225) ~[classes/:na]
    at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119) ~[classes/:na]
    at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92) ~[classes/:na]
    at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71) ~[classes/:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_51]
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.7.0_51]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.7.0_51]
    at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.7.0_51]
    at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.behaviors.Stored.start(Stored.java:110) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008) ~[picocontainer-2.14.3.jar:na]
    at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766) ~[picocontainer-2.14.3.jar:na]
    at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91) ~[sonar-plugin-api-3.7.3.jar:na]
    at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399) ~[classes/:na]
    at org.sonar.server.platform.Platform.start(Platform.java:206) ~[classes/:na]
    at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34) [classes/:na]
    at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746) [jetty-server-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238) [jetty-servlet-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240) [jetty-webapp-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689) [jetty-server-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482) [jetty-webapp-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) [jetty-util-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229) [jetty-server-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) [jetty-util-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95) [jetty-server-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.server.Server.doStart(Server.java:281) [jetty-server-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) [jetty-util-7.6.11.v20130520.jar:7.6.11.v20130520]
    at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67) [sonar-application-3.7.3.jar:na]
    at org.sonar.application.StartServer.main(StartServer.java:48) [sonar-application-3.7.3.jar:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_51]
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.7.0_51]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.7.0_51]
    at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.7.0_51]
    at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240) [wrapper-3.2.3.jar:3.2.3]
    at java.lang.Thread.run(Unknown Source) [na:1.7.0_51]
Caused by: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
    at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:94) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:64) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49) ~[hibernate-entitymanager-3.4.0.GA.jar:3.4.0.GA]
    at org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220) ~[hibernate-entitymanager-3.4.0.GA.jar:3.4.0.GA]
    ... 42 common frames omitted
Caused by: org.h2.jdbc.JdbcSQLException: Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement:
insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172]
    at org.h2.engine.SessionRemote.done(SessionRemote.java:579) ~[h2-1.3.172.jar:1.3.172]
    at org.h2.command.CommandRemote.executeUpdate(CommandRemote.java:186) ~[h2-1.3.172.jar:1.3.172]
    at org.h2.jdbc.JdbcPreparedStatement.executeUpdateInternal(JdbcPreparedStatement.java:154) ~[h2-1.3.172.jar:1.3.172]
    at org.h2.jdbc.JdbcPreparedStatement.executeUpdate(JdbcPreparedStatement.java:140) ~[h2-1.3.172.jar:1.3.172]
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105) ~[commons-dbcp-1.4.jar:1.4]
    at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105) ~[commons-dbcp-1.4.jar:1.4]
    at org.hibernate.id.IdentityGenerator$GetGeneratedKeysDelegate.executeAndExtract(IdentityGenerator.java:94) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:57) ~[hibernate-core-3.3.2.GA.jar:3.3.2.GA]
    ... 57 common frames omitted
INFO   | jvm 1    | 2014/04/16 13:24:29 | 2014-04-16 13:24:29.211:WARN:oejw.WebAppContext:Failed startup of context o.e.j.w.WebAppContext{/,file:/D:/Sonar/sonar-3.7.3/war/sonar-server/},file:/D:/Sonar/sonar-3.7.3/war/sonar-server
INFO   | jvm 1    | 2014/04/16 13:24:29 | javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:614)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:226)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.reflect.Method.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.Stored.start(Stored.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.Platform.start(Platform.java:206)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.Server.doStart(Server.java:281)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.application.StartServer.main(StartServer.java:48)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.reflect.Method.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.Thread.run(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 | Caused by: 
INFO   | jvm 1    | 2014/04/16 13:24:29 | org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:94)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.reflect.Method.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.Stored.start(Stored.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.Platform.start(Platform.java:206)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.Server.doStart(Server.java:281)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.application.StartServer.main(StartServer.java:48)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.reflect.Method.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.Thread.run(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 | Caused by: 
INFO   | jvm 1    | 2014/04/16 13:24:29 | org.h2.jdbc.JdbcSQLException: Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement:|insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172]<|?at org.h2.message.DbException.getJdbcSQLException(DbException.java:329)<|?at org.h2.message.DbException.get(DbException.java:169)<|?at org.h2.message.DbException.get(DbException.java:146)<|?at org.h2.index.BaseIndex.getDuplicateKeyException(BaseIndex.java:83)<|?at org.h2.index.PageBtree.find(PageBtree.java:121)<|?at org.h2.index.PageBtreeLeaf.addRow(PageBtreeLeaf.java:148)<|?at org.h2.index.PageBtreeLeaf.addRowTry(PageBtreeLeaf.java:101)<|?at org.h2.index.PageBtreeNode.addRowTry(PageBtreeNode.java:201)<|?at org.h2.index.PageBtreeNode.addRowTry(PageBtreeNode.java:201)<|?at org.h2.index.PageBtreeIndex.addRow(PageBtreeIndex.java:104)<|?at org.h2.index.PageBtreeIndex.add(PageBtreeIndex.java:95)<|?at org.h2.table.RegularTable.addRow(RegularTable.java:124)<|?at org.h2.command.dml.Insert.insertRows(Insert.java:126)<|?at org.h2.command.dml.Insert.update(Insert.java:86)<|?at org.h2.command.CommandContainer.update(CommandContainer.java:79)<|?at org.h2.command.Command.executeUpdate(Command.java:235)<|?at org.h2.server.TcpServerThread.process(TcpServerThread.java:335)<|?at org.h2.server.TcpServerThread.run(TcpServerThread.java:151)<|?at java.lang.Thread.run(Unknown Source)<|
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.h2.engine.SessionRemote.done(SessionRemote.java:579)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.h2.command.CommandRemote.executeUpdate(CommandRemote.java:186)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.h2.jdbc.JdbcPreparedStatement.executeUpdateInternal(JdbcPreparedStatement.java:154)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.h2.jdbc.JdbcPreparedStatement.executeUpdate(JdbcPreparedStatement.java:140)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:105)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.id.IdentityGenerator$GetGeneratedKeysDelegate.executeAndExtract(IdentityGenerator.java:94)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:57)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.reflect.Method.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.behaviors.Stored.start(Stored.java:110)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.Platform.start(Platform.java:206)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.server.Server.doStart(Server.java:281)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.sonar.application.StartServer.main(StartServer.java:48)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.reflect.Method.invoke(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
INFO   | jvm 1    | 2014/04/16 13:24:29 |   at java.lang.Thread.run(Unknown Source)
INFO   | jvm 1    | 2014/04/16 13:24:29 | 2014-04-16 13:24:29.338:INFO:oejs.AbstractConnector:Started SelectChannelConnector@0.0.0.0:9000
guwirth commented 10 years ago

It is Register rules [compiler-gcc/c++]:

2014.04.16 13:24:29 INFO  org.sonar.INFO  Register rules [compiler-gcc/c++]...
2014.04.16 13:24:29 WARN  o.h.u.JDBCExceptionReporter  SQL Error: 23505, SQLState: 23505
2014.04.16 13:24:29 ERROR o.h.u.JDBCExceptionReporter  Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement:
insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172]
2014.04.16 13:24:29 ERROR o.s.s.p.Platform  org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule]
    at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:614) ~[hibernate-entitymanager-3.4.0.GA.jar:3.4.0.GA]
jmecosta commented 10 years ago

I think its new to me, can you check if in the profile XML we have duplicates.

Altought the error is different I've had also issues due to duplicated entries in cppcheck profile On Apr 16, 2014 2:33 PM, "Günter Wirth" notifications@github.com wrote:

It is Register rules [compiler-gcc/c++]:

2014.04.16 13:24:29 INFO org.sonar.INFO Register rules [compiler-gcc/c++]... 2014.04.16 13:24:29 WARN o.h.u.JDBCExceptionReporter SQL Error: 23505, SQLState: 23505 2014.04.16 13:24:29 ERROR o.h.u.JDBCExceptionReporter Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement: insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172] 2014.04.16 13:24:29 ERROR o.s.s.p.Platform org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule] javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule] at org.hibernate.ejb.AbstractEntityManagerImpl.throwPersistenceException(AbstractEntityManagerImpl.java:614) ~[hibernate-entitymanager-3.4.0.GA.jar:3.4.0.GA]

— Reply to this email directly or view it on GitHubhttps://github.com/wenns/sonar-cxx/issues/171#issuecomment-40588720 .

guwirth commented 10 years ago

removing all rule items from file solves the problem

jmecosta commented 10 years ago

You mean you remove only the cases above and it worked. Guess this needs to be patched On Apr 16, 2014 3:37 PM, "Günter Wirth" notifications@github.com wrote:

  • found no duplicates in compiler-gcc.xml
  • one key has blanks:'enabled by default'
  • keys starting with minus: '-Wabi'
  • some keys have special characters: '-Wc++0x-compat'

removing all rule items from file solves the problem

— Reply to this email directly or view it on GitHubhttps://github.com/wenns/sonar-cxx/issues/171#issuecomment-40593313 .

guwirth commented 10 years ago

No. Mean I'm using an empty compiler-gcc.xml file and it works. Wondering if other topics above could be the problem?

<?xml version="1.0" encoding="UTF-8"?>
<rules>
</rules>
jmecosta commented 10 years ago

What version of sonar are you using, ive tried with sonar 4.2 and latest and no issues. Im using postgresql, can you try with the default database. On Apr 16, 2014 7:41 PM, "Günter Wirth" notifications@github.com wrote:

No. Mean I'm using an empty compiler-gcc.xml file and it works. Wondering if other topics above could be the problem?

<?xml version="1.0" encoding="UTF-8"?>

— Reply to this email directly or view it on GitHubhttps://github.com/wenns/sonar-cxx/issues/171#issuecomment-40622167 .

guwirth commented 10 years ago

Version 3.7.3 Database H2 1.3.172 (2013-05-25) Java Version 1.7.0_51-b13

jmecosta commented 10 years ago

OK but you are already using the default. I suggest you try then with a proper postgres or mysql

Thats normally the recommendation the sonar guys say On Apr 16, 2014 10:47 PM, "Günter Wirth" notifications@github.com wrote:

Version 3.7.3 Database H2 1.3.172 (2013-05-25) Java Version 1.7.0_51-b13

— Reply to this email directly or view it on GitHubhttps://github.com/wenns/sonar-cxx/issues/171#issuecomment-40643436 .

wenns commented 10 years ago

I do get those errors too, even if I disable both compiler and compiler-gcc rule repos with //l.add(CxxCompilerVcRuleRepository.class); //l.add(CxxCompilerGccRuleRepository.class);

then the error comes after registering cppcheck rules:

... 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [compiler/c++]... 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [compiler/c++] done: 290 ms 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [gcc/c++]... 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [gcc/c++] done: 13 ms 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [cppcheck/c++]... 2014.04.17 08:44:00 WARN o.h.u.JDBCExceptionReporter SQL Error: 23505, SQLState: 23505 2014.04.17 08:44:00 ERROR o.h.u.JDBCExceptionReporter Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement: insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172] 2014.04.17 08:44:00 ERROR jruby.rack initialization failed org.jruby.rack.RackInitializationException: javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule] ...

I dont get this on 4.2RC1 BTW, but on 4.0. Something fishy is going on. As of databases used: I use the default here. That doesnt matter though: we should be able to boot the plugin on every supported DB.

jmecosta commented 10 years ago

Sure, agreed. However I would like to see if this happens only with default or all. If this is only with the default we can ask sonar team why is so. Maybe they know something we don't. On Apr 17, 2014 9:49 AM, "Waleri Enns" notifications@github.com wrote:

I do get those errors too, even if I disable both compiler and compiler-gcc rule repos with //l.add(CxxCompilerVcRuleRepository.class); //l.add(CxxCompilerGccRuleRepository.class);

then the error comes after registering cppcheck rules:

... 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [compiler/c++]... 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [compiler/c++] done: 290 ms 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [gcc/c++]... 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [gcc/c++] done: 13 ms 2014.04.17 08:44:00 INFO org.sonar.INFO Register rules [cppcheck/c++]... 2014.04.17 08:44:00 WARN o.h.u.JDBCExceptionReporter SQL Error: 23505, SQLState: 23505 2014.04.17 08:44:00 ERROR o.h.u.JDBCExceptionReporter Unique index or primary key violation: "RULES_PLUGIN_KEY_AND_NAME ON PUBLIC.RULES(PLUGIN_RULE_KEY, PLUGIN_NAME)"; SQL statement: insert into rules (id, cardinality, plugin_config_key, created_at, description, plugin_rule_key, language, name, parent_id, plugin_name, priority, status, updated_at) values (null, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) [23505-172] 2014.04.17 08:44:00 ERROR jruby.rack initialization failed org.jruby.rack.RackInitializationException: javax.persistence.PersistenceException: org.hibernate.exception.ConstraintViolationException: could not insert: [org.sonar.api.rules.Rule] ...

I dont get this on 4.2RC1 BTW, but on 4.0. Something fishy is going on. As of databases used: I use the default here. That doesnt matter though: we should be able to boot the plugin on every supported DB.

— Reply to this email directly or view it on GitHubhttps://github.com/wenns/sonar-cxx/issues/171#issuecomment-40686066 .

guwirth commented 10 years ago

Debugger Console:

User program running
Exception org.hibernate.exception.ConstraintViolationException(<No current context>) breakpoint hit in org.hibernate.id.insert.AbstractReturningDelegate at line 64 by thread WrapperSimpleAppMain.
Exception org.hibernate.exception.ConstraintViolationException(<No current context>) breakpoint hit in org.hibernate.id.insert.AbstractReturningDelegate at line 64 by thread WrapperSimpleAppMain.
Thread WrapperSimpleAppMain stopped at AbstractReturningDelegate.java:64.

Call stack first exception:

"WrapperSimpleAppMain"
org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:64)
org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2176)
org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2656)
org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:71)
org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:321)
org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:204)
org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:130)
org.hibernate.ejb.event.EJB3PersistEventListener.saveWithGeneratedId(EJB3PersistEventListener.java:49)
org.hibernate.event.def.DefaultPersistEventListener.entityIsTransient(DefaultPersistEventListener.java:154)
org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:110)
org.hibernate.event.def.DefaultPersistEventListener.onPersist(DefaultPersistEventListener.java:61)
org.hibernate.impl.SessionImpl.firePersist(SessionImpl.java:646)
org.hibernate.impl.SessionImpl.persist(SessionImpl.java:620)
org.hibernate.impl.SessionImpl.persist(SessionImpl.java:624)
org.hibernate.ejb.AbstractEntityManagerImpl.persist(AbstractEntityManagerImpl.java:220)
org.sonar.jpa.session.JpaDatabaseSession.internalSave(JpaDatabaseSession.java:130)
org.sonar.jpa.session.JpaDatabaseSession.saveWithoutFlush(JpaDatabaseSession.java:110)
org.sonar.server.startup.RegisterRules.saveNewRules(RegisterRules.java:225)
org.sonar.server.startup.RegisterRules.registerRepositoryRules(RegisterRules.java:119)
org.sonar.server.startup.RegisterRules.registerRules(RegisterRules.java:92)
org.sonar.server.startup.RegisterRules.start(RegisterRules.java:71)
sun.reflect.NativeMethodAccessorImpl.invoke0
sun.reflect.NativeMethodAccessorImpl.invoke
sun.reflect.DelegatingMethodAccessorImpl.invoke
java.lang.reflect.Method.invoke
org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
org.picocontainer.behaviors.Stored.start(Stored.java:110)
org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1015)
org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1008)
org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:766)
org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:91)
org.sonar.server.platform.Platform.executeStartupTasks(Platform.java:399)
org.sonar.server.platform.Platform.start(Platform.java:206)
org.sonar.server.platform.PlatformLifecycleListener.contextInitialized(PlatformLifecycleListener.java:34)
org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746)
org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238)
org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1240)
org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:689)
org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:482)
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
org.eclipse.jetty.server.handler.HandlerCollection.doStart(HandlerCollection.java:229)
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:95)
org.eclipse.jetty.server.Server.doStart(Server.java:281)
org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64)
org.sonar.application.JettyEmbedder.start(JettyEmbedder.java:67)
org.sonar.application.StartServer.main(StartServer.java:48)
sun.reflect.NativeMethodAccessorImpl.invoke0
sun.reflect.NativeMethodAccessorImpl.invoke
sun.reflect.DelegatingMethodAccessorImpl.invoke
java.lang.reflect.Method.invoke
org.tanukisoftware.wrapper.WrapperSimpleApp.run(WrapperSimpleApp.java:240)
java.lang.Thread.run
jmecosta commented 10 years ago

apparently with this new version, the CxxRuleRepositoryProvider will make the registration of rules occur twice. So the duplicate entries. Seems the rules are registered just fine without this.

guwirth commented 10 years ago

Working again, tested with 2f808199a06474ce91bd2527cc7569ce98eaea91