java.sql.SQLException: Cannot drop index 'index_ao_7deabf_ste1617810863': needed in a foreign key constraint

Atlassian JIRA | Ignat Alexeyenko | 4 months ago
  1. 0

    h3. JIRA 7.2 RC02 throwing Errors for MySQL   h3. Environment * JIRA 7.2-Server-RC02 * MySQL h3. Steps to Reproduce Do either of these options * Database Set up * XML Restore * ReIndex Process with our plugin and the error it triggers h3. Expected Results All operations finish successfully, without andy database-releated exceptions. h3. Actual Results * Exception on database setup ** java.lang.RuntimeException: Unable to obtain a connection from the underlying connection pool   *  Exception on Data Restore (XML Restore) The last packet successfully received from the server was 3 milliseconds ago. The last packet sent successfully to the server was 3 milliseconds ago.) java.lang.RuntimeException: com.atlassian.jira.exception.DataAccessException: org.ofbiz.core.entity.GenericDataSourceException: Unable to establish a connection with the database. (Communications link failure   * Reindex causes the dropping index errors: at com.atlassian.sal.core.executor.ThreadLocalDelegateCallable.call(ThreadLocalDelegateCallable.java:42) at java.util.concurrent.FutureTask.run(Unknown Source) *During DB Set up* {noformat} 2016-07-21 22:47:31,961 http-nio-8080-exec-19 INFO anonymous 1366x19x1 10r3rrj 0:0:0:0:0:0:0:1 /secure/SetupDatabase.jspa [c.a.jira.plugin.JiraPluginManager] Plugin with key 'com.atlassian.jira.jira-issue-nav-components' and name 'jira-issue-nav-components' and version '8.1.21' is being added to the system. 2016-07-21 22:47:31,974 active-objects-init-JiraTenantImpl{id='system'}-0 ERROR anonymous 1366x19x1 10r3rrj 0:0:0:0:0:0:0:1 /secure/SetupDatabase.jspa [NoModule] There was an error getting a DBCP datasource. java.lang.RuntimeException: Unable to obtain a connection from the underlying connection pool at org.ofbiz.core.entity.jdbc.interceptors.connection.ConnectionTracker.trackConnection(ConnectionTracker.java:60) at org.ofbiz.core.entity.transaction.DBCPConnectionFactory.trackConnection(DBCPConnectionFactory.java:317) at org.ofbiz.core.entity.transaction.DBCPConnectionFactory.getConnection(DBCPConnectionFactory.java:81) at org.ofbiz.core.entity.ConnectionFactory.tryGenericConnectionSources(ConnectionFactory.java:69) at org.ofbiz.core.entity.transaction.JNDIFactory.getConnection(JNDIFactory.java:164) at org.ofbiz.core.entity.TransactionFactory.getConnection(TransactionFactory.java:136) at org.ofbiz.core.entity.ConnectionFactory.getConnection(ConnectionFactory.java:59) at com.atlassian.jira.ofbiz.DefaultOfBizConnectionFactory.getConnection(DefaultOfBizConnectionFactory.java:44) at com.atlassian.activeobjects.jira.JiraTenantAwareDataSourceProvider$OfBizDataSource.getConnection(JiraTenantAwareDataSourceProvider.java:103) at com.atlassian.activeobjects.internal.DataSourceProviderActiveObjectsFactory$ActiveObjectsDataSource.getConnection(DataSourceProviderActiveObjectsFactory.java:93) ... 2 filtered at java.lang.reflect.Method.invoke(Method.java:497) at net.java.ao.builder.DelegatingDisposableDataSourceHandler.delegate(DelegatingDisposableDataSourceHandler.java:37) at net.java.ao.builder.DelegatingDisposableDataSourceHandler.invoke(DelegatingDisposableDataSourceHandler.java:30) at com.sun.proxy.$Proxy2924.getConnection(Unknown Source) at net.java.ao.DatabaseProvider.getConnection(DatabaseProvider.java:855) at net.java.ao.DatabaseProvider.hasIndex(DatabaseProvider.java:1434) at net.java.ao.DatabaseProvider.renderDropIndex(DatabaseProvider.java:1419) at net.java.ao.DatabaseProvider.renderAction(DatabaseProvider.java:242) at net.java.ao.schema.SchemaGenerator$1.apply(SchemaGenerator.java:126) at net.java.ao.schema.SchemaGenerator$1.apply(SchemaGenerator.java:124) at com.google.common.collect.Iterators$8.transform(Iterators.java:799) at com.google.common.collect.TransformedIterator.next(TransformedIterator.java:48) at net.java.ao.schema.SchemaGenerator.migrate(SchemaGenerator.java:90) at net.java.ao.EntityManager.migrate(EntityManager.java:128) at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:45) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:77) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:72) at com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:25) at com.atlassian.jira.DefaultHostContextAccessor.doInTransaction(DefaultHostContextAccessor.java:34) ... 2 filtered at java.lang.reflect.Method.invoke(Method.java:497) at com.atlassian.plugin.util.ContextClassLoaderSettingInvocationHandler.invoke(ContextClassLoaderSettingInvocationHandler.java:26) at com.sun.proxy.$Proxy43.doInTransaction(Unknown Source) ... 2 filtered at java.lang.reflect.Method.invoke(Method.java:497) at com.atlassian.plugin.osgi.bridge.external.HostComponentFactoryBean$DynamicServiceInvocationHandler.invoke(HostComponentFactoryBean.java:136) at com.sun.proxy.$Proxy43.doInTransaction(Unknown Source) at com.atlassian.sal.core.transaction.HostContextTransactionTemplate.execute(HostContextTransactionTemplate.java:21) ... 2 filtered at java.lang.reflect.Method.invoke(Method.java:497) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:56) at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:60) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133) at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:70) at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:53) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.eclipse.gemini.blueprint.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:57) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133) at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207) at com.sun.proxy.$Proxy994.execute(Unknown Source) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory.create(AbstractActiveObjectsFactory.java:72) at com.atlassian.activeobjects.internal.DelegatingActiveObjectsFactory.create(DelegatingActiveObjectsFactory.java:32) at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:91) at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:86) at com.atlassian.sal.core.executor.ThreadLocalDelegateCallable.call(ThreadLocalDelegateCallable.java:42) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet successfully received from the server was 1 milliseconds ago. The last packet sent successfully to the server was 1 milliseconds ago. at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at com.mysql.jdbc.Util.handleNewInstance(Util.java:409) at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1127) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3715) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3604) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4155) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:926) at com.mysql.jdbc.MysqlIO.proceedHandshakeWithPluggableAuthentication(MysqlIO.java:1748) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1288) at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2506) at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2539) at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2321) at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:832) at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:46) ... 3 filtered at java.lang.reflect.Constructor.newInstance(Constructor.java:422) at com.mysql.jdbc.Util.handleNewInstance(Util.java:409) at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:417) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:344) at org.apache.commons.dbcp2.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:39) at org.apache.commons.dbcp2.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:256) at org.apache.commons.pool2.impl.GenericObjectPool.create(GenericObjectPool.java:861) at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:435) at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:363) at org.apache.commons.dbcp2.PoolingDataSource.getConnection(PoolingDataSource.java:134) at org.apache.commons.dbcp2.BasicDataSource.getConnection(BasicDataSource.java:1533) at org.ofbiz.core.entity.transaction.DBCPConnectionFactory$1.call(DBCPConnectionFactory.java:321) at org.ofbiz.core.entity.transaction.DBCPConnectionFactory$1.call(DBCPConnectionFactory.java:318) at org.ofbiz.core.entity.jdbc.interceptors.connection.ConnectionTracker.trackConnection(ConnectionTracker.java:54) ... 70 more Caused by: java.io.EOFException: Can not read response from server. Expected to read 4 bytes, read 0 bytes before connection was unexpectedly lost. at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:3161) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3615) {noformat} *During Data Restore* {noformat} 2016-07-21 23:04:49,877 JiraImportTaskExecutionThread-1 WARN admin 1383x701x1 10r3rrj 0:0:0:0:0:0:0:1 /secure/admin/XmlRestore.jspa [c.a.jira.index.AccumulatingResultBuilder] com.atlassian.jira.exception.DataAccessException: org.ofbiz.core.entity.GenericDataSourceException: Unable to establish a connection with the database. (Communications link failure The last packet successfully received from the server was 3 milliseconds ago. The last packet sent successfully to the server was 3 milliseconds ago.) java.lang.RuntimeException: com.atlassian.jira.exception.DataAccessException: org.ofbiz.core.entity.GenericDataSourceException: Unable to establish a connection with the database. (Communications link failure The last packet successfully received from the server was 3 milliseconds ago. The last packet sent successfully to the server was 3 milliseconds ago.) at com.atlassian.jira.index.DefaultIndex$Failure.<init>(DefaultIndex.java:101) at com.atlassian.jira.issue.index.DefaultIssueIndexer$IndexIssuesOperation.perform(DefaultIssueIndexer.java:400) at com.atlassian.jira.issue.index.DefaultIssueIndexer$IndexIssuesOperation.perform(DefaultIssueIndexer.java:369) at com.atlassian.jira.issue.index.DefaultIssueIndexer.lambda$null$202(DefaultIssueIndexer.java:308) at com.atlassian.jira.issue.index.DefaultIssueIndexer$$Lambda$1193/524039629.get(Unknown Source) at com.atlassian.jira.index.SimpleIndexingStrategy.get(SimpleIndexingStrategy.java:7) at com.atlassian.jira.index.SimpleIndexingStrategy.get(SimpleIndexingStrategy.java:5) at com.atlassian.jira.index.MultiThreadedIndexingStrategy$1.call(MultiThreadedIndexingStrategy.java:33) at com.atlassian.jira.index.MultiThreadedIndexingStrategy$1.call(MultiThreadedIndexingStrategy.java:31) at com.atlassian.jira.util.concurrent.BoundedExecutor$2.call(BoundedExecutor.java:68) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: com.atlassian.jira.exception.DataAccessException: org.ofbiz.core.entity.GenericDataSourceException: Unable to establish a connection with the database. (Communications link failure The last packet successfully received from the server was 3 milliseconds ago. The last packet sent successfully to the server was 3 milliseconds ago.) at com.atlassian.jira.ofbiz.DefaultOfBizDelegator.findByAnd(DefaultOfBizDelegator.java:94) at com.atlassian.jira.ofbiz.WrappingOfBizDelegator.findByAnd(WrappingOfBizDelegator.java:73) at com.atlassian.jira.issue.changehistory.DefaultChangeHistoryManager.getAllChangeItems(DefaultChangeHistoryManager.java:187) at com.atlassian.jira.issue.index.DefaultChangeHistoryRetriever.apply(DefaultChangeHistoryRetriever.java:24) at com.atlassian.jira.issue.index.DefaultIssueIndexer$DefaultDocumentCreationStrategy$1.apply(DefaultIssueIndexer.java:564) at com.atlassian.jira.issue.index.DefaultIssueIndexer$DefaultDocumentCreationStrategy$1.apply(DefaultIssueIndexer.java:561) at com.atlassian.jira.issue.index.DefaultIssueIndexer$DefaultDocumentCreationStrategy.get(DefaultIssueIndexer.java:554) at com.atlassian.jira.issue.index.DefaultIssueIndexer$IndexIssuesOperation.perform(DefaultIssueIndexer.java:380) ... 12 more Caused by: org.ofbiz.core.entity.GenericDataSourceException: Unable to establish a connection with the database. (Communications link failure The last packet successfully received from the server was 3 milliseconds ago. The last packet sent successfully to the server was 3 milliseconds ago.) at org.ofbiz.core.entity.jdbc.SQLProcessor.getConnection(SQLProcessor.java:399) at org.ofbiz.core.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:543) at org.ofbiz.core.entity.GenericDAO.createEntityListIterator(GenericDAO.java:960) at org.ofbiz.core.entity.GenericDAO.selectByAnd(GenericDAO.java:730) at org.ofbiz.core.entity.GenericHelperDAO.findByAnd(GenericHelperDAO.java:150) at org.ofbiz.core.entity.GenericDelegator.findByAnd(GenericDelegator.java:903) at org.ofbiz.core.entity.GenericDelegator.findByAnd(GenericDelegator.java:881) at com.atlassian.jira.ofbiz.DefaultOfBizDelegator.findByAnd(DefaultOfBizDelegator.java:92) ... 20 more Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet successfully received from the server was 3 milliseconds ago. The last packet sent successfully to the server was 3 milliseconds ago. at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at com.mysql.jdbc.Util.handleNewInstance(Util.java:409) at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1127) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3715) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3604) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:4155) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:926) at com.mysql.jdbc.MysqlIO.proceedHandshakeWithPluggableAuthentication(MysqlIO.java:1748) at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1288) at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionImpl.java:2506) at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:2539) at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2321) at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:832) at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:46) ... 2 filtered at java.lang.reflect.Constructor.newInstance(Constructor.java:422) at com.mysql.jdbc.Util.handleNewInstance(Util.java:409) at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:417) at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:344) at java.sql.DriverManager.getConnection(DriverManager.java:664) at java.sql.DriverManager.getConnection(DriverManager.java:247) at org.ofbiz.core.entity.ConnectionFactory.tryGenericConnectionSources(ConnectionFactory.java:87) at org.ofbiz.core.entity.transaction.JNDIFactory.getConnection(JNDIFactory.java:164) at org.ofbiz.core.entity.TransactionFactory.getConnection(TransactionFactory.java:136) at org.ofbiz.core.entity.ConnectionFactory.getConnection(ConnectionFactory.java:59) at org.ofbiz.core.entity.jdbc.SQLProcessor.getConnection(SQLProcessor.java:394) ... 28 more Caused by: java.io.EOFException: Can not read response from server. Expected to read 4 bytes, read 0 bytes before connection was unexpectedly lost. at com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:3161) at com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:3615) ... 51 more 2016-07-21 23:04:49,884 JiraImportTaskExecutionThread-1 ERROR admin 1383x701x1 10r3rrj 0:0:0:0:0:0:0:1 /secure/admin/XmlRestore.jspa [c.a.j.bc.dataimport.DefaultDataImportService] Error importing data: com.atlassian.jira.index.IndexingFailureException: Indexing completed with 1 errors com.atlassian.jira.index.IndexingFailureException: Indexing completed with 1 errors at com.atlassian.jira.index.AccumulatingResultBuilder$CompositeResult.await(AccumulatingResultBuilder.java:150) at com.atlassian.jira.issue.index.DefaultIndexManager.doIndexIssuesInBatchMode(DefaultIndexManager.java:986) at com.atlassian.jira.issue.index.DefaultIndexManager.doStopTheWorldReindex(DefaultIndexManager.java:961) at com.atlassian.jira.issue.index.DefaultIndexManager.lambda$reIndexAll$787(DefaultIndexManager.java:326) at com.atlassian.jira.issue.index.DefaultIndexManager$$Lambda$543/1593758938.run(Unknown Source) at com.atlassian.jira.issue.index.DefaultIndexManager.withReindexLock(DefaultIndexManager.java:359) at com.atlassian.jira.issue.index.DefaultIndexManager.reIndexAll(DefaultIndexManager.java:326) at com.atlassian.jira.issue.index.DefaultIndexManager.reIndexAll(DefaultIndexManager.java:241) at com.atlassian.jira.issue.index.DefaultIndexManager.reIndexAll(DefaultIndexManager.java:234) at com.atlassian.jira.issue.index.DefaultIndexManager.reIndexAll(DefaultIndexManager.java:230) at com.atlassian.jira.issue.index.DefaultIndexManager.activate(DefaultIndexManager.java:203) ... 3 filtered at java.lang.reflect.Method.invoke(Method.java:497) at com.atlassian.jira.config.component.SwitchingInvocationHandler.invoke(SwitchingInvocationHandler.java:22) at com.sun.proxy.$Proxy163.activate(Unknown Source) at com.atlassian.jira.util.index.CompositeIndexLifecycleManager.activate(CompositeIndexLifecycleManager.java:134) at com.atlassian.jira.util.index.CompositeIndexLifecycleManager.activate(CompositeIndexLifecycleManager.java:128) at com.atlassian.jira.bc.dataimport.DefaultDataImportService.reindex(DefaultDataImportService.java:972) at com.atlassian.jira.bc.dataimport.DefaultDataImportService.performImport(DefaultDataImportService.java:766) at com.atlassian.jira.bc.dataimport.DefaultDataImportService.doImport(DefaultDataImportService.java:324) at com.atlassian.jira.web.action.setup.DataImportAsyncCommand.call(DataImportAsyncCommand.java:60) at com.atlassian.jira.web.action.setup.DataImportAsyncCommand.call(DataImportAsyncCommand.java:28) at com.atlassian.jira.task.ImportTaskManagerImpl$TaskCallableDecorator.call(ImportTaskManagerImpl.java:157) at com.atlassian.jira.task.ImportTaskManagerImpl$TaskCallableDecorator.call(ImportTaskManagerImpl.java:133) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) {noformat} Apart from this we are also seeing Dropping Index errors during the reIndex process. See Below error {noformat} 2016-07-21 14:02:15,734 http-nio-8302-exec-10 ERROR admin 842x1499x1 gav866 0:0:0:0:0:0:0:1 /rest/zephyr/latest/execution/indexAll [c.a.p.r.c.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: bundle [com.thed.zephyr.je] com.atlassian.activeobjects.internal.ActiveObjectsInitException: bundle [com.thed.zephyr.je] at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:95) at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:86) at com.atlassian.sal.core.executor.ThreadLocalDelegateCallable.call(ThreadLocalDelegateCallable.java:42) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source) Caused by: com.atlassian.activeobjects.internal.ActiveObjectsSqlException: There was a SQL exception thrown by the Active Objects library: Database: - name:MySQL - version:5.6.29 - minor version:6 - major version:5 - name:MySQL Connector Java - version:mysql-connector-java-5.1.38 ( Revision: fe541c166cec739c74cc727c5da96c1028b4834a ) java.sql.SQLException: Cannot drop index 'index_ao_7deabf_ste1617810863': needed in a foreign key constraint at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:47) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:77) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:72) at com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:25) at com.atlassian.jira.DefaultHostContextAccessor.doInTransaction(DefaultHostContextAccessor.java:34) ... 2 filtered at java.lang.reflect.Method.invoke(Unknown Source) at com.atlassian.plugin.util.ContextClassLoaderSettingInvocationHandler.invoke(ContextClassLoaderSettingInvocationHandler.java:26) at com.sun.proxy.$Proxy136.doInTransaction(Unknown Source) {noformat}   {color:#292929}Notes{color} It seems working fine with JIRA 7.2 RC01. h3.  

    Atlassian JIRA | 4 months ago | Ignat Alexeyenko
    java.sql.SQLException: Cannot drop index 'index_ao_7deabf_ste1617810863': needed in a foreign key constraint
  2. 0

    h3. Summary Upgrading the HipChat for JIRA plugin to version 7.8.1 throws the error below: {code}2016-06-01 11:54:30,717 http-nio-8717-exec-9 ERROR admin 714x223x2 1ciuqrw 10.60.6.247 /rest/hipchat/integrations/1.0/configuration/status [c.a.p.r.c.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: bundle [com.atlassian.labs.hipchat.hipchat-for-jira-plugin] com.atlassian.activeobjects.internal.ActiveObjectsInitException: bundle [com.atlassian.labs.hipchat.hipchat-for-jira-plugin] at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:95) at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:86) at com.atlassian.sal.core.executor.ThreadLocalDelegateCallable.call(ThreadLocalDelegateCallable.java:42) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: com.atlassian.activeobjects.internal.ActiveObjectsSqlException: There was a SQL exception thrown by the Active Objects library: Database: - name:Oracle - version:Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options - minor version:2 Driver: - name:Oracle JDBC driver - version:12.1.0.1.0 java.sql.SQLException: ORA-01408: such column list already indexed at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:47) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:77) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:72) at com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:25) at com.atlassian.jira.DefaultHostContextAccessor.doInTransaction(DefaultHostContextAccessor.java:34) ... 2 filtered at java.lang.reflect.Method.invoke(Method.java:498) at com.atlassian.plugin.util.ContextClassLoaderSettingInvocationHandler.invoke(ContextClassLoaderSettingInvocationHandler.java:26) at com.sun.proxy.$Proxy340.doInTransaction(Unknown Source) ... 2 filtered at java.lang.reflect.Method.invoke(Method.java:498) at com.atlassian.plugin.osgi.bridge.external.HostComponentFactoryBean$DynamicServiceInvocationHandler.invoke(HostComponentFactoryBean.java:136) at com.sun.proxy.$Proxy340.doInTransaction(Unknown Source) at com.atlassian.sal.core.transaction.HostContextTransactionTemplate.execute(HostContextTransactionTemplate.java:21) ... 2 filtered at java.lang.reflect.Method.invoke(Method.java:498) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:56) at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:60) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133) at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:70) at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:53) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.eclipse.gemini.blueprint.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:57) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133) at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:207) at com.sun.proxy.$Proxy937.execute(Unknown Source) at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory.create(AbstractActiveObjectsFactory.java:72) at com.atlassian.activeobjects.internal.DelegatingActiveObjectsFactory.create(DelegatingActiveObjectsFactory.java:32) at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:91) ... 6 more Caused by: java.sql.SQLException: ORA-01408: such column list already indexed at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:450) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:399) at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1017) at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:655) at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:566) at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:202) at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:45) at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:933) at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1075) at oracle.jdbc.driver.OracleStatement.executeUpdateInternal(OracleStatement.java:1640) at oracle.jdbc.driver.OracleStatement.executeUpdate(OracleStatement.java:1603) at oracle.jdbc.driver.OracleStatementWrapper.executeUpdate(OracleStatementWrapper.java:308) at org.apache.commons.dbcp2.DelegatingStatement.executeUpdate(DelegatingStatement.java:234) at org.apache.commons.dbcp2.DelegatingStatement.executeUpdate(DelegatingStatement.java:234) at net.java.ao.DatabaseProvider.executeUpdate(DatabaseProvider.java:2246) at net.java.ao.DatabaseProvider.executeUpdateForAction(DatabaseProvider.java:2302) at net.java.ao.DatabaseProvider.executeUpdatesForActions(DatabaseProvider.java:2274) at net.java.ao.schema.SchemaGenerator.migrate(SchemaGenerator.java:91) at net.java.ao.EntityManager.migrate(EntityManager.java:128) at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:45) ... 44 more {code} h3. Environment JIRA 7.1.7 HipChat for JIRA Plugin 7.8.1 Oracle 11g/12g database h3. Steps to Reproduce This problem can be reproduced in a fresh JIRA install # Install JIRA 7.1.7 # Upgrade HipChat for JIRA plugin from 7.3.3 (bundled with JIRA 7.1.7) to the latest version in UPM (7.8.1) # Issue still persist after trying to uninstall and reinstall the plugin h3. Expected Results java.sql.SQLException: ORA-01408 should not be thrown after plugin upgrade h3. Actual Results java.sql.SQLException: ORA-01408 is thrown after plugin upgrade h3.Workaround N/A Disable plugin if HipChat Integration is not needed

    Atlassian JIRA | 6 months ago | Chai Tzu Hau [Atlassian]
    java.sql.SQLException: ORA-01408: such column list already indexed
  3. 0

    new install problem

    GitHub | 2 years ago | gzanthony
    org.flywaydb.core.internal.dbsupport.FlywaySqlScriptException: Error executing statement at line 39: ALTER TABLE `s_account_settings` ADD CONSTRAINT `FK_s_account_settings_2` FOREIGN KEY (`defaultThemeId`) REFERENCES `s_account_theme` (`id`) ON DELETE SET NULL ON UPDATE CASCADE
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Conflito de dependências com Wildfly 10

    Google Groups | 9 months ago | Marcelo Eugenio
    javax.persistence.PersistenceException: [PersistenceUnit: sigerhHidrometeorologiaSemar] Unable to build Hibernate SessionFactory
  6. 0

    One to Many mapping between three entities in JPA

    Stack Overflow | 6 months ago | hjain25
    org.hibernate.tool.schema.spi.CommandAcceptanceException: Unable to execute command [ alter table board add constraint FKcefyg893q4c26nvw7uus84ts3 foreign key (boardname) references board (boardid)]

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.sql.SQLException

      Cannot drop index 'index_ao_7deabf_ste1617810863': needed in a foreign key constraint

      at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate()
    2. com.atlassian.activeobjects
      AbstractActiveObjectsFactory$1.doInTransaction
      1. com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:47)
      2. com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:77)
      3. com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:72)
      3 frames
    3. com.atlassian.sal
      HostContextTransactionTemplate$1.doInTransaction
      1. com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:25)
      1 frame
    4. com.atlassian.jira
      DefaultHostContextAccessor.doInTransaction
      1. com.atlassian.jira.DefaultHostContextAccessor.doInTransaction(DefaultHostContextAccessor.java:34)
      1 frame