com.atlassian.activeobjects.spi.ActiveObjectsImportExportException: There was an error during import/export with <unknown plugin> (table AO_ED979B_EVENTPROPERTY):

Atlassian JIRA | Vincent Chin [Atlassian] | 6 months ago
  1. 0

    h2.Summary Migration from Cloud to Server sometimes fails due to the column constraints on {{AO_ED979B_EVENTPROPERTY}}. This is a JIRA Mobile table. {noformat} [c.a.j.bc.dataimport.DefaultDataImportService] Error during ActiveObjects restore com.atlassian.activeobjects.spi.ActiveObjectsImportExportException: There was an error during import/export with <unknown plugin> (table AO_ED979B_EVENTPROPERTY): at com.atlassian.activeobjects.backup.ImportExportErrorServiceImpl.newImportExportSqlException(ImportExportErrorServiceImpl.java:26) at com.atlassian.dbexporter.importer.DataImporter$BatchInserter.flush(DataImporter.java:429) at com.atlassian.dbexporter.importer.DataImporter$BatchInserter.executePS(DataImporter.java:412) at com.atlassian.dbexporter.importer.DataImporter$BaseInserter.execute(DataImporter.java:378) at com.atlassian.dbexporter.importer.DataImporter.importTable(DataImporter.java:114) at com.atlassian.dbexporter.importer.DataImporter.access$000(DataImporter.java:41) at com.atlassian.dbexporter.importer.DataImporter$1.call(DataImporter.java:71) at com.atlassian.dbexporter.importer.DataImporter$1.call(DataImporter.java:64) at com.atlassian.dbexporter.jdbc.JdbcUtils.withConnection(JdbcUtils.java:28) at com.atlassian.dbexporter.importer.DataImporter.doImportNode(DataImporter.java:64) at com.atlassian.dbexporter.importer.AbstractImporter.importNode(AbstractImporter.java:44) at com.atlassian.dbexporter.DbImporter.importData(DbImporter.java:69) at com.atlassian.activeobjects.backup.ActiveObjectsBackup.restore(ActiveObjectsBackup.java:151) at com.atlassian.jira.bc.dataimport.DefaultDataImportService.restoreActiveObjects(DefaultDataImportService.java:555) at com.atlassian.jira.bc.dataimport.DefaultDataImportService.performImport(DefaultDataImportService.java:710) at com.atlassian.jira.bc.dataimport.DefaultDataImportService.doImport(DefaultDataImportService.java:320) 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) Caused by: java.sql.BatchUpdateException: ORA-12899: value too large for column "JIRADBUSER"."AO_ED979B_EVENTPROPERTY"."VALUE" (actual: 258, maximum: 255) at oracle.jdbc.driver.OraclePreparedStatement.executeBatch(OraclePreparedStatement.java:11190) at oracle.jdbc.driver.OracleStatementWrapper.executeBatch(OracleStatementWrapper.java:244) at org.apache.commons.dbcp2.DelegatingStatement.executeBatch(DelegatingStatement.java:345) at org.apache.commons.dbcp2.DelegatingStatement.executeBatch(DelegatingStatement.java:345) ... 24 more {noformat} h2.Details on the issue {noformat} jira=> \d "AO_ED979B_EVENTPROPERTY" Table "public.AO_ED979B_EVENTPROPERTY" Column | Type | Modifiers ----------+------------------------+------------------------------------------------------------------------ EVENT_ID | integer | not null ID | integer | not null default nextval('"AO_ED979B_EVENTPROPERTY_ID_seq"'::regclass) KEY | character varying(255) | not null VALUE | character varying(255) | Indexes: "AO_ED979B_EVENTPROPERTY_pkey" PRIMARY KEY, btree ("ID") "index_ao_ed979b_eve1511666309" btree ("EVENT_ID") {noformat} The default constraints for the {{value}} column for the {{AO_ED979B_EVENTPROPERTY}} is 255. Migration from Cloud to Server fails because there are data that exceeds 255 character. h2.Steps to Replicate This happens because the table has a limit of 255 characters and when Oracle imports the data it thinks that it has more characters. This happens cause the column is not configured correctly when imported. To reproduce this just create comments in issues of more than 255 characters and then try to export the data to an Oracle DB h2.Workaround *Solution 1* Before importing the data you can change the size of the column in the DB to more than 255 characters. *Solution 2* 1) Before importing (make sure that the Database is empty) edit the activeobjects.xml 2) find the table and change the precision to more than 255. This is how it looks: {code} <table name="AO_ED979B_EVENTPROPERTY"> <column name="EVENT_ID" primaryKey="false" autoIncrement="false" sqlType="4" precision="10"/> <column name="ID" primaryKey="true" autoIncrement="true" sqlType="4" precision="10"/> <column name="KEY" primaryKey="false" autoIncrement="false" sqlType="12" precision="255"/> <column name="VALUE" primaryKey="false" autoIncrement="false" sqlType="12" precision="255"/> </table> {code} You should change this line to something like this: {code} <column name="VALUE" primaryKey="false" autoIncrement="false" sqlType="12" precision="512"/> {code}

    Atlassian JIRA | 6 months ago | Vincent Chin [Atlassian]
    com.atlassian.activeobjects.spi.ActiveObjectsImportExportException: There was an error during import/export with <unknown plugin> (table AO_ED979B_EVENTPROPERTY):
  2. 0

    We noticed that our portal (version 4.4.0-snapshot) no longer was aggregating portal events. Looking in the portal-event.log the exception stack trace shown below indicated that a search term the portal was trying to aggregate was too long for the column I solved the problem (I hope) by increasing the size of the search_term column in table UP_SEARCH_REQ_AGGR form 255 to 500. After the change the portal started to aggregate events again. ERROR [uP-TaskExec-891-aggregateRawEvents] o.j.p.e.a.PortalEventProcessingManagerImpl 2016-10-06 08:55:03,496 - aggregateRawEvents failed org.springframework.orm.hibernate3.HibernateJdbcException: JDBC exception on Hibernate data access: SQLException for SQL [insert into UP_SEARCH_REQ_AGGR (AGGR_GROUP_ID, DATE_DIMENSION_ID, DURATION, AGGR_INTERVAL, TIME_DIMENSION_ID, STATS_COMPLETE, SEARCH_COUNT, SEARCH_TERM, ID) values (?, ?, ?, ?, ?, ?, ?, ?, ?)]; SQL state [72000]; error code [12899]; could not execute batch; nested exception is org.hibernate.exception.GenericJDBCException: could not execute batch at org.springframework.orm.hibernate3.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:651) ~[spring-orm-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.orm.jpa.vendor.HibernateJpaDialect.translateExceptionIfPossible(HibernateJpaDialect.java:106) ~[spring-orm-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.orm.jpa.JpaTransactionManager.doCommit(JpaTransactionManager.java:517) ~[spring-orm-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:755) ~[spring-tx-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:724) ~[spring-tx-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:148) ~[spring-tx-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.jasig.portal.events.aggr.PortalRawEventsAggregatorImpl.doAggregateRawEvents(PortalRawEventsAggregatorImpl.java:217) ~[classes/:4.4.0-SNAPSHOT] at sun.reflect.GeneratedMethodAccessor1001.invoke(Unknown Source) ~[na:na] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_91] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_91] at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:183) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:150) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:96) ~[spring-tx-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:260) ~[spring-tx-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:94) ~[spring-tx-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204) ~[spring-aop-3.2.9.RELEASE.jar:3.2.9.RELEASE] at com.sun.proxy.$Proxy226.doAggregateRawEvents(Unknown Source) ~[na:na] at org.jasig.portal.events.aggr.PortalEventProcessingManagerImpl$3.apply(PortalEventProcessingManagerImpl.java:204) ~[classes/:4.4.0-SNAPSHOT] at org.jasig.portal.events.aggr.PortalEventProcessingManagerImpl$3.apply(PortalEventProcessingManagerImpl.java:201) ~[classes/:4.4.0-SNAPSHOT] at org.jasig.portal.concurrency.locking.ClusterLockServiceImpl.doInTryLock(ClusterLockServiceImpl.java:200) ~[classes/:4.4.0-SNAPSHOT] at org.jasig.portal.events.aggr.PortalEventProcessingManagerImpl.aggregateRawEvents(PortalEventProcessingManagerImpl.java:199) ~[classes/:4.4.0-SNAPSHOT] at sun.reflect.GeneratedMethodAccessor835.invoke(Unknown Source) ~[na:na] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_91] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_91] at org.springframework.scheduling.support.ScheduledMethodRunnable.run(ScheduledMethodRunnable.java:64) [spring-context-3.2.9.RELEASE.jar:3.2.9.RELEASE] at org.jasig.portal.utils.threading.ThreadNamingRunnable.run(ThreadNamingRunnable.java:41) [classes/:4.4.0-SNAPSHOT] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_91] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_91] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_91] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_91] at java.lang.Thread.run(Thread.java:745) [na:1.8.0_91] Caused by: org.hibernate.exception.GenericJDBCException: could not execute batch at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:54) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:124) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:122) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.jdbc.batch.internal.BatchingBatch.doExecuteBatch(BatchingBatch.java:101) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl.execute(AbstractBatchImpl.java:161) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.getBatch(JdbcCoordinatorImpl.java:196) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3057) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:3521) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.action.internal.EntityInsertAction.execute(EntityInsertAction.java:88) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.spi.ActionQueue.execute(ActionQueue.java:395) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:387) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:303) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:349) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:56) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.internal.SessionImpl.flush(SessionImpl.java:1195) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:404) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.transaction.internal.jdbc.JdbcTransaction.beforeTransactionCommit(JdbcTransaction.java:101) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.engine.transaction.spi.AbstractTransactionImpl.commit(AbstractTransactionImpl.java:175) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] at org.hibernate.ejb.TransactionImpl.commit(TransactionImpl.java:75) ~[hibernate-entitymanager-4.2.19.Final.jar:4.2.19.Final] at org.springframework.orm.jpa.JpaTransactionManager.doCommit(JpaTransactionManager.java:513) ~[spring-orm-3.2.9.RELEASE.jar:3.2.9.RELEASE] ... 30 common frames omitted Caused by: java.sql.BatchUpdateException: ORA-12899: value too large for column "UPORTAL43"."UP_SEARCH_REQ_AGGR"."SEARCH_TERM" (actual: 264, maximum: 255) at oracle.jdbc.driver.OraclePreparedStatement.executeBatch(OraclePreparedStatement.java:11190) ~[ojdbc7-12.1.0.1.jar:12.1.0.1.0] at oracle.jdbc.driver.OracleStatementWrapper.executeBatch(OracleStatementWrapper.java:244) ~[ojdbc7-12.1.0.1.jar:12.1.0.1.0] at sun.reflect.GeneratedMethodAccessor589.invoke(Unknown Source) ~[na:na] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_91] at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_91] at org.apache.tomcat.jdbc.pool.interceptor.AbstractQueryReport$StatementProxy.invoke(AbstractQueryReport.java:235) ~[tomcat-jdbc-7.0.37.jar:na] at com.sun.proxy.$Proxy49.executeBatch(Unknown Source) ~[na:na] at org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:113) ~[hibernate-core-4.2.19.Final.jar:4.2.19.Final] ... 47 common frames omitted

    Apereo Issues | 2 months ago | Bruce Phillips
    org.springframework.orm.hibernate3.HibernateJdbcException: JDBC exception on Hibernate data access: SQLException for SQL [insert into UP_SEARCH_REQ_AGGR (AGGR_GROUP_ID, DATE_DIMENSION_ID, DURATION, AGGR_INTERVAL, TIME_DIMENSION_ID, STATS_COMPLETE, SEARCH_COUNT, SEARCH_TERM, ID) values (?, ?, ?, ?, ?, ?, ?, ?, ?)]; SQL state [72000]; error code [12899]; could not execute batch; nested exception is org.hibernate.exception.GenericJDBCException: could not execute batch
  3. 0

    Select for nowait update

    Stack Overflow | 2 years ago | user1274028
    java.sql.BatchUpdateException: invalid batch command: invalid SELECT batch command 0
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Error during Sonar runner execution 5.0. "After migrating 3.7.4 to 5.0"

    Stack Overflow | 1 year ago | Gaston Paolo
    org.apache.ibatis.executor.BatchExecutorException: org.sonar.api.database.model.MeasureMapper.insert (batch index #1) failed. Cause: java.sql.BatchUpdateException: ORA-00001: restricci├│n ├║nica (SONAR5.SYS_C0078055) violada
  6. 0

    Hibernate throwing unique constriant exception

    Stack Overflow | 2 years ago | Amit
    org.hibernate.exception.ConstraintViolationException: could not insert: [com.bu.app.bha.dataaccess.dataobject.managereference.OccupationClassificationDO]

  1. r1chjames 10 times, last 6 months ago
12 unregistered visitors
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.BatchUpdateException

    ORA-12899: value too large for column "JIRADBUSER"."AO_ED979B_EVENTPROPERTY"."VALUE" (actual: 258, maximum: 255)

    at oracle.jdbc.driver.OraclePreparedStatement.executeBatch()
  2. Oracle jdbc
    OracleStatementWrapper.executeBatch
    1. oracle.jdbc.driver.OraclePreparedStatement.executeBatch(OraclePreparedStatement.java:11190)
    2. oracle.jdbc.driver.OracleStatementWrapper.executeBatch(OracleStatementWrapper.java:244)
    2 frames
  3. Apache Commons DBCP
    DelegatingStatement.executeBatch
    1. org.apache.commons.dbcp2.DelegatingStatement.executeBatch(DelegatingStatement.java:345)
    2. org.apache.commons.dbcp2.DelegatingStatement.executeBatch(DelegatingStatement.java:345)
    2 frames
  4. com.atlassian.dbexporter
    DbImporter.importData
    1. com.atlassian.dbexporter.importer.DataImporter$BatchInserter.executePS(DataImporter.java:412)
    2. com.atlassian.dbexporter.importer.DataImporter$BaseInserter.execute(DataImporter.java:378)
    3. com.atlassian.dbexporter.importer.DataImporter.importTable(DataImporter.java:114)
    4. com.atlassian.dbexporter.importer.DataImporter.access$000(DataImporter.java:41)
    5. com.atlassian.dbexporter.importer.DataImporter$1.call(DataImporter.java:71)
    6. com.atlassian.dbexporter.importer.DataImporter$1.call(DataImporter.java:64)
    7. com.atlassian.dbexporter.jdbc.JdbcUtils.withConnection(JdbcUtils.java:28)
    8. com.atlassian.dbexporter.importer.DataImporter.doImportNode(DataImporter.java:64)
    9. com.atlassian.dbexporter.importer.AbstractImporter.importNode(AbstractImporter.java:44)
    10. com.atlassian.dbexporter.DbImporter.importData(DbImporter.java:69)
    10 frames
  5. com.atlassian.activeobjects
    ActiveObjectsBackup.restore
    1. com.atlassian.activeobjects.backup.ActiveObjectsBackup.restore(ActiveObjectsBackup.java:151)
    1 frame
  6. com.atlassian.jira
    ImportTaskManagerImpl$TaskCallableDecorator.call
    1. com.atlassian.jira.bc.dataimport.DefaultDataImportService.restoreActiveObjects(DefaultDataImportService.java:555)
    2. com.atlassian.jira.bc.dataimport.DefaultDataImportService.performImport(DefaultDataImportService.java:710)
    3. com.atlassian.jira.bc.dataimport.DefaultDataImportService.doImport(DefaultDataImportService.java:320)
    4. com.atlassian.jira.web.action.setup.DataImportAsyncCommand.call(DataImportAsyncCommand.java:60)
    5. com.atlassian.jira.web.action.setup.DataImportAsyncCommand.call(DataImportAsyncCommand.java:28)
    6. com.atlassian.jira.task.ImportTaskManagerImpl$TaskCallableDecorator.call(ImportTaskManagerImpl.java:157)
    7. com.atlassian.jira.task.ImportTaskManagerImpl$TaskCallableDecorator.call(ImportTaskManagerImpl.java:133)
    7 frames
  7. Java RT
    Thread.run
    1. java.util.concurrent.FutureTask.run(FutureTask.java:266)
    2. java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    3. java.util.concurrent.FutureTask.run(FutureTask.java:266)
    4. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    5. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    6. java.lang.Thread.run(Thread.java:745)
    6 frames