1. 13 4月, 2004 1 次提交
    • B
      Here's an attempt at new socket and signal code for win32. · a4c40f14
      Bruce Momjian 提交于
      It works on the principle of turning sockets into non-blocking, and then
      emulate blocking behaviour on top of that, while allowing signals to
      run. Signals are now implemented using an event instead of APCs, thus
      getting rid of the issue of APCs not being compatible with "old style"
      sockets functions.
      
      It also moves the win32 specific code away from pqsignal.h/c into
      port/win32, and also removes the "thread style workaround" of the APC
      issue previously in place.
      
      In order to make things work, a few things are also changed in pgstat.c:
      
      1) There is now a separate pipe to the collector and the bufferer. This
      is required because the pipe will otherwise only be signalled in one of
      the processes when the postmaster goes down. The MS winsock code for
      select() must have some kind of workaround for this behaviour, but I
      have found no stable way of doing that. You really are not supposed to
      use the same socket from more than one process (unless you use
      WSADuplicateSocket(), in which case the docs specifically say that only
      one will be flagged).
      
      2) The check for "postmaster death" is moved into a separate select()
      call after the main loop. The previous behaviour select():ed on the
      postmaster pipe, while later explicitly saying "we do NOT check for
      postmaster exit inside the loop".
      The issue was that the code relies on the same select() call seeing both
      the postmaster pipe *and* the pgstat pipe go away. This does not always
      happen, and it appears that useing WSAEventSelect() makes it even more
      common that it does not.
      Since it's only called when the process exits, I don't think using a
      separate select() call will have any significant impact on how the stats
      collector works.
      
      Magnus Hagander
      a4c40f14
  2. 24 3月, 2004 1 次提交
  3. 19 2月, 2004 1 次提交
  4. 10 2月, 2004 1 次提交
    • 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
  5. 09 2月, 2004 1 次提交
    • N
      Win32 signals cleanup. Patch by Magnus Hagander, with input from Claudio · f06e7952
      Neil Conway 提交于
      Natoli and Bruce Momjian (and some cosmetic fixes from Neil Conway).
      Changes:
      
          - remove duplicate signal definitions from pqsignal.h
      
          - replace pqkill() with kill() and redefine kill() in Win32
      
          - use ereport() in place of fprintf() in some error handling in
            pqsignal.c
      
          - export pg_queue_signal() and make use of it where necessary
      
          - add a console control handler for Ctrl-C and similar handling
            on Win32
      
          - do WaitForSingleObjectEx() in CHECK_FOR_INTERRUPTS() on Win32;
            query cancelling should now work on Win32
      
          - various other fixes and cleanups
      f06e7952
  6. 03 2月, 2004 1 次提交
  7. 27 1月, 2004 2 次提交
    • B
      Pgindent win32 signal code. · 70d58115
      Bruce Momjian 提交于
      70d58115
    • B
      Here's the latest win32 signals code, this time in the form of a patch · 50491963
      Bruce Momjian 提交于
      against the latest shapshot. It also includes the replacement of kill()
      with pqkill() and sigsetmask() with pqsigsetmask().
      
      Passes all tests fine on my linux machine once applied. Still doesn't
      link completely on Win32 - there are a few things still required. But
      much closer than before.
      
      At Bruce's request, I'm goint to write up a README file about the method
      of signals delivery chosen and why the others were rejected (basically a
      summary of the mailinglist discussions). I'll finish that up once/if the
      patch is accepted.
      
      
      Magnus Hagander
      50491963
  8. 25 12月, 2003 1 次提交
  9. 21 12月, 2003 1 次提交
  10. 19 12月, 2003 1 次提交
  11. 13 12月, 2003 1 次提交
  12. 05 12月, 2003 1 次提交
  13. 30 11月, 2003 1 次提交
    • P
      · 969685ad
      PostgreSQL Daemon 提交于
      $Header: -> $PostgreSQL Changes ...
      969685ad
  14. 25 10月, 2003 1 次提交
  15. 26 9月, 2003 1 次提交
  16. 25 9月, 2003 1 次提交
  17. 14 9月, 2003 1 次提交
  18. 13 9月, 2003 1 次提交
  19. 08 9月, 2003 1 次提交
  20. 07 9月, 2003 1 次提交
  21. 06 9月, 2003 2 次提交
  22. 05 9月, 2003 1 次提交
  23. 13 8月, 2003 2 次提交
  24. 08 8月, 2003 1 次提交
  25. 05 8月, 2003 1 次提交
  26. 04 8月, 2003 2 次提交
  27. 02 8月, 2003 3 次提交
  28. 28 7月, 2003 3 次提交
  29. 26 7月, 2003 2 次提交
    • B
      Have SSL text print only when SSL mode is enabled. · abc7f732
      Bruce Momjian 提交于
      abc7f732
    • B
      At long last I put together a patch to support 4 client SSL negotiation · 397831e1
      Bruce Momjian 提交于
      modes (and replace the requiressl boolean). The four options were first
      spelled out by Magnus Hagander <mha@sollentuna.net> on 2000-08-23 in email
      to pgsql-hackers, archived here:
      
      http://archives.postgresql.org/pgsql-hackers/2000-08/msg00639.php
      
      My original less-flexible patch and the ensuing thread are archived at:
      
      http://dbforums.com/t623845.html
      
      Attached is a new patch, including documentation.
      
      To sum up, there's a new client parameter "sslmode" and environment
      variable "PGSSLMODE", with these options:
      
      sslmode   description
      -------   -----------
      disable   Unencrypted non-SSL only
      allow     Negotiate, prefer non-SSL
      prefer    Negotiate, prefer SSL (default)
      require   Require SSL
      
      The only change to the server is a new pg_hba.conf line type,
      "hostnossl", for specifying connections that are not allowed to use SSL
      (for example, to prevent servers on a local network from accidentally
      using SSL and wasting cycles). Thus the 3 pg_hba.conf line types are:
      
      pg_hba.conf line types
      ----------------------
      host       applies to either SSL or regular connections
      hostssl    applies only to SSL connections
      hostnossl  applies only to regular connections
      
      These client and server options, the postgresql.conf ssl = false option,
      and finally the possibility of compiling with no SSL support at all,
      make quite a range of combinations to test. I threw together a test
      script to try many of them out. It's in a separate tarball with its
      config files, a patch to psql so it'll announce SSL connections even in
      absence of a tty, and the test output. The test is especially informative
      when run on the same tty the postmaster was started on, so the FATAL:
      errors during negotiation are interleaved with the psql client output.
      
      I saw Tom write that new submissions for 7.4 have to be in before midnight
      local time, and since I'm on the east coast in the US, this just makes it
      in before the bell. :)
      
      Jon Jensen
      397831e1
  30. 24 7月, 2003 2 次提交