Project Specific Select Field: Can't render project custom specific field when upgrade from version 1.0.0 to 2.4.1!

zhen zhang
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 21, 2015

Hi ALL,

I am testing the Project Specific Select Field plugin 2.4.1 in JIRA 6.4.1, it does not work properly when upgrade from v1.0.0 to v2.4.1.  Version 1.0.0 works fine for JIRA 5.1.3, but when we upgrade JIRA to 6.4.1, and upgrade this plugin to v2.4.1, it throws errors when I click Project Specific tab in the Project administrator page. the error and exception in JIRA log are the following, can anyone help me on this issue? thanks in advance!

2015_05_22_14_14_38_JIRA_Development_SSDF_JIRA_DTC.png

Exception in JIRA logs:


2015-05-21 18:34:23,012 http-bio-8080-exec-25 ERROR jarinee.uetrongchit 1114x835x2 g1gznv 10.42.62.228 /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_10904 [common.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: bundle [jira.plugin.projectspecificselectfield.jpssf]
com.atlassian.activeobjects.internal.ActiveObjectsInitException: bundle [jira.plugin.projectspecificselectfield.jpssf]
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:105)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:92)
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
- major version:11
Driver:
- name:Oracle JDBC driver
- version:11.2.0.2.0

java.sql.SQLException: ORA-01439: column to be modified must be empty to change datatype

at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:54)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:91)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:85)
at com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:25)
at com.atlassian.jira.DefaultHostContextAccessor.doInTransaction(DefaultHostContextAccessor.java:34)
at sun.reflect.GeneratedMethodAccessor156.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.atlassian.plugin.osgi.hostcomponents.impl.DefaultComponentRegistrar$ContextClassLoaderSettingInvocationHandler.invoke(DefaultComponentRegistrar.java:134)
at com.sun.proxy.$Proxy123.doInTransaction(Unknown Source)
at sun.reflect.GeneratedMethodAccessor156.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.atlassian.plugin.osgi.bridge.external.HostComponentFactoryBean$DynamicServiceInvocationHandler.invoke(HostComponentFactoryBean.java:154)
at com.sun.proxy.$Proxy123.doInTransaction(Unknown Source)
at com.atlassian.sal.core.transaction.HostContextTransactionTemplate.execute(HostContextTransactionTemplate.java:21)
at sun.reflect.GeneratedMethodAccessor161.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:58)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:62)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:56)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:39)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:59)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy1465.execute(Unknown Source)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory.create(AbstractActiveObjectsFactory.java:84)
at com.atlassian.activeobjects.internal.DelegatingActiveObjectsFactory.create(DelegatingActiveObjectsFactory.java:40)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:99)
... 6 more
Caused by: java.sql.SQLException: ORA-01439: column to be modified must be empty to change datatype

at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:440)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396)
at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:837)
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:445)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:191)
at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:523)
at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:193)
at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:999)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1315)
at oracle.jdbc.driver.OracleStatement.executeUpdateInternal(OracleStatement.java:1822)
at oracle.jdbc.driver.OracleStatement.executeUpdate(OracleStatement.java:1787)
at oracle.jdbc.driver.OracleStatementWrapper.executeUpdate(OracleStatementWrapper.java:280)
at org.apache.commons.dbcp.DelegatingStatement.executeUpdate(DelegatingStatement.java:228)
at org.apache.commons.dbcp.DelegatingStatement.executeUpdate(DelegatingStatement.java:228)
at net.java.ao.DatabaseProvider.executeUpdate(DatabaseProvider.java:2361)
at net.java.ao.DatabaseProvider.executeUpdateForAction(DatabaseProvider.java:2431)
at net.java.ao.DatabaseProvider.executeUpdatesForActions(DatabaseProvider.java:2394)
at net.java.ao.schema.SchemaGenerator.migrate(SchemaGenerator.java:98)
at net.java.ao.EntityManager.migrate(EntityManager.java:130)
at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:50)
... 44 more
2015-05-21 18:34:23,009 http-bio-8080-exec-16 ERROR jarinee.uetrongchit 1114x837x4 g1gznv 10.42.62.228 /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_11200 [common.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: bundle [jira.plugin.projectspecificselectfield.jpssf]
com.atlassian.activeobjects.internal.ActiveObjectsInitException: bundle [jira.plugin.projectspecificselectfield.jpssf]
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:105)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:92)
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
- major version:11
Driver:
- name:Oracle JDBC driver
- version:11.2.0.2.0

java.sql.SQLException: ORA-01439: column to be modified must be empty to change datatype

at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:54)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:91)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:85)
at com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:25)
at com.atlassian.jira.DefaultHostContextAccessor.doInTransaction(DefaultHostContextAccessor.java:34)
at sun.reflect.GeneratedMethodAccessor156.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.atlassian.plugin.osgi.hostcomponents.impl.DefaultComponentRegistrar$ContextClassLoaderSettingInvocationHandler.invoke(DefaultComponentRegistrar.java:134)
at com.sun.proxy.$Proxy123.doInTransaction(Unknown Source)
at sun.reflect.GeneratedMethodAccessor156.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.atlassian.plugin.osgi.bridge.external.HostComponentFactoryBean$DynamicServiceInvocationHandler.invoke(HostComponentFactoryBean.java:154)
at com.sun.proxy.$Proxy123.doInTransaction(Unknown Source)
at com.atlassian.sal.core.transaction.HostContextTransactionTemplate.execute(HostContextTransactionTemplate.java:21)
at sun.reflect.GeneratedMethodAccessor161.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:58)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:62)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:56)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:39)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:59)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy1465.execute(Unknown Source)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory.create(AbstractActiveObjectsFactory.java:84)
at com.atlassian.activeobjects.internal.DelegatingActiveObjectsFactory.create(DelegatingActiveObjectsFactory.java:40)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:99)
... 6 more
Caused by: java.sql.SQLException: ORA-01439: column to be modified must be empty to change datatype

at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:440)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396)
at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:837)
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:445)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:191)
at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:523)
at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:193)
at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:999)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1315)
at oracle.jdbc.driver.OracleStatement.executeUpdateInternal(OracleStatement.java:1822)
at oracle.jdbc.driver.OracleStatement.executeUpdate(OracleStatement.java:1787)
at oracle.jdbc.driver.OracleStatementWrapper.executeUpdate(OracleStatementWrapper.java:280)
at org.apache.commons.dbcp.DelegatingStatement.executeUpdate(DelegatingStatement.java:228)
at org.apache.commons.dbcp.DelegatingStatement.executeUpdate(DelegatingStatement.java:228)
at net.java.ao.DatabaseProvider.executeUpdate(DatabaseProvider.java:2361)
at net.java.ao.DatabaseProvider.executeUpdateForAction(DatabaseProvider.java:2431)
at net.java.ao.DatabaseProvider.executeUpdatesForActions(DatabaseProvider.java:2394)
at net.java.ao.schema.SchemaGenerator.migrate(SchemaGenerator.java:98)
at net.java.ao.EntityManager.migrate(EntityManager.java:130)
at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:50)
... 44 more
2015-05-21 18:34:23,248 http-bio-8080-exec-9 WARN [thomsonreuters.jira.filter.SAFELoginFilter] ###URI: /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_11201
2015-05-21 18:34:23,248 http-bio-8080-exec-20 WARN [thomsonreuters.jira.filter.SAFELoginFilter] ###URI: /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_13609
2015-05-21 18:34:23,249 http-bio-8080-exec-2 WARN [thomsonreuters.jira.filter.SAFELoginFilter] ###URI: /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_12101
2015-05-21 18:34:23,251 http-bio-8080-exec-13 WARN [thomsonreuters.jira.filter.SAFELoginFilter] ###URI: /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_11000
2015-05-21 18:34:23,251 http-bio-8080-exec-14 WARN [thomsonreuters.jira.filter.SAFELoginFilter] ###URI: /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_10901
2015-05-21 18:34:23,254 http-bio-8080-exec-20 ERROR jarinee.uetrongchit 1114x841x2 g1gznv 10.42.62.228 /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_13609 [common.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: bundle [jira.plugin.projectspecificselectfield.jpssf]
com.atlassian.activeobjects.internal.ActiveObjectsInitException: bundle [jira.plugin.projectspecificselectfield.jpssf]
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:105)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:92)
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
- major version:11
Driver:
- name:Oracle JDBC driver
- version:11.2.0.2.0

java.sql.SQLException: ORA-01439: column to be modified must be empty to change datatype

at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:54)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:91)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory$1.doInTransaction(AbstractActiveObjectsFactory.java:85)
at com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:25)
at com.atlassian.jira.DefaultHostContextAccessor.doInTransaction(DefaultHostContextAccessor.java:34)
at sun.reflect.GeneratedMethodAccessor156.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.atlassian.plugin.osgi.hostcomponents.impl.DefaultComponentRegistrar$ContextClassLoaderSettingInvocationHandler.invoke(DefaultComponentRegistrar.java:134)
at com.sun.proxy.$Proxy123.doInTransaction(Unknown Source)
at sun.reflect.GeneratedMethodAccessor156.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.atlassian.plugin.osgi.bridge.external.HostComponentFactoryBean$DynamicServiceInvocationHandler.invoke(HostComponentFactoryBean.java:154)
at com.sun.proxy.$Proxy123.doInTransaction(Unknown Source)
at com.atlassian.sal.core.transaction.HostContextTransactionTemplate.execute(HostContextTransactionTemplate.java:21)
at sun.reflect.GeneratedMethodAccessor161.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:58)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:62)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:56)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:39)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:59)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy1465.execute(Unknown Source)
at com.atlassian.activeobjects.internal.AbstractActiveObjectsFactory.create(AbstractActiveObjectsFactory.java:84)
at com.atlassian.activeobjects.internal.DelegatingActiveObjectsFactory.create(DelegatingActiveObjectsFactory.java:40)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:99)
... 6 more
Caused by: java.sql.SQLException: ORA-01439: column to be modified must be empty to change datatype

at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:440)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396)
at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:837)
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:445)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:191)
at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:523)
at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:193)
at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:999)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1315)
at oracle.jdbc.driver.OracleStatement.executeUpdateInternal(OracleStatement.java:1822)
at oracle.jdbc.driver.OracleStatement.executeUpdate(OracleStatement.java:1787)
at oracle.jdbc.driver.OracleStatementWrapper.executeUpdate(OracleStatementWrapper.java:280)
at org.apache.commons.dbcp.DelegatingStatement.executeUpdate(DelegatingStatement.java:228)
at org.apache.commons.dbcp.DelegatingStatement.executeUpdate(DelegatingStatement.java:228)
at net.java.ao.DatabaseProvider.executeUpdate(DatabaseProvider.java:2361)
at net.java.ao.DatabaseProvider.executeUpdateForAction(DatabaseProvider.java:2431)
at net.java.ao.DatabaseProvider.executeUpdatesForActions(DatabaseProvider.java:2394)
at net.java.ao.schema.SchemaGenerator.migrate(SchemaGenerator.java:98)
at net.java.ao.EntityManager.migrate(EntityManager.java:130)
at com.atlassian.activeobjects.internal.EntityManagedActiveObjects.migrate(EntityManagedActiveObjects.java:50)
... 44 more
2015-05-21 18:34:23,256 http-bio-8080-exec-13 ERROR jarinee.uetrongchit 1114x843x4 g1gznv 10.42.62.228 /rest/projectspecificselectfield/1.0/statistics/SANDDEFAULT/customfield_11000 [common.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: bundle [jira.plugin.projectspecificselectfield.jpssf]
com.atlassian.activeobjects.internal.ActiveObjectsInitException: bundle [jira.plugin.projectspecificselectfield.jpssf]
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:105)
at com.atlassian.activeobjects.osgi.TenantAwareActiveObjects$1$1$1.call(TenantAwareActiveObjects.java:92)
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
- major version:11
Driver:
- name:Oracle JDBC driver
- version:11.2.0.2.0

 

6 answers

1 accepted

0 votes
Answer accepted
Holger Schimanski
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2015

Please follow the steps below. That is a manual procedure to migrate column CUSTOM_FIELD_ID of AO_9661E7_SELECT_OPTION from varchar2 to number(20). The UPDATE statement from the wiki is included in Step 3.

Attention: Please check the following steps on a test setup with a copy from your production database first! Do not execute this directly on the production database to prevent mistakes.

Step 1: Rename current varchar2 CUSTOM_FIELD_ID column to CUSTOM_FIELD_ID_VARCHAR2

ALTER TABLE AO_9661E7_SELECT_OPTION 
RENAME COLUMN CUSTOM_FIELD_ID TO CUSTOM_FIELD_ID_VARCHAR2;

Step 2: Create new column of type number(20) called CUSTOM_FIELD_ID

ALTER TABLE AO_9661E7_SELECT_OPTION 
ADD (CUSTOM_FIELD_ID NUMBER(20));

Step 3: Set values for new column based on varchar2 column

UPDATE AO_9661E7_SELECT_OPTION 
SET CUSTOM_FIELD_ID = TO_NUMBER(REPLACE(CUSTOM_FIELD_ID_VARCHAR2 ,'customfield_'));

 

References

 

zhen zhang
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 25, 2015

Hi @Holger Schimanski , After changing the CUSTOM_FIELD_ID type from varchar2 to number(20) based on the steps you suggested above, the project specific tab can display normally and no error thrown in the JIRA log for this plugin. Really appreciate for your help, thanks again!

Holger Schimanski
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 27, 2015

Great news! Because you are coming from a previous version, please notice that there are two new custom field types and the one you have used so far Project Specific Select Field (simple) is the one with limited capabilities compared with the two new ones Project Specific Select Field and Project Specific Mulit Select Field. When using the new custom field types, project admins can also edit and reorder option values. With Project Specific Select Field (simple) option values are allways ordered alphabetically and cannot be edited. The new ones require a little different set up, please have a look at the documentation.

Cheers, Holger

0 votes
Holger Schimanski
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 27, 2015

The update is normally done, when JIRA starts the plugin and then sees a mismatch between the AO object definition and the corresponding table. But it looks like we have to help here.

Column CUSTOM_FIELD_ID needs to get same type as PROJECT_ID. In my database (HSQLDB) both are BIGINT.

What is PROJECT_ID in your case?

 

 

0 votes
Holger Schimanski
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 26, 2015

I guess you are coming from version 0.9? Can you connect to your Oracle database and have a look at the table AO_9661E7_SELECT_OPTION. There is a column CUSTOM_FIELD_ID, which I guess is of type char or varchar?

When migrating to newer versions of the plugin, this column needs to be migrated to integer. Please have a look at the section "Updating from Version 0.9" in the documentation (last section at the bottom). There is a SQL UPDATE statement mentioned, which needs to be executed in order to remove some text parts of the custom field ID stored here.

Then when updating the plugin, JIRA is normally able to change the type of the column from text to integer. But looking at "ORA-01439: column to be modified must be empty to change datatype" this seems not to be possible with Oracle as a database. Before we go more into details here, please confirm type of column CUSTOM_FIELD_ID and execute the UPDATE statement. Then you should give it a new try by restarting JIRA.

Best regards,
Holger

0 votes
zhen zhang
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2015

Hi @Holger Schimanski,

In my database(Orace), the type of PROJECT_ID is NUMBER(20).

0 votes
zhen zhang
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2015

Hi @Holger Schimanski,

I noticed one sentence " In table AO_9661E7_SELECT_OPTION the column CUSTOM_FIELD_ID will be changed from String to Integer during update" in the documentation. it seems the correct type for CUSTOM_FIELD_ID  should be integer. but I found the actual type for this column still varchar2 when after implementing the operations mentioned in the section "Updating from Version 0.9". Could you please help to confirm the table AO_9661E7_SELECT_OPTION  is only used by project specific plugin? If so I can try to manually change the column type from varchar2 to integer. Thanks in advance!

 

Notes:

I installed the project specific select field plugin manually when JIRA upgrade to version 6.4.1, so the column type can't be automatically changed.

0 votes
zhen zhang
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2015

Hi @Holger Schimanski, 

Really appreciate for your time. Our production JIRA DB is Oracle, the column CUSTOM_FIELD_ID type is varchar2(255). I followed the section "Updating from Version 0.9" in the documentation, and use the below update query sql to update the column. After restarting JIRA, the custom field still can't be render in the project tab and throw the same exceptions in the JIRA log as above. Do you have any idea how to handle below exceptions? thanks!

value.UPDATE AO_9661E7_SELECT_OPTION SET CUSTOM_FIELD_ID = substr(CUSTOM_FIELD_ID, 13);


 

Suggest an answer

Log in or Sign up to answer