1. 25 Sep, 2010 13 commits
  2. 24 Sep, 2010 5 commits
    • Rusty Russell's avatar
      tdb: implement tdb_summary. · 1c7178a0
      Rusty Russell authored
      Including pretty graphs!
      1c7178a0
    • Rusty Russell's avatar
      tally: implement tally_total() · e0fd4d11
      Rusty Russell authored
      Not as trivial as you might think, with overflow and underflow.
      e0fd4d11
    • Rusty Russell's avatar
      tdb: TDB_INCOMPATIBLE_HASH, to allow safe changing of default hash. · 95bf6d3f
      Rusty Russell authored
      This flag to tdb_open/tdb_open_ex effects creation of a new database:
      1) Uses the Jenkins lookup3 hash instead of the old gdbm hash if none is
         specified,
      2) Places a non-zero field in header->rwlocks, so older versions of TDB will
         refuse to open it.
      
      This means that the caller (ie Samba) can set this flag to safely
      change the hash function.  Versions of TDB from this one on will either
      use the correct hash or refuse to open (if a different hash is specified).
      Older TDB versions will see the nonzero rwlocks field and refuse to open 
      it under any conditions.
      95bf6d3f
    • Rusty Russell's avatar
      tdb: automatically identify Jenkins hash tdbs · 16f4f30f
      Rusty Russell authored
      If the caller to tdb_open_ex() doesn't specify a hash, and tdb_old_hash
      doesn't match, try tdb_jenkins_hash.
      
      This makes life simpler, especially with the upcoming TDB_INCOMPATIBLE_HASH
      flag.
      16f4f30f
    • Rusty Russell's avatar
      tdb: add Bob Jenkins lookup3 hash as helper hash. · d117f992
      Rusty Russell authored
      This is a better hash than the default: shipping it with tdb makes it easy
      for callers to use it as the hash by passing it to tdb_open_ex().
      d117f992
  3. 23 Sep, 2010 2 commits
  4. 14 Sep, 2010 6 commits
  5. 13 Sep, 2010 7 commits
  6. 12 Sep, 2010 1 commit
  7. 11 Sep, 2010 3 commits
    • Rusty Russell's avatar
      tdb: unify logging code in test dir. · 655ef777
      Rusty Russell authored
      655ef777
    • Rusty Russell's avatar
      tdb: make check more robust against recovery failures. · 73598053
      Rusty Russell authored
      We can end up with dead areas when we die during transaction commit;
      tdb_check() fails on such a (valid) database.
      
      This is particularly noticable now we no longer truncate on recovery;
      if the recovery area was at the end of the file we used to remove it
      that way.
      73598053
    • Rusty Russell's avatar
      tdb: rewrite external agent for testing. · a153d09b
      Rusty Russell authored
      For locking and transaction tests, we need an external process to probe the
      tdb.  This code was a mess, and unreliable (occasional failures).  Rewrite
      it so that instead of blocking and using SIGALRM, we mug fcntl and force
      non-blocking locks.  We use a special return to day "I couldn't because
      the lock wasn't available".
      
      I also made the operations clearer and more orthogonal rather than "what
      we needed for each test" which was really hard to understand.
      
      It turns out those occasional failures weren't spurious.  Next patch!
      a153d09b
  8. 10 Sep, 2010 3 commits