Uploaded image for project: 'Libcloud'
  1. Libcloud
  2. LIBCLOUD-180

Libcloud Driver to support Apache VCL Cloud software

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.9.1
    • Fix Version/s: 0.10.1
    • Component/s: Compute
    • Labels:
      None

      Description

      A libcloud driver that support Apache VCL software. I have a working driver ready to be integrated.

      1. vcldriver.patch
        74 kB
        Jason Gionta

        Activity

        Hide
        kami Tomaz Muraus added a comment -

        Hey,

        Thanks for the patch. I have committed it to trunk and made the following changes and fixes:

        • Removed "VCLException" class, because it doesn't provide any extra benefit over using an existing "LibcloudError" class.
        • Fixed a typo - 'drive' instead of 'driver'.
        • Fixed test/secret.py-dist file (missing 'secure' and correct 'host' argument)
        • Added 'driver' argument to the 'VCLProxy' constructor. This way we can pass this argument to LibcloudError when throwing an exception.
        • Fixed some style issues (single instead of double quotes).
        • Fixed mixed tabs and spaces and invalid indentation in the test file
        • Removed "not supported" exceptions. Base NodeDriver class already throws an exception if a method is not implemented
        • Removed unnecessary string interpolation - uri='%s' % (self.API).
        • Removed unnecessary 'self.type == Provider.VCL check'.
        • Removed unnecessary if in the constructor ('if host is not None'), because exception is already thrown if a host is not specified.
        • Removed the 'if host[:8] != 'https://'' check. 'host' argument must be an actual hostname (e.g. myapi.cloud.com) and not a URL.
        • removed 'user_agent' attribute from the 'VCLSafeTransport' and 'VLCProxy'" class, because it doesn't actually seem to be used.
        • changed 'verbose' argument in the 'VLCProxy' class to default to boolean False instead of int 0.
        • Changed the 'VLCProxy' class signature to look like this: (self, user, key, secure, host, port, driver, verbose=False). Now the 'host', 'port' and 'secure' arguments are used when building API url

        If you have any questions let us know.

        Show
        kami Tomaz Muraus added a comment - Hey, Thanks for the patch. I have committed it to trunk and made the following changes and fixes: Removed "VCLException" class, because it doesn't provide any extra benefit over using an existing "LibcloudError" class. Fixed a typo - 'drive' instead of 'driver'. Fixed test/secret.py-dist file (missing 'secure' and correct 'host' argument) Added 'driver' argument to the 'VCLProxy' constructor. This way we can pass this argument to LibcloudError when throwing an exception. Fixed some style issues (single instead of double quotes). Fixed mixed tabs and spaces and invalid indentation in the test file Removed "not supported" exceptions. Base NodeDriver class already throws an exception if a method is not implemented Removed unnecessary string interpolation - uri='%s' % (self.API). Removed unnecessary 'self.type == Provider.VCL check'. Removed unnecessary if in the constructor ('if host is not None'), because exception is already thrown if a host is not specified. Removed the 'if host [:8] != 'https://'' check. 'host' argument must be an actual hostname (e.g. myapi.cloud.com) and not a URL. removed 'user_agent' attribute from the 'VCLSafeTransport' and 'VLCProxy'" class, because it doesn't actually seem to be used. changed 'verbose' argument in the 'VLCProxy' class to default to boolean False instead of int 0. Changed the 'VLCProxy' class signature to look like this: (self, user, key, secure, host, port, driver, verbose=False). Now the 'host', 'port' and 'secure' arguments are used when building API url If you have any questions let us know.
        Hide
        the_palindrome Jason Gionta added a comment -

        Attached is the patch with new driver and tests

        Show
        the_palindrome Jason Gionta added a comment - Attached is the patch with new driver and tests
        Hide
        kami Tomaz Muraus added a comment -

        Hey, can you please attach the patch with the driver code and tests?

        Show
        kami Tomaz Muraus added a comment - Hey, can you please attach the patch with the driver code and tests?

          People

          • Assignee:
            kami Tomaz Muraus
            Reporter:
            the_palindrome Jason Gionta
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development