[Xapian-tickets] [Xapian] #491: calling replace_document() twice doubles the size of the database

Xapian nobody at xapian.org
Tue Jun 29 01:52:42 BST 2010


#491: calling replace_document() twice doubles the size of the database
--------------------+-------------------------------------------------------
 Reporter:  maad    |        Owner:  olly   
     Type:  defect  |       Status:  closed 
 Priority:  normal  |    Milestone:         
Component:  Other   |      Version:         
 Severity:  major   |   Resolution:  invalid
 Keywords:          |    Blockedby:         
 Platform:  All     |     Blocking:         
--------------------+-------------------------------------------------------
Changes (by olly):

  * status:  new => closed
  * resolution:  => invalid


Comment:

 This isn't a bug, just how the Btree files work.

 Modifications are made by copying modified blocks so that we can rollback
 change.  So after the second operation, each table has 2 blocks in, one
 unused.  Subsequent repetitions reuse the spare block.  If you want to
 eliminate the unused space, xapian-compact will make a copy of the table
 with unused space minimised.

-- 
Ticket URL: <http://trac.xapian.org/ticket/491#comment:1>
Xapian <http://xapian.org/>
Xapian



More information about the Xapian-tickets mailing list