-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Low
-
None
-
Affects Version/s: 6.6.13, 6.15.8, 7.13.10, 7.19.5, 8.5.14, 9.2.6
-
Component/s: Content - Page
-
61
-
Severity 3 - Minor
-
5
Issue Summary
Moving a page to a new space fails with no warnings to the user in the UI.
The URL might even show the moved=true statement, but the page remains in the same old space, under the same parent page.
Checking the atlassian-confluence.log, the following entries show the move page action failed and was rolled back on the Hibernate level.
2019-07-03 02:12:49,177 ERROR [http-nio-8101-exec-82 url:/pages/movepage.action username:xxxxxx] [atlassian.confluence.event.ConfluenceEventDispatcher] run There was an exception thrown trying to dispatch event [com.atlassian.confluence.event.events.content.page.PageMoveEvent@3a567e65[theMover=ConfluenceUserImpl{name='xxxxxx', key=yyyyyyyyyy},oldSpace=Space{key='OLDSPACEKEY'},oldParentPage=page: OLD_PARENT_PAGE (111111111),oldPosition=3,movedBecauseOfParent=false,movedPageList=[page: MOVED_PAGE (1111111)],page=page: MOVED_PAGE (1111111),suppressNotifications=false,timestamp=1562091168004]] from the invoker [com.atlassian.confluence.event.ConfluenceListenerHandlersConfiguration$TimingListenerHandler$1$1@15eb0a15]
-- referer: https://confluence/pages/viewpage.action?pageId=111111 | url: /pages/movepage.action | traceId: 4cb0685c76abd0f3 | userName: xxxxxx | action: movepage
java.lang.RuntimeException: Listener: com.atlassian.confluence.links.RelatedContentRefactoringListener event: com.atlassian.confluence.event.events.content.page.PageMoveEvent
at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:50)
at com.atlassian.confluence.event.ConfluenceListenerHandlersConfiguration$TimingListenerHandler$1$1.invoke(ConfluenceListenerHandlersConfiguration.java:69)
at com.atlassian.confluence.event.ConfluenceEventDispatcher$VCacheRequestContextRunnableFactory$1.lambda$run$0(ConfluenceEventDispatcher.java:93)
at com.atlassian.confluence.vcache.VCacheRequestContextOperations.lambda$doInRequestContext$0(VCacheRequestContextOperations.java:50)
at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContextInternal(VCacheRequestContextManager.java:87)
at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContext(VCacheRequestContextManager.java:71)
at com.atlassian.confluence.vcache.VCacheRequestContextOperations.doInRequestContext(VCacheRequestContextOperations.java:49)
at com.atlassian.confluence.event.ConfluenceEventDispatcher$VCacheRequestContextRunnableFactory$1.run(ConfluenceEventDispatcher.java:93)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:457)
at com.atlassian.event.internal.AsynchronousAbleEventDispatcher.dispatch(AsynchronousAbleEventDispatcher.java:88)
at com.atlassian.event.internal.EventPublisherImpl.invokeListeners(EventPublisherImpl.java:203)
at com.atlassian.event.internal.EventPublisherImpl.publish(EventPublisherImpl.java:114)
at com.atlassian.confluence.event.TimingEventPublisher.publish(TimingEventPublisher.java:64)
at com.atlassian.confluence.pages.DefaultPageManager.publishPageMoveEvents(DefaultPageManager.java:1680)
at com.atlassian.confluence.pages.DefaultPageManager.movePageToTopLevel(DefaultPageManager.java:884)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:16)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.confluence.util.profiling.ConfluenceMonitoringMethodInterceptor.invoke(ConfluenceMonitoringMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy105.movePageToTopLevel(Unknown Source)
at com.atlassian.confluence.content.service.page.MovePageToTopOfSpaceCommand.executeInternal(MovePageToTopOfSpaceCommand.java:44)
at com.atlassian.confluence.core.service.AbstractServiceCommand$ServiceCommandState$2.execute(AbstractServiceCommand.java:148)
at com.atlassian.confluence.core.service.AbstractServiceCommand.execute(AbstractServiceCommand.java:60)
at sun.reflect.GeneratedMethodAccessor3816.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy2837.execute(Unknown Source)
at com.atlassian.confluence.core.service.CommandActionHelper.execute(CommandActionHelper.java:32)
at com.atlassian.confluence.pages.actions.AbstractCommandAction.execute(AbstractCommandAction.java:28)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:168)
(...)
Caused by: java.lang.NullPointerException
at java.util.Calendar.setTime(Calendar.java:1770)
at com.atlassian.confluence.pages.BlogPost.getPostingCalendarDate(BlogPost.java:134)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$ContentEntityResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:276)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$ContentEntityResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:243)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$AttachmentResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:342)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$AttachmentResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:313)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor.createOutgoingLink(XhtmlOutgoingLinksExtractor.java:152)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor.extract(XhtmlOutgoingLinksExtractor.java:120)
at com.atlassian.confluence.links.DefaultLinkManager.updateOutgoingLinks(DefaultLinkManager.java:228)
at sun.reflect.GeneratedMethodAccessor1540.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:16)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.confluence.util.profiling.ConfluenceMonitoringMethodInterceptor.invoke(ConfluenceMonitoringMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy53.updateOutgoingLinks(Unknown Source)
at com.atlassian.confluence.core.DefaultContentEntityManager.saveContentEntity(DefaultContentEntityManager.java:173)
at com.atlassian.confluence.pages.DefaultPageManager.saveContentEntity(DefaultPageManager.java:1399)
at sun.reflect.GeneratedMethodAccessor1342.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:16)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.confluence.util.profiling.ConfluenceMonitoringMethodInterceptor.invoke(ConfluenceMonitoringMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy105.saveContentEntity(Unknown Source)
at com.atlassian.confluence.links.DefaultRelatedContentRefactorer.persistBodyModificationToContent(DefaultRelatedContentRefactorer.java:255)
at com.atlassian.confluence.links.DefaultRelatedContentRefactorer.updateReferrers(DefaultRelatedContentRefactorer.java:110)
at com.atlassian.confluence.links.DefaultRelatedContentRefactorer.updateReferrersForMovingPage(DefaultRelatedContentRefactorer.java:39)
at com.atlassian.confluence.links.RelatedContentRefactoringListener.handleEvent(RelatedContentRefactoringListener.java:38)
at sun.reflect.GeneratedMethodAccessor4427.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:40)
... 427 more
2019-07-03 02:12:51,163 WARN [http-nio-8101-exec-82 url:/pages/movepage.action username:xxxxx] [confluence.impl.hibernate.ConfluenceHibernateTransactionManager] doRollback Performing rollback. Transactions:
->[null]: PROPAGATION_REQUIRED,ISOLATION_DEFAULT (Session #1627106864)
-- referer: https://confluence/pages/viewpage.action?pageId=11111111 | url: /pages/movepage.action | traceId: 4cb0685c76abd0f3 | userName: xxxxx | action: movepage
Moving the page to a new parent within the same space works fine.
Environment
The issue occurred on an environment with the following characteristics:
- Confluence Server 6.6.13
- Oracle Database
- The page to be moved has an (internal) incoming link from a Blog post
Steps to Reproduce
- Create a Sample Page within a Source Space.
- Create a Blog post within another Space.
- In the Blog post, add an outgoing link to the Sample Page.
- Move the Sample Page from the Source Space to the Target Space.
Expected Results
The page is properly moved to the Target Space.
Actual Results
The page is not moved and no error nor warnings are shown to the user.
The below exception is thrown in the atlassian-confluence.log file:
2019-07-03 02:12:49,177 ERROR [http-nio-8101-exec-82 url:/pages/movepage.action username:xxxxxx] [atlassian.confluence.event.ConfluenceEventDispatcher] run There was an exception thrown trying to dispatch event [com.atlassian.confluence.event.events.content.page.PageMoveEvent@3a567e65[theMover=ConfluenceUserImpl{name='xxxxxx', key=yyyyyyyyyy},oldSpace=Space{key='OLDSPACEKEY'},oldParentPage=page: OLD_PARENT_PAGE (111111111),oldPosition=3,movedBecauseOfParent=false,movedPageList=[page: MOVED_PAGE (1111111)],page=page: MOVED_PAGE (1111111),suppressNotifications=false,timestamp=1562091168004]] from the invoker [com.atlassian.confluence.event.ConfluenceListenerHandlersConfiguration$TimingListenerHandler$1$1@15eb0a15]
-- referer: https://confluence/pages/viewpage.action?pageId=111111 | url: /pages/movepage.action | traceId: 4cb0685c76abd0f3 | userName: xxxxxx | action: movepage
java.lang.RuntimeException: Listener: com.atlassian.confluence.links.RelatedContentRefactoringListener event: com.atlassian.confluence.event.events.content.page.PageMoveEvent
at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:50)
at com.atlassian.confluence.event.ConfluenceListenerHandlersConfiguration$TimingListenerHandler$1$1.invoke(ConfluenceListenerHandlersConfiguration.java:69)
at com.atlassian.confluence.event.ConfluenceEventDispatcher$VCacheRequestContextRunnableFactory$1.lambda$run$0(ConfluenceEventDispatcher.java:93)
at com.atlassian.confluence.vcache.VCacheRequestContextOperations.lambda$doInRequestContext$0(VCacheRequestContextOperations.java:50)
at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContextInternal(VCacheRequestContextManager.java:87)
at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContext(VCacheRequestContextManager.java:71)
at com.atlassian.confluence.vcache.VCacheRequestContextOperations.doInRequestContext(VCacheRequestContextOperations.java:49)
at com.atlassian.confluence.event.ConfluenceEventDispatcher$VCacheRequestContextRunnableFactory$1.run(ConfluenceEventDispatcher.java:93)
at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:457)
at com.atlassian.event.internal.AsynchronousAbleEventDispatcher.dispatch(AsynchronousAbleEventDispatcher.java:88)
at com.atlassian.event.internal.EventPublisherImpl.invokeListeners(EventPublisherImpl.java:203)
at com.atlassian.event.internal.EventPublisherImpl.publish(EventPublisherImpl.java:114)
at com.atlassian.confluence.event.TimingEventPublisher.publish(TimingEventPublisher.java:64)
at com.atlassian.confluence.pages.DefaultPageManager.publishPageMoveEvents(DefaultPageManager.java:1680)
at com.atlassian.confluence.pages.DefaultPageManager.movePageToTopLevel(DefaultPageManager.java:884)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:16)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.confluence.util.profiling.ConfluenceMonitoringMethodInterceptor.invoke(ConfluenceMonitoringMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy105.movePageToTopLevel(Unknown Source)
at com.atlassian.confluence.content.service.page.MovePageToTopOfSpaceCommand.executeInternal(MovePageToTopOfSpaceCommand.java:44)
at com.atlassian.confluence.core.service.AbstractServiceCommand$ServiceCommandState$2.execute(AbstractServiceCommand.java:148)
at com.atlassian.confluence.core.service.AbstractServiceCommand.execute(AbstractServiceCommand.java:60)
at sun.reflect.GeneratedMethodAccessor3816.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy2837.execute(Unknown Source)
at com.atlassian.confluence.core.service.CommandActionHelper.execute(CommandActionHelper.java:32)
at com.atlassian.confluence.pages.actions.AbstractCommandAction.execute(AbstractCommandAction.java:28)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:168)
(...)
Caused by: java.lang.NullPointerException
at java.util.Calendar.setTime(Calendar.java:1770)
at com.atlassian.confluence.pages.BlogPost.getPostingCalendarDate(BlogPost.java:134)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$ContentEntityResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:276)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$ContentEntityResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:243)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$AttachmentResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:342)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor$AttachmentResourceHandler.getDestination(XhtmlOutgoingLinksExtractor.java:313)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor.createOutgoingLink(XhtmlOutgoingLinksExtractor.java:152)
at com.atlassian.confluence.content.render.xhtml.links.XhtmlOutgoingLinksExtractor.extract(XhtmlOutgoingLinksExtractor.java:120)
at com.atlassian.confluence.links.DefaultLinkManager.updateOutgoingLinks(DefaultLinkManager.java:228)
at sun.reflect.GeneratedMethodAccessor1540.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:16)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.confluence.util.profiling.ConfluenceMonitoringMethodInterceptor.invoke(ConfluenceMonitoringMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy53.updateOutgoingLinks(Unknown Source)
at com.atlassian.confluence.core.DefaultContentEntityManager.saveContentEntity(DefaultContentEntityManager.java:173)
at com.atlassian.confluence.pages.DefaultPageManager.saveContentEntity(DefaultPageManager.java:1399)
at sun.reflect.GeneratedMethodAccessor1342.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157)
at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99)
at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:16)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at com.atlassian.confluence.util.profiling.ConfluenceMonitoringMethodInterceptor.invoke(ConfluenceMonitoringMethodInterceptor.java:34)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy105.saveContentEntity(Unknown Source)
at com.atlassian.confluence.links.DefaultRelatedContentRefactorer.persistBodyModificationToContent(DefaultRelatedContentRefactorer.java:255)
at com.atlassian.confluence.links.DefaultRelatedContentRefactorer.updateReferrers(DefaultRelatedContentRefactorer.java:110)
at com.atlassian.confluence.links.DefaultRelatedContentRefactorer.updateReferrersForMovingPage(DefaultRelatedContentRefactorer.java:39)
at com.atlassian.confluence.links.RelatedContentRefactoringListener.handleEvent(RelatedContentRefactoringListener.java:38)
at sun.reflect.GeneratedMethodAccessor4427.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at com.atlassian.event.internal.SingleParameterMethodListenerInvoker.invoke(SingleParameterMethodListenerInvoker.java:40)
... 427 more
2019-07-03 02:12:51,163 WARN [http-nio-8101-exec-82 url:/pages/movepage.action username:xxxxx] [confluence.impl.hibernate.ConfluenceHibernateTransactionManager] doRollback Performing rollback. Transactions:
->[null]: PROPAGATION_REQUIRED,ISOLATION_DEFAULT (Session #1627106864)
-- referer: https://confluence/pages/viewpage.action?pageId=11111111 | url: /pages/movepage.action | traceId: 4cb0685c76abd0f3 | userName: xxxxx | action: movepage
Notes
So far, the issue could not be reproduced on another environment so we are unsure on what the triggers are.
They will be included to the bug report when identified.
The issue occurs on the refactoring task to update the contents of pages with outgoing links to the moved page.
The important marker in the exception stack trace is the following, indicating the issue is related with an outgoing link to the moved page in a Blog Post:
Caused by: java.lang.NullPointerException at java.util.Calendar.setTime(Calendar.java:1770) at com.atlassian.confluence.pages.BlogPost.getPostingCalendarDate(BlogPost.java:134)
There is a problem when the blogpost is created. Creating blogpost (using the REST API or the editor), two entries are created on the database, one with CREATIONDATE and other with the CREATIONDATE empty:
If the BLOGPOST is edited after, all the entries will have the CREATIONDATE set as expected. So, the problem only happens if a never-edited blogpost is linked to a page and the page is moved also this can affected the pages update in some cases.
Workaround
The workaround could be to temporarily remove the outgoing link to the page moved in the Blog Post, move the page and then re-add the link.
You can check the Page Information to get the incoming links.
- Run this query on the database:
select * from CONTENT where CONTENTTYPE = 'BLOGPOST' and CREATIONDATE is null;
- Add a valid CREATIONDATE for all the entries without a creationdate. A query like the following would work:
UPDATE CONTENT SET creationdate = '1980-11-03 00:00:00' WHERE CONTENTTYPE = 'BLOGPOST' AND CREATIONDATE is null;