1. 21 11月, 2005 1 次提交
  2. 15 10月, 2005 1 次提交
  3. 04 10月, 2005 1 次提交
  4. 23 9月, 2005 1 次提交
    • T
      Take exclusive buffer lock in scan_heap() to eliminate some corner cases · a453951d
      Tom Lane 提交于
      in which invalid page data could be transiently written to disk by
      concurrent bgwriter activity.  There doesn't seem any risk of loss of
      actual user data, but an empty page could possibly be left corrupt if a
      crash occurs before the correct data gets written out.  Pointed out by
      Alvaro Herrera.
      a453951d
  5. 03 9月, 2005 1 次提交
    • T
      Clean up a couple of ad-hoc computations of the maximum number of tuples · 35e9b1cc
      Tom Lane 提交于
      on a page, as suggested by ITAGAKI Takahiro.  Also, change a few places
      that were using some other estimates of max-items-per-page to consistently
      use MaxOffsetNumber.  This is conservatively large --- we could have used
      the new MaxHeapTuplesPerPage macro, or a similar one for index tuples ---
      but those places are simply declaring a fixed-size buffer and assuming it
      will work, rather than actively testing for overrun.  It seems safer to
      size these buffers in a way that can't overflow even if the page is
      corrupt.
      35e9b1cc
  6. 21 8月, 2005 1 次提交
    • T
      Convert the arithmetic for shared memory size calculation from 'int' · 0007490e
      Tom Lane 提交于
      to 'Size' (that is, size_t), and install overflow detection checks in it.
      This allows us to remove the former arbitrary restrictions on NBuffers
      etc.  It won't make any difference in a 32-bit machine, but in a 64-bit
      machine you could theoretically have terabytes of shared buffers.
      (How efficiently we could manage 'em remains to be seen.)  Similarly,
      num_temp_buffers, work_mem, and maintenance_work_mem can be set above
      2Gb on a 64-bit machine.  Original patch from Koichi Suzuki, additional
      work by moi.
      0007490e
  7. 30 7月, 2005 1 次提交
    • T
      Clean up a number of autovacuum loose ends. Make the stats collector · 5d5f1a79
      Tom Lane 提交于
      track shared relations in a separate hashtable, so that operations done
      from different databases are counted correctly.  Add proper support for
      anti-XID-wraparound vacuuming, even in databases that are never connected
      to and so have no stats entries.  Miscellaneous other bug fixes.
      Alvaro Herrera, some additional fixes by Tom Lane.
      5d5f1a79
  8. 14 7月, 2005 1 次提交
  9. 20 5月, 2005 1 次提交
  10. 08 5月, 2005 1 次提交
    • T
      Repair very-low-probability race condition between relation extension · 30f540be
      Tom Lane 提交于
      and VACUUM: in the interval between adding a new page to the relation
      and formatting it, it was possible for VACUUM to come along and decide
      it should format the page too.  Though not harmful in itself, this would
      cause data loss if a third transaction were able to insert tuples into
      the vacuumed page before the original extender got control back.
      30f540be
  11. 26 3月, 2005 1 次提交
  12. 21 3月, 2005 1 次提交
    • T
      Remove unnecessary calls of FlushRelationBuffers: there is no need · 354049c7
      Tom Lane 提交于
      to write out data that we are about to tell the filesystem to drop.
      smgr_internal_unlink already had a DropRelFileNodeBuffers call to
      get rid of dead buffers without a write after it's no longer possible
      to roll back the deleting transaction.  Adding a similar call in
      smgrtruncate simplifies callers and makes the overall division of
      labor clearer.  This patch removes the former behavior that VACUUM
      would write all dirty buffers of a relation unconditionally.
      354049c7
  13. 01 1月, 2005 1 次提交
    • P
      · 2ff50159
      PostgreSQL Daemon 提交于
      Tag appropriate files for rc3
      
      Also performed an initial run through of upgrading our Copyright date to
      extend to 2005 ... first run here was very simple ... change everything
      where: grep 1996-2004 && the word 'Copyright' ... scanned through the
      generated list with 'less' first, and after, to make sure that I only
      picked up the right entries ...
      2ff50159
  14. 02 12月, 2004 1 次提交
    • T
      Change planner to use the current true disk file size as its estimate of · 5374d097
      Tom Lane 提交于
      a relation's number of blocks, rather than the possibly-obsolete value
      in pg_class.relpages.  Scale the value in pg_class.reltuples correspondingly
      to arrive at a hopefully more accurate number of rows.  When pg_class
      contains 0/0, estimate a tuple width from the column datatypes and divide
      that into current file size to estimate number of rows.  This improved
      methodology allows us to jettison the ancient hacks that put bogus default
      values into pg_class when a table is first created.  Also, per a suggestion
      from Simon, make VACUUM (but not VACUUM FULL or ANALYZE) adjust the value
      it puts into pg_class.reltuples to try to represent the mean tuple density
      instead of the minimal density that actually prevails just after VACUUM.
      These changes alter the plans selected for certain regression tests, so
      update the expected files accordingly.  (I removed join_1.out because
      it's not clear if it still applies; we can add back any variant versions
      as they are shown to be needed.)
      5374d097
  15. 25 10月, 2004 1 次提交
  16. 16 10月, 2004 1 次提交
  17. 01 10月, 2004 1 次提交
  18. 29 8月, 2004 2 次提交
  19. 22 7月, 2004 1 次提交
    • T
      Invent WAL timelines, as per recent discussion, to make point-in-time · 2042b342
      Tom Lane 提交于
      recovery more manageable.  Also, undo recent change to add FILE_HEADER
      and WASTED_SPACE records to XLOG; instead make the XLOG page header
      variable-size with extra fields in the first page of an XLOG file.
      This should fix the boundary-case bugs observed by Mark Kirkwood.
      initdb forced due to change of XLOG representation.
      2042b342
  20. 06 6月, 2004 1 次提交
  21. 01 6月, 2004 1 次提交
    • T
      Minor code rationalization: FlushRelationBuffers just returns void, · e6747079
      Tom Lane 提交于
      rather than an error code, and does elog(ERROR) not elog(WARNING)
      when it detects a problem.  All callers were simply elog(ERROR)'ing on
      failure return anyway, and I find it hard to envision a caller that would
      not, so we may as well simplify the callers and produce the more useful
      error message directly.
      e6747079
  22. 09 5月, 2004 1 次提交
    • T
      Get rid of rd_nblocks field in relcache entries. Turns out this was · 4af34211
      Tom Lane 提交于
      costing us lots more to maintain than it was worth.  On shared tables
      it was of exactly zero benefit because we couldn't trust it to be
      up to date.  On temp tables it sometimes saved an lseek, but not often
      enough to be worth getting excited about.  And the real problem was that
      we forced an lseek on every relcache flush in order to update the field.
      So all in all it seems best to lose the complexity.
      4af34211
  23. 26 4月, 2004 1 次提交
  24. 12 2月, 2004 1 次提交
  25. 10 2月, 2004 2 次提交
    • T
      Centralize implementation of delay code by creating a pg_usleep() · 58f337a3
      Tom Lane 提交于
      subroutine in src/port/pgsleep.c.  Remove platform dependencies from
      miscadmin.h and put them in port.h where they belong.  Extend recent
      vacuum cost-based-delay patch to apply to VACUUM FULL, ANALYZE, and
      non-btree index vacuuming.
      
      By the way, where is the documentation for the cost-based-delay patch?
      58f337a3
    • T
      Restructure smgr API as per recent proposal. smgr no longer depends on · 87bd9563
      Tom Lane 提交于
      the relcache, and so the notion of 'blind write' is gone.  This should
      improve efficiency in bgwriter and background checkpoint processes.
      Internal restructuring in md.c to remove the not-very-useful array of
      MdfdVec objects --- might as well just use pointers.
      Also remove the long-dead 'persistent main memory' storage manager (mm.c),
      since it seems quite unlikely to ever get resurrected.
      87bd9563
  26. 07 2月, 2004 1 次提交
  27. 04 2月, 2004 1 次提交
    • T
      Rename SortMem and VacuumMem to work_mem and maintenance_work_mem. · 391c3811
      Tom Lane 提交于
      Make btree index creation and initial validation of foreign-key constraints
      use maintenance_work_mem rather than work_mem as their memory limit.
      Add some code to guc.c to allow these variables to be referenced by their
      old names in SHOW and SET commands, for backwards compatibility.
      391c3811
  28. 30 11月, 2003 1 次提交
    • P
      · 969685ad
      PostgreSQL Daemon 提交于
      $Header: -> $PostgreSQL Changes ...
      969685ad
  29. 25 9月, 2003 1 次提交
  30. 04 8月, 2003 2 次提交
  31. 21 7月, 2003 1 次提交
  32. 28 5月, 2003 1 次提交
  33. 05 3月, 2003 1 次提交
    • T
      Reimplement free-space-map management as per recent discussions. · 391eb5e5
      Tom Lane 提交于
      Adjustable threshold is gone in favor of keeping track of total requested
      page storage and doling out proportional fractions to each relation
      (with a minimum amount per relation, and some quantization of the results
      to avoid thrashing with small changes in page counts).  Provide special-
      case code for indexes so as not to waste space storing useless page
      free space counts.  Restructure internal data storage to be a flat array
      instead of list-of-chunks; this may cost a little more work in data
      copying when reorganizing, but allows binary search to be used during
      lookup_fsm_page_entry().
      391eb5e5
  34. 24 2月, 2003 2 次提交
  35. 22 2月, 2003 1 次提交
    • T
      More infrastructure for btree compaction project. Tree-traversal code · 799bc58d
      Tom Lane 提交于
      now knows what to do upon hitting a dead page (in theory anyway, it's
      untested...).  Add a post-VACUUM-cleanup entry point for index AMs, to
      provide a place for dead-page scavenging to happen.
      Also, fix oversight that broke btpo_prev links in temporary indexes.
      initdb forced due to additions in pg_am.
      799bc58d
  36. 13 11月, 2002 1 次提交