Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 62660 invoked from network); 22 Apr 2009 23:07:12 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 22 Apr 2009 23:07:12 -0000 Received: (qmail 88416 invoked by uid 500); 22 Apr 2009 23:07:11 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 88335 invoked by uid 500); 22 Apr 2009 23:07:11 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 88327 invoked by uid 99); 22 Apr 2009 23:07:11 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 22 Apr 2009 23:07:11 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 22 Apr 2009 23:07:09 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 53887234C051 for ; Wed, 22 Apr 2009 16:06:48 -0700 (PDT) Message-ID: <266500144.1240441608341.JavaMail.jira@brutus> Date: Wed, 22 Apr 2009 16:06:48 -0700 (PDT) From: "Kathey Marsden (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Updated: (DERBY-4182) SYSCS_UTIL.SYSCS_INPLACE_COMPRESS_TABLE does not reclaim space lost from an aborted insert In-Reply-To: <2108138851.1240441608303.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-4182?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Kathey Marsden updated DERBY-4182: ---------------------------------- Attachment: TestInPlaceCompressWithPKViolation.java > SYSCS_UTIL.SYSCS_INPLACE_COMPRESS_TABLE does not reclaim space lost from an aborted insert > ------------------------------------------------------------------------------------------- > > Key: DERBY-4182 > URL: https://issues.apache.org/jira/browse/DERBY-4182 > Project: Derby > Issue Type: Bug > Components: Tools > Affects Versions: 10.4.2.0, 10.5.1.1, 10.6.0.0 > Reporter: Kathey Marsden > Attachments: TestInPlaceCompressWithPKViolation.java > > > Because of DERBY-691 an aborted insert (for example due to a constraint violation or rollback) can cause space to not be reclaimed. SYSCS_UTIL.SYSCS_INPLACE_COMPRESS_TABLE should reclaim this space. Even if it cannot return the space to the operating system it should show up as free pages after calling the procedure, but it currently does not. SYSCS_UTIL.SYSCS_COMPRESS_TABLE works properly and returns the space to the operating system. > See the attached program TestInPlaceCompressWithPKViolation.java to reproduce this problem. The program attempts 10 3MB inserts. One is successful and 9 fail. SpaceTable queries show only 18 pages are marked as free after inplace compress and none returned to the os. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > The statement was aborted because it would have caused a duplicate key value in a unique or primary key constraint or un > ique index identified by 'SQL090422155557650' defined on 'TAB'. > *****spaceTable before SYSCS_UTIL.SYSCS_INPLACE_COMPRESS_TABLE('APP','TAB',1,1,1) > CONGLOMERATENAME > |ISIND&|NUMALLOCATEDPAGES |NUMFREEPAGES |NUMUNFILLEDPAGES |PAGESIZE |ESTIMSPACESAVING > ------------------------------------------------------------------------------------------------------------------------ > --------------------------------------------------------------------------------------------------------------- > TAB > |0 |931 |0 |2 |32768 |0 > *****spaceTable after SYSCS_UTIL.SYSCS_INPLACE_COMPRESS_TABLE('APP','TAB',1,1,1) > CONGLOMERATENAME > |ISIND&|NUMALLOCATEDPAGES |NUMFREEPAGES |NUMUNFILLEDPAGES |PAGESIZE |ESTIMSPACESAVING > ------------------------------------------------------------------------------------------------------------------------ > --------------------------------------------------------------------------------------------------------------- > TAB > |0 |913 |18 |1 |32768 |589824 > *****spaceTable after SYSCS_UTIL.SYSCS_COMPRESS_TABLE('APP','TAB',1) > CONGLOMERATENAME > |ISIND&|NUMALLOCATEDPAGES |NUMFREEPAGES |NUMUNFILLEDPAGES |PAGESIZE |ESTIMSPACESAVING > ------------------------------------------------------------------------------------------------------------------------ > --------------------------------------------------------------------------------------------------------------- > TAB > |0 |95 |0 |1 |32768 |0 -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.