On Mon, Jun 30, 2014 at 8:24 AM, Alessandro Pisa
<alessandro.p...@gmail.com> wrote:
> On 30 June 2014 12:43, Jim Fulton <j...@zope.com> wrote:
>> On Mon, Jun 30, 2014 at 3:30 AM, Alessandro Pisa
>> <alessandro.p...@gmail.com> wrote:
>>> Hello everybody :)
>>
>> As the comment suggests, if you continued packing, the new file
>> would be as large as the old one, because no records would be
>> removed.  This is likely either because a) you've already packed to
>> that pack time before.
>> b) None of the objects written up to the pack time
>> have been written after the pack time and this there are no old records
>> to be removed.
>
> Strange, I am making a 0 day pack.

Perhaps you had a clock problem and the recent records have
timestamps in the future.

> How can I convince zeopack of that?

You pass a pack time of now. :)

> Is it possible to remove this "previous pack memory" and act as it
> would be the first pack?

Theoretically.

> Would this be effective?

At causing dangling references, possibly.

> Any suggestion for reducing the Data.fs size?

I suggest using the file-store iterator to look at the transaction
timestamps.

Something like:

  from ZODB.FileStorage import FileIterator

  it = FileIterator('s.fs')

  last = None
  for t in it:
      if last is not None:
          if t.tid <= last:
              print 'wtf', repr(t.tid)
          last = t.tid


If you've said to pack to the present and you
aren't writing to the database, then I would expect it to stop at
the end of the file, unless you have a problem with your
transaction ids.

Jim

-- 
Jim Fulton
http://www.linkedin.com/in/jimfulton
_______________________________________________
For more information about ZODB, see http://zodb.org/

ZODB-Dev mailing list  -  ZODB-Dev@zope.org
https://mail.zope.org/mailman/listinfo/zodb-dev

Reply via email to