Skip to content
Snippets Groups Projects
  1. Feb 21, 2012
  2. Aug 30, 2011
  3. Aug 25, 2011
  4. Aug 18, 2010
    • Manuel Franceschini's avatar
      Introduce new IPAddress classes · 8b312c1d
      Manuel Franceschini authored
      
      This patch unifies the netutils functions dealing with IP addresses to
      three classes:
      - IPAddress: Common IP address functionality
      - IPv4Address: IPv4 specific functionality
      - IPv6address: IPv6-specific functionality
      
      Furthermore it adds methods to check whether an address is a loopback
      address, replacing the .startswith("127") for IPv4 and adding IPv6
      support.
      
      It also provides the basis for future IPv6 address handling. Methods to
      convert IP strings to their corresponding interger values will allow to
      canonicalize IPv6 addresses.
      
      Signed-off-by: default avatarManuel Franceschini <livewire@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      8b312c1d
  5. Jul 12, 2010
    • Manuel Franceschini's avatar
      Confd IPv6 support · d8bcfe21
      Manuel Franceschini authored
      
      This patch series basically adds a new parameter 'family' to the constructors
      of daemon.AsyncUDPSocket and confd.client.ConfdUDPClient. This enables the
      users of these two classes to support IPv6.
      
      In ganeti-confd.ConfdAsyncUDPClient a method to check the address families of
      all peers is added.
      
      Furthermore it adds unittests for the added functionality.
      
      Signed-off-by: default avatarManuel Franceschini <livewire@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      d8bcfe21
  6. Jul 09, 2010
  7. Apr 21, 2010
  8. Apr 09, 2010
  9. Apr 08, 2010
    • Iustin Pop's avatar
      Add a new confd callback (StoreResultCallback) · aa2efc52
      Iustin Pop authored
      
      This new callback simply stores (without calling any lower-level
      callback) the last result; coupled with the filtering callback, this
      ensures that it has the 'best' response after all have been received.
      
      The result can then be retrieved via the GetResponse method.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      aa2efc52
    • Iustin Pop's avatar
      ConfdClient: add synchronous wait for replies mode · bfbbc223
      Iustin Pop authored
      
      Currently, there is no way for a user of the confd client library to
      know how many replies there should be, whether all have been received,
      etc. This is bad since we can't reliably detect the consistency of the
      results.
      
      This patch attempts to fix this by adding a synchronous WaitForReply
      function that will wait until either a timeout expires, or until a
      minimum number of replies have been received (interested users should
      add similar functionality for the async case). The callback
      functionality will still do call-backs into the user-provided code
      during the wait, but after this function has returned, we know that we
      received all possible replies.
      
      Note: To account for the interval between initial send of the request,
      and calling of this function, we modify the expiration time of the
      request.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      bfbbc223
    • Iustin Pop's avatar
      ConfdClient: unify some internal variables · 71e114da
      Iustin Pop authored
      
      Currently the requests are tracked in _request and in _expire_requests.
      This is conventient, but it restricts the ability to extend the request
      tracking, e.g. via packet stats and/or extension of expiration time.
      
      This patch introduces a new simple class _Request that holds all
      properties of pending requests; it then uses instances of this class as
      values in _request instead of tuples, and removes the _expire_requests.
      
      The only drawback is the change in behaviour of _ExpireRequests:
      previously, it used to scan the list only up to the first non-expired
      request, after which it aborted. Now it will scan the entire dict, which
      (depending on workload) could change the time behaviour. I don't think
      this is a problem, as:
      - deleting from the head of a list is very expensive (list.pop(0);
        list.append() is an order of magnitude more expensive than deleting
        an element from a dictionary and re-adding it)
      - we should have more than tens or hundreds of pending requests; in case
        this assumption changes, we could introduce a no-more-often-than-X
        expiration policy, etc.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      71e114da
  10. Apr 07, 2010
  11. Apr 06, 2010
  12. Mar 18, 2010
  13. Jan 14, 2010
  14. Jan 04, 2010
  15. Nov 06, 2009
    • Iustin Pop's avatar
      Fix pylint 'E' (error) codes · 6c881c52
      Iustin Pop authored
      
      This patch adds some silences and tweaks the code slightly so that
      “pylint --rcfile pylintrc -e ganeti” doesn't give any errors.
      
      The biggest change is in jqueue.py, the move of _RequireOpenQueue out of
      the JobQueue class. Since that is actually a function and not a method
      (never used as such) this makes sense, and also silences two pylint
      errors.
      
      Another real code change is in utils.py, where FieldSet.Matches will
      return None instead of False for failure; this still works with the way
      this class/method is used, and makes more sense (it resembles more
      closely the re.match return values).
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      6c881c52
  16. Oct 12, 2009
  17. Sep 29, 2009
  18. Sep 28, 2009
  19. Sep 25, 2009
  20. Sep 24, 2009
  21. Sep 23, 2009
  22. Sep 16, 2009
Loading