Skip to content
Snippets Groups Projects
  1. Apr 26, 2012
    • Michael Hanselmann's avatar
      errors: Add exception for RAPI testing utilities · 352e1a26
      Michael Hanselmann authored
      
      This exception is raised to abort before actually sending a LUXI call
      (there is no LUXI server involved in the test). The testing utilities
      catch the exception to report a success (i.e. the code didn't throw
      an exception before due to invalid types, etc.). To allow the exception
      to be thrown all the way to the test utilities, the HTTP server library
      must ignore it. Also some overly generic exception handling is removed
      from the RAPI request handler.
      
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      352e1a26
  2. Dec 08, 2011
  3. Oct 18, 2011
  4. Sep 20, 2011
    • Andrea Spadaccini's avatar
      Implementation of TLS-protected SPICE connections · b6267745
      Andrea Spadaccini authored
      
      Added support for TLS-protected SPICE connections:
      
      client/gnt_cluster.py, cli.py:
      * added three new parameters to renew-crypto (--new-spice-certificate,
        --spice-certificate, --spice-ca-certificate) and their validation.
      
      utils/x509.py:
      * changed GenerateSelfSignedSslCert so that now also returns the
        generated key and certificate;
      * added missing return value in the docstring of
        GenerateSelfSignedX509Cert.
      
      lib/bootstrap.py:
      * changed the signatures of the relevant functions and implemented
        certificates generation/writing.
      
      tools/cfupgrade:
      * changed GenerateClusterCrypto invocation to reflect the new signature;
      * added SPICE certificate names.
      
      lib/errors.py:
      * added the X509CertError class.
      
      lib/hypervisor/hv_kvm.py:
      * silenced pylint warning R0915
      
      Signed-off-by: default avatarAndrea Spadaccini <spadaccio@google.com>
      Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
      b6267745
  5. Aug 25, 2011
  6. Jul 26, 2011
  7. Apr 18, 2011
  8. Feb 15, 2011
  9. Jan 31, 2011
  10. Oct 28, 2010
  11. Oct 13, 2010
  12. 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
  13. Aug 17, 2010
  14. Jul 16, 2010
  15. Jul 07, 2010
  16. Jun 23, 2010
  17. May 21, 2010
  18. Dec 18, 2009
  19. Nov 06, 2009
  20. Nov 04, 2009
    • Iustin Pop's avatar
      Introduce a wrapper for hostname resolving · 104f4ca1
      Iustin Pop authored
      
      Currently a few of the LU's CheckPrereq use utils.HostInfo which raises
      a resolver error in case of failure. This is an exception from the
      standard that CheckPrereq should raise an OpPrereqError if the error is
      in the 'pre' phase (so that it can be retried).
      
      This patch adds a new error code (resolver_error) and a wrapper over
      utils.HostInfo that just converts the ResolverError into
      OpPrereqError(…, errors.ECODE_RESOLVER). It then uses this wrapper in
      cmdlib, bootstrap and some scripts.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
      104f4ca1
  21. Nov 02, 2009
  22. Sep 25, 2009
  23. Sep 16, 2009
  24. Aug 28, 2009
  25. Aug 27, 2009
  26. Aug 10, 2009
  27. Jul 29, 2009
  28. Jul 14, 2009
  29. Jun 15, 2009
    • Iustin Pop's avatar
      Remove old invalid-os related functionality · 8e70b181
      Iustin Pop authored
      
      We no longer need OS objects to be able to represent invalid OSes. This
      cleans up the code handling those cases.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      8e70b181
    • Iustin Pop's avatar
      Conver node_leave_cluster rpc to new style result · 0623d351
      Iustin Pop authored
      
      This patch converts this rpc call to the new style result, and also
      changes in the process the meaning of the QuitGanetiException's
      arguments and the node daemon rpc call exception handler.
      
      The problem with the exception handler is that we used a two-stage one,
      and the inner used to catch all exception (including this one), so in
      the logs we always had an exception logged, instead of the normal
      'leaving cluster message'. The patch also adds logging of the
      exception's arguments, so that we have a trail in the logs about the
      shutdown mode.
      
      The exception's arguments were reversed from the normal RPC results
      style. While it makes somewhat more sense for this exception, we change
      them such that they match the rpc result format.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      0623d351
  30. Feb 10, 2009
    • Guido Trotter's avatar
      Instance parameters: force typing · a5728081
      Guido Trotter authored
      We want all the hv/be parameters to have a known type, rather than a
      random mix of empty string, boolean values, and None, so we declare the
      type of each variable and we enforce/convert it.
      
      - Add some new constants for enforceable value types
      - Add new constants dicts HVS_PARAMETER_TYPES and BES_PARAMETER_TYPES
        holding not only the valid parameters but also their types
      - Drop the old HVS_PARAMETERS and BES_PARAMETERS constants and calculate
        the values from the type dict
      - Convert all the default parameters to a valid type value
      - Create a new ForceDictType utils function, to check/enforce a dict's
        element value types, with relevant unit tests
      - Drop a few custom functions to check/convert the BE param types in
        utils and cli, in favor of ForceDictType
      - Double-check the parameter types using ForceDictType in both scripts
        and LogicalUnits, when possible.
      
      As a bonus:
      - Remove some old commented-out code in gnt-instance
      - Remove some already fixed FIXME
      - Fix a bug which prevented VALUE_DEFAULT to be applied to BE parameters
        in SetInstanceParams because the value was checked for validity before
        that transformation was made
      - Fix a bug which prevented initing a cluster and passing hvparams to
        work at all
      - ForceDictType allows an allowed_values for exceptions, which makes us
        able to do the checking even when some values must not be
        converted/typechecked (for example the 'default' string in
        SetInstanceParameters)
      
      Reviewed-by: iustinp
      a5728081
  31. Dec 17, 2008
    • Michael Hanselmann's avatar
      Add job queue size limit · f87b405e
      Michael Hanselmann authored
      A job queue with too many jobs can increase memory usage and/or make
      the master daemon slow. The current limit is just an arbitrary number.
      A "soft" limit for automatic job archival is prepared.
      
      Reviewed-by: iustinp
      f87b405e
  32. Dec 11, 2008
    • Iustin Pop's avatar
      Fix epydoc format warnings · c41eea6e
      Iustin Pop authored
      This patch should fix all outstanding epydoc parsing errors; as such, we
      switch epydoc into verbose mode so that any new errors will be visible.
      
      Reviewed-by: imsnah
      c41eea6e
  33. Oct 15, 2008
  34. Jul 11, 2008
    • Michael Hanselmann's avatar
      Add experimental persistency to job queue · f1da30e6
      Michael Hanselmann authored
      It's not perfect and it's not finished, but it's a start.
      
      - Serial number is read only once, but written on each update
      - Jobs are kept only on disk (caching will be implemented)
      
      Reviewed-by: iustinp
      f1da30e6
Loading