添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

Deleting A Space That has Page Templates causes DataIntegrityViolationException in relation to Space Templates

Closed:
Assignee:
Priority:
Resolution:
Closed
Unassigned
Medium Medium
Duplicate
Component/s
None
Affected version/s
2.9.1
Fix version/s:
None
Label/s
affects-server database/hibernate editor spaces
Reporter:
Derek MacKie
Votes:
5
Watchers:
6
Linked Issues:

Description

I have a space that has 2 space templates defined. When I try to remove the space I get the following exception page and the space does not get removed:

------------------------------

Cause

org.springframework.dao.DataIntegrityViolationException: Hibernate operation: could not delete: com.atlassian.confluence.pages.templates.PageTemplate#1409026 ; SQL []; ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates" Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".; nested exception is org.postgresql.util.PSQLException: ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates" Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".
at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.translate(SQLStateSQLExceptionTranslator.java:110)

caused by: org.postgresql.util.PSQLException: ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates" Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1592)
Stack Trace: [hide]

org.springframework.dao.DataIntegrityViolationException: Hibernate operation: could not delete: com.atlassian.confluence.pages.templates.PageTemplate#1409026 ; SQL []; ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates"
Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".; nested exception is org.postgresql.util.PSQLException: ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates"
Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".
Caused by: org.postgresql.util.PSQLException: ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates"
Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1592)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1327)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:192)
at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:451)
at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:350)
at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:304)
at com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeUpdate(NewProxyPreparedStatement.java:105)
at net.sf.hibernate.impl.NonBatchingBatcher.addToBatch(NonBatchingBatcher.java:22)
at net.sf.hibernate.persister.EntityPersister.delete(EntityPersister.java:581)
at net.sf.hibernate.impl.ScheduledDeletion.execute(ScheduledDeletion.java:29)
at net.sf.hibernate.impl.SessionImpl.execute(SessionImpl.java:2449)
at net.sf.hibernate.impl.SessionImpl.executeAll(SessionImpl.java:2435)
at net.sf.hibernate.impl.SessionImpl.execute(SessionImpl.java:2397)
at net.sf.hibernate.impl.SessionImpl.autoFlushIfRequired(SessionImpl.java:1821)
at net.sf.hibernate.impl.SessionImpl.getQueries(SessionImpl.java:1578)
at net.sf.hibernate.impl.SessionImpl.find(SessionImpl.java:1543)
at net.sf.hibernate.impl.QueryImpl.list(QueryImpl.java:49)
at org.springframework.orm.hibernate.HibernateTemplate$20.doInHibernate(HibernateTemplate.java:731)
at org.springframework.orm.hibernate.HibernateTemplate.execute(HibernateTemplate.java:370)
at org.springframework.orm.hibernate.HibernateTemplate.find(HibernateTemplate.java:717)
at org.springframework.orm.hibernate.HibernateTemplate.find(HibernateTemplate.java:700)
at bucket.search.persistence.dao.hibernate.HibernateIndexQueueEntryDao.getNewEntries(HibernateIndexQueueEntryDao.java:43)
at com.atlassian.confluence.search.lucene.queue.DatabaseIndexTaskQueue.getUnflushedEntries(DatabaseIndexTaskQueue.java:153)
at com.atlassian.confluence.search.lucene.queue.DatabaseIndexTaskQueue.flushQueue(DatabaseIndexTaskQueue.java:136)
at com.atlassian.confluence.search.lucene.DefaultConfluenceIndexManager.flushQueue(DefaultConfluenceIndexManager.java:106)
at sun.reflect.GeneratedMethodAccessor499.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy25.flushQueue(Unknown Source)
at com.atlassian.confluence.spaces.DefaultSpaceManager.removeSpace(DefaultSpaceManager.java:168)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.atlassian.spring.interceptors.SpringProfilingInterceptor.invoke(SpringProfilingInterceptor.java:20)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy30.removeSpace(Unknown Source)
at com.atlassian.confluence.spaces.actions.RemoveSpaceAction.doRemove(RemoveSpaceAction.java:17)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.opensymphony.xwork.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:302)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.interceptor.DefaultWorkflowInterceptor.intercept(DefaultWorkflowInterceptor.java:55)
at com.atlassian.confluence.core.ConfluenceWorkflowInterceptor.intercept(ConfluenceWorkflowInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.security.interceptors.CaptchaInterceptor.intercept(CaptchaInterceptor.java:46)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.util.LoggingContextInterceptor.intercept(LoggingContextInterceptor.java:48)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.core.CancellingInterceptor.intercept(CancellingInterceptor.java:23)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.security.actions.PermissionCheckInterceptor.intercept(PermissionCheckInterceptor.java:54)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.pages.actions.CommentAwareInterceptor.intercept(CommentAwareInterceptor.java:43)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.pages.actions.PageAwareInterceptor.intercept(PageAwareInterceptor.java:120)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.spaces.actions.SpaceAwareInterceptor.intercept(SpaceAwareInterceptor.java:67)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.core.actions.LastModifiedInterceptor.intercept(LastModifiedInterceptor.java:39)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.confluence.core.ConfluenceAutowireInterceptor.intercept(ConfluenceAutowireInterceptor.java:25)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.atlassian.xwork.interceptors.XWorkTransactionInterceptor.intercept(XWorkTransactionInterceptor.java:97)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:35)
at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:165)
at com.opensymphony.xwork.DefaultActionProxy.execute(DefaultActionProxy.java:115)
at com.opensymphony.webwork.dispatcher.ServletDispatcher.serviceAction(ServletDispatcher.java:229)
at com.opensymphony.webwork.dispatcher.ServletDispatcher.service(ServletDispatcher.java:199)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:118)
at com.atlassian.confluence.util.profiling.ProfilingPageFilter.parsePage(ProfilingPageFilter.java:153)
at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:54)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.confluence.jmx.JmxFilter.doFilter(JmxFilter.java:109)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.core.filters.ServletContextThreadLocalFilter.doFilter(ServletContextThreadLocalFilter.java:21)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.confluence.util.LoggingContextFilter.doFilter(LoggingContextFilter.java:49)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.confluence.util.UserThreadLocalFilter.doFilter(UserThreadLocalFilter.java:44)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.seraph.filter.SecurityFilter.doFilter(SecurityFilter.java:192)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.seraph.filter.TrustedApplicationsFilter.doFilter(TrustedApplicationsFilter.java:120)
at com.atlassian.confluence.util.AbstractBootstrapHotSwappingFilter.doFilter(AbstractBootstrapHotSwappingFilter.java:28)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.seraph.filter.BaseLoginFilter.doFilter(BaseLoginFilter.java:125)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.confluence.util.ClusterHeaderFilter.doFilter(ClusterHeaderFilter.java:35)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.johnson.filters.AbstractJohnsonFilter.doFilter(AbstractJohnsonFilter.java:72)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.springframework.orm.hibernate.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:170)
at com.atlassian.spring.filter.FlushingSpringSessionInViewFilter.doFilterInternal(FlushingSpringSessionInViewFilter.java:29)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:75)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.util.profiling.filters.ProfilingFilter.doFilter(ProfilingFilter.java:142)
at com.atlassian.core.filters.ProfilingAndErrorFilter.doFilter(ProfilingAndErrorFilter.java:27)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.confluence.core.datetime.RequestTimeThreadLocalFilter.doFilter(RequestTimeThreadLocalFilter.java:34)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.confluence.util.RequestCacheThreadLocalFilter.doFilter(RequestCacheThreadLocalFilter.java:25)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.gzipfilter.GzipFilter.doFilterInternal(GzipFilter.java:94)
at com.atlassian.gzipfilter.GzipFilter.doFilter(GzipFilter.java:64)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at com.atlassian.core.filters.AbstractEncodingFilter.doFilter(AbstractEncodingFilter.java:33)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
at java.lang.Thread.run(Thread.java:619)

Referer URL

https://wiki.globalrelay.net/spaces/removespace.action?key=TRGR
Confluence Application Information
Build Information

home: /opt/confluence/data
buildNumber: 1418
upTime: 9 days, 20 hours, 45 minutes, 25 seconds
devMode: false
version: 2.9.1
Unique ID: 0x0000011E508F850D0A140A0CA6A377AA9A9AB8D349E1C1DEC2D167EE9949B587
Server information

Application Server: Apache Tomcat/5.5.23
Servlet Version: 2.4
Database Dialect: net.sf.hibernate.dialect.PostgreSQLDialect
Database Driver Name: org.postgresql.Driver
Database Driver Version: 8.3
Database Name: PostgreSQL
Database Version: 8.3.3
Database Transaction Isolation: Read committed Database Latency: 0
Memory Information

Total Memory: 476 MB
Used Memory: 333 MB
Free Memory: 142 MB
System Information

favouriteColour: Sangria
javaRuntime: Java(TM) SE Runtime Environment
jvmVersion: 1.0
operatingSystem: Linux 2.6.18-92.1.10.el5.centos.plus
fileSystemEncoding: UTF-8
javaVm: Java HotSpot(TM) 64-Bit Server VM
javaVendor: Sun Microsystems Inc.
userTimezone: Etc/GMT
jvmImplementationVersion: 10.0-b23
appServer: Apache Tomcat
date: Friday, 19 Dec 2008
time: 18:43:49
jvmVendor: Sun Microsystems Inc.
userName: root
javaVersion: 1.6.0_07
operatingSystemArchitecture: amd64
Cluster Information

Not clustered.
Plugins

  • Add Content Menu Sections (confluence.menu.add, Version: 1.0)
  • Admin Sections (confluence.sections.admin, Version: 1.0)
  • Advanced Macros (confluence.macros.advanced, Version: 1.4.2)
  • Attachment Actions (confluence.sections.attachments, Version: 1.0)
  • Basic Macros (confluence.macros.basic, Version: 1.4)
  • Browse Menu Items (confluence.sections.browse, Version: 1.0)
  • Calendar Plugin (confluence.extra.calendar, Version: 2.7.1)
  • Chart Plugin (confluence.extra.chart, Version: 1.11)
  • Checklists Macros (com.comalatech.checklists, Version: 1.4.0)
  • Code Macro (confluence.macros.code, Version: 1.5)
  • Comment Action Sections (confluence.comment.action, Version: 1.0)
  • Confluence Atlassian Plugin Repository (confluence.repository.client, Version: 2.0.15)
  • Confluence Attachments Plugin (confluence.extra.attachments, Version: 2.10)
  • Confluence Blogging RPC Plugin (com.atlassian.confluence.plugins.xmlrpc.bloggingrpc, Version: 1.2.3)
  • Confluence Classic Theme (com.atlassian.confluence.themes.classic, Version: 2.0)
  • Confluence Contributors Plugin (com.atlassian.confluence.contributors, Version: 1.2)
  • Confluence HTML Macros (confluence.macros.html, Version: 1.4)
  • Confluence Remote API (confluence.extra.confluencerpc, Version: 2.9.1)
  • Confluence Usage Stats (com.atlassian.confluence.ext.usage, Version: 0.8)
  • Content Action Menu Sections (confluence.content.action.menu, Version: 1.0)
  • Content Buttons (confluence.sections.page.temp, Version: 1.0)
  • Core Extractors (confluence.extractors.core, Version: 1.4)
  • Core Listeners (confluence.listeners.core, Version: 1.3)
  • Core Path Converters (confluence.converters.core, Version: 1.0)
  • Core Startup and Shutdown (confluence.lifecycle.core, Version: 1)
  • Dashboard Macros (confluence.macros.dashboard, Version: 1.4.2)
  • Default Theme (com.atlassian.confluence.themes.default, Version: 1.0)
  • Dynamic Task List 2 Plugin (confluence.extra.dynamictasklist2, Version: 3.0.6)
  • Edit Profile Sections (confluence.sections.profile.edit, Version: 1.0)
  • Excel Plugin (org.swift.confluence.excel, Version: 3.5.0)
  • Form Mail NG (com.adaptavist.confluence.formMailNG, Version: 1.2.1)
  • French language pack (confluence.languages.fr_FR, Version: 1.8)
  • German language pack (confluence.languages.de_DE, Version: 1.3)
  • Global Labels Sections (confluence.sections.labels, Version: 1.0)
  • Google Maps Plugin (com.atlassian.confluence.ext.gmaps, Version: 0.5)
  • Information Macros (confluence.extra.information, Version: 1.0)
  • JIRA Macros (confluence.extra.jira, Version: 2.8.1.2)
  • Layout Macros (confluence.extra.layout, Version: 1.1)
  • Left Navigation Theme (com.atlassian.confluence.themes.leftnavigation, Version: 2.0)
  • Live Search Macros (confluence.extra.livesearch, Version: 2.8)
  • News Tabs (confluence.sections.news, Version: 1.0)
  • Office Connector plugin (com.atlassian.confluence.extra.officeconnector, Version: 1.3.6)
  • Page Operations (confluence.sections.page.operations, Version: 1.0)
  • Page Tabs (confluence.search.mappers.lucene, Version: 1.0)
  • Page Tabs (confluence.sections.page, Version: 1.0)
  • Page Tree (com.atlassian.confluence.plugins.pagetree, Version: 1.10)
  • Page View Links (confluence.sections.page.actions, Version: 1.0)
  • Profile Tabs (confluence.sections.profile, Version: 1.0)
  • Search Web Interface (confluence.sections.search.view, Version: 1.0)
  • Social Bookmarking Plugin (com.atlassian.confluence.plugins.socialbookmarking, Version: 1.2.2)
  • Space Actions Sections (confluence.sections.space.actions, Version: 1.0)
  • Space Admin Sections (confluence.sections.space.admin, Version: 1.0)
  • Space Advanced Sections (confluence.sections.space.advanced, Version: 1.0)
  • Space Browse Sections (confluence.sections.space.browse, Version: 1.0)
  • Space Item Tabs (confluence.sections.space, Version: 1.0)
  • Space Labels Sections (confluence.sections.space.labels, Version: 1.0)
  • Space Pages Sections (confluence.sections.space.pages, Version: 1.0)
  • Survey Macros (com.nearinfinity.confluence.survey-plugin, Version: 1.1.6)
  • System Web Resources (confluence.web.resources, Version: 1.0)
  • Table of Contents Plugin (org.randombits.confluence.toc, Version: 2.4.8)
  • Tabular Metadata (confluence.extra.masterdetail, Version: 2.7)
  • TinyMCE Editor Plugin (com.atlassian.confluence.extra.tinymceplugin, Version: 3.0-rc2)
  • Top and Left Navigation Theme (at.hansen.confluence.themes.topandleftnavigation, Version: 1.1)
  • Top and Left Navigation Theme - Alternative Version (at.hansen.confluence.themes.topandleftnavigationITD, Version: 1.0)
  • User Lister (confluence.extra.userlister, Version: 2.4.1)
  • User Menu Sections (confluence.user.menu, Version: 1.0)
  • View Profile Web Interface (confluence.sections.profile.view, Version: 1.0)
  • Visio Plugin (org.swift.confluence.visio, Version: 1.0)
  • WebDAV Plugin (confluence.extra.webdav, Version: 1.1)
  • Wiki Renderer Components (confluence.renderer.components, Version: 1.0)
  • Word Plugin (org.swift.confluence.word, Version: 3.0.1)
  • Request
    Information

    https://wiki.globalrelay.net/500page.jsp
    /500page.jsp
    Context Path
    Servlet Path
    /500page.jsp
    Query String
    key=TRGR

    Headers (Limited subset)

    wiki.globalrelay.net
    user-agent
    Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.1) Gecko/2008070208 Firefox/3.0.1
    keep-alive
    connection
    keep-alive

    Attributes

    javax.servlet.forward.request_uri
    /spaces/doremovespace.action
    javax.servlet.forward.context_path
    javax.servlet.forward.servlet_path
    /spaces/doremovespace.action
    javax.servlet.forward.path_info
    /500page.jsp
    javax.servlet.forward.query_string
    key=TRGR
    os_securityfilter_already_filtered
    javax.servlet.jsp.jspException
    org.springframework.dao.DataIntegrityViolationException: Hibernate operation: could not delete: com.atlassian.confluence.pages.templates.PageTemplate#1409026 ; SQL []; ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates" Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".; nested exception is org.postgresql.util.PSQLException: ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates" Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".
    atlassian.core.seraph.original.url
    /spaces/doremovespace.action?key=TRGR
    javax.servlet.error.status_code
    javax.servlet.error.servlet_name
    action
    javax.servlet.request.key_size
    _ sitemesh _using_stream
    false
    com.atlassian.gzipfilter.GzipFilter_already_filtered
    loginfilter.already.filtered
    com.atlassian.johnson.filters.JohnsonFilter_already_filtered
    Confluence-Request-Time
    1229712225070
    javax.servlet.request.ssl_session
    494be350f50b8059357a86344181e59cbfdbbed36dccc1bee33339ca1bfa3c4a
    javax.servlet.error.message
    webwork.valueStack
    com.opensymphony.xwork.util.OgnlValueStack@27e61926
    sessioninview.FILTERED
    _ sitemesh _filterapplied
    javax.servlet.request.cipher_suite
    TLS_DHE_RSA_WITH_AES_128_CBC_SHA
    javax.servlet.error.exception
    org.springframework.dao.DataIntegrityViolationException: Hibernate operation: could not delete: com.atlassian.confluence.pages.templates.PageTemplate#1409026 ; SQL []; ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates" Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".; nested exception is org.postgresql.util.PSQLException: ERROR: update or delete on table "pagetemplates" violates foreign key constraint "fkbc7ce96a17d4a070" on table "pagetemplates" Detail: Key (templateid)=(1409026) is still referenced from table "pagetemplates".
    javax.servlet.error.request_uri
    /spaces/doremovespace.action

    Parameters (Limited subset)

    confirm

    Confluence User

    anonymous

    ----------------------------

    When I manually delete the templates and then remove the space I get no exception and the space is removed.

    Comments

    Andrew Lynch
    Added 12/21/08 11:31 PM

    Hi Derek,

    Thanks for the report.

    Regards,
    Andrew Lynch

    Igor Minar
    Added 1/20/09 11:49 PM

    was hit by this one too:

    -- url: /spaces/doremovespace.action | userName: igorminar
    org.springframework.dao.DataIntegrityViolationException: Hibernate operation: could not delete: [com.atlassian.confluence.pages.template
    s.PageTemplate#51544073]; SQL []; Cannot delete or update a parent row: a foreign key constraint fails (`wikis/PAGETEMPLATES`, CONSTRAIN
    T `FKBC7CE96A17D4A070` FOREIGN KEY (`PREVVER`) REFERENCES `PAGETEMPLATES` (`TEMPLATEID`)); nested exception is com.mysql.jdbc.exceptions
    .jdbc4.MySQLIntegrityConstraintViolationException: Cannot delete or update a parent row: a foreign key constraint fails (`wikis/PAGETEMP
    LATES`, CONSTRAINT `FKBC7CE96A17D4A070` FOREIGN KEY (`PREVVER`) REFERENCES `PAGETEMPLATES` (`TEMPLATEID`))
    Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Cannot delete or update a parent row: a foreign k
    ey constraint fails (`wikis/PAGETEMPLATES`, CONSTRAINT `FKBC7CE96A17D4A070` FOREIGN KEY (`PREVVER`) REFERENCES `PAGETEMPLATES` (`TEMPLAT
    EID`))
    
    Stephen Day
    Added 2/16/09 4:51 PM

    I had a similar problem and was only able to remove the space by first deleting all its templates.

    org.springframework.dao.DataIntegrityViolationException: Hibernate operation: could not delete: [com.atlassian.confluence.pages.templates.PageTemplate#1605634]; SQL []; ORA-02292: integrity constraint (MRLWIKI.FKBC7CE96A17D4A070) violated - child record found ; nested exception is java.sql.SQLIntegrityConstraintViolationException: ORA-02292: integrity constraint (MRLWIKI.FKBC7CE96A17D4A070) violated - child record found
        at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.translate(SQLStateSQLExceptionTranslator.java:110)
    caused by: java.sql.SQLIntegrityConstraintViolationException: ORA-02292: integrity constraint (MRLWIKI.FKBC7CE96A17D4A070) violated - child record found
        at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:85)
    Stack Trace:[hide]
    org.springframework.dao.DataIntegrityViolationException: Hibernate operation: could not delete: [com.atlassian.confluence.pages.templates.PageTemplate#1605634]; SQL []; ORA-02292: integrity constraint (MRLWIKI.FKBC7CE96A17D4A070) violated - child record found
    ; nested exception is java.sql.SQLIntegrityConstraintViolationException: ORA-02292: integrity constraint (MRLWIKI.FKBC7CE96A17D4A070) violated - child record found
    Caused by: java.sql.SQLIntegrityConstraintViolationException: ORA-02292: integrity constraint (MRLWIKI.FKBC7CE96A17D4A070) violated - child record found
    
    Arie Murdianto
    Added 4/23/09 1:27 PM

    Hi,

    I have tried to reproduce this problem locally but I could not reproduce it. Here is the steps that I went through:

  • Install Confluence with postgreSQL 8.2 as the DB
  • Create space
  • Create space's template and create global's template
  • Create 2 pages and associate each page with space's template and global's template
  • Delete the space.
  • Below is my system information:

    System Date	Thursday, 23 Apr 2009
    System Time	09:27:24
    System Favourite Colour	Sangria
    Java Version	1.5.0_07
    Java Vendor	Sun Microsystems Inc.
    JVM Version	1.0
    JVM Vendor	Sun Microsystems Inc.
    JVM Implementation Version	1.5.0_07-b03
    Java Runtime	Java(TM) 2 Runtime Environment, Standard Edition
    Java VM	Java HotSpot(TM) Client VM
    User Name	arie
    User Timezone	Canada/Eastern
    Operating System	Windows XP 5.1
    OS Architecture	x86
    Filesystem Encoding	Cp1252
    Java VM Memory Statistics
    Total Memory	508 MB
    Free Memory	388 MB
    Used Memory	119 MB
    Memory Graph 	
    [Used Memory (23 %)] 	[Free Memory (77 %)]
    	  77 % Free
    Runtime Information
    Database Dialect	net.sf.hibernate.dialect.PostgreSQLDialect
    Database Connection URL	jdbc:postgresql://localhost:5432/confluence
    Database Driver Name	org.postgresql.Driver
    Database Driver Version	8.3
    Database Connection Transaction Isolation	Read committed
    Database name	PostgreSQL
    Database version	8.2.3
    Database Latency	0 ms
    Application Server	Apache Tomcat/5.5.23
    Servlet Version	2.4
    Server Base Url	http://localhost:8291
    Confluence Home	E:/kerjaan/home/confluence291postgre
    Uptime	9 minutes, 45 seconds
    Confluence Version	2.9.1
    Build Number	1418
    
    Derek MacKie
    Added 4/23/09 4:03 PM

    I see the versions of postgres are different from what you tested with and what we are using. I'm not sure if hat would be the cause or not but its something that I noticed was different. Also I don't know if there could be any interaction issues with the plugins we had installed and the templates implementation.

    Arie Murdianto
    Added 5/7/09 12:45 PM

    Hi Derek,

    I have tried to use 8.3.3 version also and I could not reproduce the problem using the same steps as my first comment

    System Date	Thursday, 07 May 2009
    System Time	08:43:12
    System Favourite Colour	Sangria
    Java Version	1.5.0_07
    Java Vendor	Sun Microsystems Inc.
    JVM Version	1.0
    JVM Vendor	Sun Microsystems Inc.
    JVM Implementation Version	1.5.0_07-b03
    Java Runtime	Java(TM) 2 Runtime Environment, Standard Edition
    Java VM	Java HotSpot(TM) Client VM
    User Name	arie
    User Timezone	Canada/Eastern
    Operating System	Windows XP 5.1
    OS Architecture	x86
    Filesystem Encoding	Cp1252
    Java VM Memory Statistics
    Total Memory	508 MB
    Free Memory	386 MB
    Used Memory	121 MB
    Memory Graph 	
    [Used Memory (24 %)] 	[Free Memory (76 %)]
    	  76 % Free
    Runtime Information
    Database Dialect	net.sf.hibernate.dialect.PostgreSQLDialect
    Database Connection URL	jdbc:postgresql://localhost:5433/confluence291
    Database Driver Name	org.postgresql.Driver
    Database Driver Version	8.3
    Database Connection Transaction Isolation	Read committed
    Database name	PostgreSQL
    Database version	8.3.3
    Database Latency	0 ms
    Application Server	Apache Tomcat/5.5.23
    Servlet Version	2.4
    Server Base Url	http://localhost:8291
    Confluence Home	E:/kerjaan/home/confluence291postgre833
    Uptime	4 minutes, 52 seconds
    Confluence Version	2.9.1
    Build Number	1418
    
    Derek MacKie
    Added 5/7/09 5:33 PM

    Strange. I can't reproduce this issue anymore either but we have not changed anything as far as I am aware. I know it was reproducible when it first happened though. May as well close it since we can't reproduce it now.

    Eric Law [Atlassian]
    Added 5/11/09 4:30 AM

    Another similar reported issue - https://support.atlassian.com/browse/CSP-31883

    jens
    Added 10/9/09 7:12 AM

    Since we are not able to reproduce the issue and customers reported that it is no longer a problem, I am going to close this ticket.

    Please raise a support request if you should run into this problem again.

    Jeremy Largman
    Added 11/13/09 8:41 PM

    I'd like to reopen this issue despite the fact that we can't replicate it, as it continues to affect customer instances. Would it be possible to change the order of the deletion:

    from DefaultSpaceManager:

    pageManager.removeAllPages(space); pageManager.removeAllBlogPosts(space); mailContentManager.removeAllMail(space); templateManager.removeAllPageTemplates(space); spacePermissionManager.removeAllPermissions(space); templateManager.removeAllPageTemplates(space); pageManager.removeAllPages(space);