An error occurred fetching the project authors.
  1. 09 Apr, 2003 1 commit
  2. 04 Mar, 2003 1 commit
  3. 27 Jan, 2003 1 commit
  4. 17 Jan, 2003 1 commit
    • Jeremy Hylton's avatar
      Change handling of tpc_abort() during disconnection. · b3667600
      Jeremy Hylton authored
      Fix likely bug where calling tpc_abort() after a client disconnected
      did not properly clear the client's internal state about the
      transaction.  The change means that tpc_abort() will never raise a
      ClientDisconnected error, even when disconnected.
      
      Added a new test that sort-of covers this case and deleted another
      that was testing, in part, that you did get a ClientDisconnected
      error.
      b3667600
  5. 15 Jan, 2003 2 commits
  6. 14 Jan, 2003 1 commit
    • Jeremy Hylton's avatar
      Prevent client from using stale cache data while connecting. · b25c2295
      Jeremy Hylton authored
      XXX Maybe there should be an option to allow this.
      
      A ZEO client can run in disconnected mode, using data from
      its cache, or in connected mode.  Several instance variables
      are related to whether the client is connected.
      
      _server: All method calls are invoked through the server
         stub.  When not connect, set to disconnected_stub an
         object that raises ClientDisconnected errors.
      
      _ready: A threading Event that is set only if _server
         is set to a real stub.
      
      _connection: The current zrpc connection or None.
      
      _connection is set as soon as a connection is established,
      but _server is set only after cache verification has finished
      and clients can safely use the server.  _pending_server holds
      a server stub while it is being verified.
      
      Before this change, a client could start using a connection before
      verification finished.  If verification took a long time, it could
      even commit a new transaction using a mixing of old and new data.
      b25c2295
  7. 09 Jan, 2003 1 commit
  8. 07 Jan, 2003 1 commit
  9. 03 Jan, 2003 1 commit
  10. 20 Dec, 2002 1 commit
  11. 16 Dec, 2002 1 commit
  12. 12 Dec, 2002 1 commit
  13. 04 Nov, 2002 1 commit
  14. 31 Oct, 2002 1 commit
  15. 30 Oct, 2002 1 commit
    • Guido van Rossum's avatar
      Fixed a few docstrings that were out of date. · 3cd508c3
      Guido van Rossum authored
      Added a new test: checkMultiStorageTransaction().  This tests for the
      deadlocks that we've seen when multiple appservers do transactions
      involving multiple ZEO 2.0 storages.  It also nicely tests the timeout
      feature that Jeremy added to StorageServer.
      
      WARNING: with the current ZEO code, this occasionally hangs.  That's
      the point of this test. :-)
      3cd508c3
  16. 05 Oct, 2002 1 commit
  17. 03 Oct, 2002 1 commit
  18. 01 Oct, 2002 3 commits
  19. 30 Sep, 2002 1 commit
  20. 29 Sep, 2002 1 commit
  21. 26 Sep, 2002 2 commits
  22. 20 Sep, 2002 1 commit
    • Guido van Rossum's avatar
      I set out making wait=1 work for fallback connections, i.e. the · 24afe7ac
      Guido van Rossum authored
      ClientStorage constructor called with both wait=1 and
      read_only_fallback=1 should return, indicating its readiness, when a
      read-only connection was made.  This is done by calling
      connect(sync=1).  Previously this waited for the ConnectThread to
      finish, but that thread doesn't finish until it's made a read-write
      connection, so a different mechanism is needed.
      
      I ended up doing a major overhaul of the interfaces between
      ClientStorage, ConnectionManager, ConnectThread/ConnectWrapper, and
      even ManagedConnection.  Changes:
      
      ClientStorage.py:
      
        ClientStorage:
      
        - testConnection() now returns just the preferred flag; stubs are
          cheap and I like to have the notifyConnected() signature be the
          same for clients and servers.
      
        - notifyConnected() now takes a connection (to match the signature
          of this method in StorageServer), and creates a new stub.  It also
          takes care of the reconnect business if the client was already
          connected, rather than the ClientManager.  It stores the
          connection as self._connection so it can close the previous one.
          This is also reset by notifyDisconnected().
      
      zrpc/client.py:
      
        ConnectionManager:
      
        - Changed self.thread_lock into a condition variable.  It now also
          protects self.connection.  The condition is notified when
          self.connection is set to a non-None value in connect_done();
          connect(sync=1) waits for it.  The self.connected variable is no
          more; we test "self.connection is not None" instead.
      
        - Tried to made close() reentrant.  (There's a trick: you can't set
          self.connection to None, conn.close() ends up calling close_conn()
          which does this.)
      
        - Renamed notify_closed() to close_conn(), for symmetry with the
          StorageServer API.
      
        - Added an is_connected() method so ConnectThread.try_connect()
          doesn't have to dig inside the manager's guts to find out if the
          manager is connected (important for the disposition of fallback
          wrappers).
      
        ConnectThread and ConnectWrapper:
      
        - Follow above changes in the ClientStorage and ConnectionManager
          APIs: don't close the manager's connection when reconnecting, but
          leave that up to notifyConnected(); ConnectWrapper no longer
          manages the stub.
      
        - ConnectWrapper sets self.sock to None once it's created a
          ManagedConnection -- from there on the connection is is charge of
          closing the socket.
      
      zrpc/connection.py:
      
        ManagedServerConnection:
      
        - Changed the order in which close() calls things; super_close()
          should be last.
      
        ManagedConnection:
      
        - Ditto, and call the manager's close_conn() instead of
          notify_closed().
      
      tests/testZEO.py:
      
        - In checkReconnectSwitch(), we can now open the client storage with
          wait=1 and read_only_fallback=1.
      24afe7ac
  23. 19 Sep, 2002 1 commit
  24. 17 Sep, 2002 8 commits
  25. 15 Sep, 2002 1 commit
    • Guido van Rossum's avatar
      Fix argument passing to the storage factory in winserver. · 207efabe
      Guido van Rossum authored
      This code used to assume that all arguments were strings.
      It was always wrong (create was passed as '0' or '1' rather
      than as 0 or 1) but this was somehow masked.  When I added
      readonly, things broke.  The solution is that winserver.py
      ha a convention that an argument starting with '=' is
      evaluated as an expression, and _startserver in testZEO's
      WindowsConnectionText uses this for the create and readonly
      args.
      207efabe
  26. 13 Sep, 2002 1 commit
    • Guido van Rossum's avatar
      Import Disconnected from the correct module. · 8b3a867c
      Guido van Rossum authored
      Add a LOG call to ConnectionTests.setUp().
      
      Add tests for the ClientStorage read_only and read_only_fallback
      features.  Note that the latter feature is not completely working yet;
      the reconnect feature doesn't work, so it's of questionable value for
      now (though it *does* connect to a read-only storage whe no read-write
      storage is available).
      8b3a867c
  27. 12 Sep, 2002 3 commits