1. 12 Dec, 2002 11 commits
    • Barry Warsaw's avatar
      Remove the direct rebinding of asyncore.loop to this module's loop() · a42b2dd2
      Barry Warsaw authored
      function.  This was a nasty decoy (am I using that term correctly?
      :).
      
      Because we're worried about backward compatibility, for now we'll
      rebind asyncore.loop() to a function that prints a warning and then
      calls loop().  Eventually we'll take this away so you have to call
      ThreadedAsync.loop() explicitly.
      a42b2dd2
    • Barry Warsaw's avatar
      loop_forever(): Use ThreadedAsync.loop() explicitly, instead of · c5e9f28d
      Barry Warsaw authored
      through the sneakily rebound asyncore.loop().
      c5e9f28d
    • Barry Warsaw's avatar
      Since the Unix and Windows tests share a common infrastructure now, · 87699fc9
      Barry Warsaw authored
      rename UnixTests to FileStorageTests, and add a simple BDBTests class
      to use Berkeley Full storage.
      
      Rewrite to use the new forker module api.
      
      WindowsTests: Removed.
      87699fc9
    • Barry Warsaw's avatar
      Since the Unix and Windows tests share a common infrastructure now, · 7468a492
      Barry Warsaw authored
      rename UnixConnectionTests to FileStorageConnectionTests, and add a
      simple BDBConnectionTests class to use Berkeley Full storage.
      
      WindowsConnectionTests: Removed.
      7468a492
    • Barry Warsaw's avatar
      Substantial rewrite to use the new forker module api. · d568a947
      Barry Warsaw authored
      DummyDB.invalidate(): Add **kws since some of the tests try to use
      keyword arguments.
      
      Removed redundant keyword arguments from various openClientStorage()
      calls.
      d568a947
    • Barry Warsaw's avatar
    • Barry Warsaw's avatar
      Since both the Windows and Unix ZEO tests share the same code, it · eac692f6
      Barry Warsaw authored
      makes little sense to call the server script `winserver.py'.  That's
      gone now, in favor of this zeoserver.py script.  Changes include:
      
      main(): Accept a -C option pointing to a temp file containing a
      ZConfig storage section.  This reads the file and creates the so
      described storage, then removes the temp config file.  It creates an
      administrative server which opens an `admin' port which is used to
      os._exit() this process, with the following protocol.  The first time
      the admin port is connected to, an ack character is sent from
      zeoserver.  This is necessary to coordinate the tests so that they are
      assured the server is running and responding before it tries to do
      more.  Otherwise, some tests were vulnerable to timing bugs where the
      shutdown connect happened before the server was ready to accept them.
      
      The second connect exits the server process just like before.  Copious
      log entries are written.
      
      This script also cleans up after the storages are closed, by calling
      the storage's .cleanup() method if it exists (FileStorage and the
      Berkeley storages both implement this method).
      eac692f6
    • Jeremy Hylton's avatar
      35d1e1c0
    • Barry Warsaw's avatar
      Get rid of the differences between forking off the zeo server for NT · bc0fdca4
      Barry Warsaw authored
      and Unix.  We actually use the Windows code as the basis for the new
      approach so there's some hope that this will actually work on Windows
      <wink>.  Tim will verify once the checkins are finished.
      
      start_zeo_server(): Is now the blessed way of starting a ZEO server,
      and it primarily takes a ZConfig storage section string as its
      argument.  This it writes to a temp file and passes -C to the
      zeoserver.py script, which parses that temp file and creates the
      underlying storage.  zeoserver.py is responsible for deleting the temp
      file.
      
      zeoserver opens an `admin' port which is used to quit the server, but
      the protocol has been expanded slightly.  The first time the admin
      port is connected to, an ack character is sent from zeoserver.  This
      is necessary to coordinate the tests so that they are assured the
      server is running and responding before it tries to do more.
      Otherwise, some tests were vulnerable to timing bugs where the
      shutdown connect happened before the server was ready to accept them.
      
      The second connect exits the server process just like before.
      
      start_zeo_server() returns a 3-tuple.  The first element is the
      (host,port) tuple of the ZEO server, the second is the (host,port)
      tuple of the admin socket, and the third is the pid of the spawned
      child process.
      
      shutdown_zeo_server(): The blessed way to shut down a zeoserver.py
      process.  Takes an admin (host,port) tuple, connects to that and
      writes a log entry.
      bc0fdca4
    • Jeremy Hylton's avatar
      Possible fix for ZClass problem with persistent_id(). · ea15fb62
      Jeremy Hylton authored
      The get_class() function will not find a class for a ZClass, but it
      shouldn't fail.  Fix this by making the class an output paramter got
      get_class() and returning 1/0 for success / failure.  A ZClass should
      succeed trivially because it is not an extension class.
      ea15fb62
    • Barry Warsaw's avatar
      main(): Use ThreadedAsync.loop() explicitly instead of the · 56d3270b
      Barry Warsaw authored
      asyncore.loop() which really isn't.
      56d3270b
  2. 10 Dec, 2002 8 commits
  3. 09 Dec, 2002 3 commits
  4. 06 Dec, 2002 10 commits
  5. 05 Dec, 2002 8 commits