You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by to...@apache.org on 2014/02/03 16:06:35 UTC

[1/3] git commit: Fix a typo.

Updated Branches:
  refs/heads/trunk 005b79518 -> 71aff983c


Fix a typo.


Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/cf1930cf
Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/cf1930cf
Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/cf1930cf

Branch: refs/heads/trunk
Commit: cf1930cf8c78260fbb70d6bd239e6bb5a38bfdb6
Parents: 005b795
Author: Tomaz Muraus <to...@apache.org>
Authored: Mon Feb 3 15:43:30 2014 +0100
Committer: Tomaz Muraus <to...@apache.org>
Committed: Mon Feb 3 15:43:30 2014 +0100

----------------------------------------------------------------------
 libcloud/common/cloudsigma.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/libcloud/blob/cf1930cf/libcloud/common/cloudsigma.py
----------------------------------------------------------------------
diff --git a/libcloud/common/cloudsigma.py b/libcloud/common/cloudsigma.py
index e0e6336..c65535c 100644
--- a/libcloud/common/cloudsigma.py
+++ b/libcloud/common/cloudsigma.py
@@ -47,7 +47,7 @@ API_ENDPOINTS_2_0 = {
         'host': 'lvs.cloudsigma.com'
     },
     'wdc': {
-        'name': 'Las Vegas',
+        'name': 'Washington DC',
         'country': 'United States',
         'host': 'wdc.cloudsigma.com'
     }


[2/3] git commit: LIBCLOUD-509: Add extra dictionary to the NodeSize object within the base compute API. This will allow additional properties specific to providers to be stored within the object. The GCE driver was updated and the addition of the # of C

Posted by to...@apache.org.
LIBCLOUD-509: Add extra dictionary to the NodeSize object within the base compute API. This will allow additional properties specific to providers to be stored within the object. The GCE driver was updated and the addition of the # of CPUs was added into the CloudStack driver.

Signed-off-by: Tomaz Muraus <to...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/bee946e2
Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/bee946e2
Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/bee946e2

Branch: refs/heads/trunk
Commit: bee946e28f0f7d79bc30f283ac1c6180adf5d230
Parents: cf1930c
Author: Chris DeRamus <ch...@divvycloud.com>
Authored: Sun Feb 2 13:44:53 2014 -0500
Committer: Tomaz Muraus <to...@apache.org>
Committed: Mon Feb 3 15:53:33 2014 +0100

----------------------------------------------------------------------
 libcloud/compute/base.py               | 8 +++++++-
 libcloud/compute/drivers/cloudstack.py | 3 ++-
 libcloud/compute/drivers/gce.py        | 2 +-
 3 files changed, 10 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/libcloud/blob/bee946e2/libcloud/compute/base.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/base.py b/libcloud/compute/base.py
index 5e09650..46cdefe 100644
--- a/libcloud/compute/base.py
+++ b/libcloud/compute/base.py
@@ -272,7 +272,8 @@ class NodeSize(UuidMixin):
     4
     """
 
-    def __init__(self, id, name, ram, disk, bandwidth, price, driver):
+    def __init__(self, id, name, ram, disk, bandwidth, price,
+                 driver, extra=None):
         """
         :param id: Size ID.
         :type id: ``str``
@@ -294,6 +295,10 @@ class NodeSize(UuidMixin):
 
         :param driver: Driver this image belongs to.
         :type driver: :class:`.NodeDriver`
+
+        :param extra: Optional provider specific attributes associated with
+                      this node.
+        :type  extra: ``dict``
         """
         self.id = str(id)
         self.name = name
@@ -302,6 +307,7 @@ class NodeSize(UuidMixin):
         self.bandwidth = bandwidth
         self.price = price
         self.driver = driver
+        self.extra = extra or {}
         UuidMixin.__init__(self)
 
     def __repr__(self):

http://git-wip-us.apache.org/repos/asf/libcloud/blob/bee946e2/libcloud/compute/drivers/cloudstack.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/drivers/cloudstack.py b/libcloud/compute/drivers/cloudstack.py
index f7e1847..a48ce81 100644
--- a/libcloud/compute/drivers/cloudstack.py
+++ b/libcloud/compute/drivers/cloudstack.py
@@ -589,8 +589,9 @@ class CloudStackNodeDriver(CloudStackDriverMixIn, NodeDriver):
                                  method='GET')
         sizes = []
         for sz in szs['serviceoffering']:
+            extra = {'cpu': sz['cpunumber']}
             sizes.append(NodeSize(sz['id'], sz['name'], sz['memory'], 0, 0,
-                                  0, self))
+                                  0, self, extra=extra))
         return sizes
 
     def create_node(self, **kwargs):

http://git-wip-us.apache.org/repos/asf/libcloud/blob/bee946e2/libcloud/compute/drivers/gce.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/drivers/gce.py b/libcloud/compute/drivers/gce.py
index 84bf7a2..69dfb44 100644
--- a/libcloud/compute/drivers/gce.py
+++ b/libcloud/compute/drivers/gce.py
@@ -259,7 +259,7 @@ class GCENodeSize(NodeSize):
                  extra=None):
         self.extra = extra
         super(GCENodeSize, self).__init__(id, name, ram, disk, bandwidth,
-                                          price, driver)
+                                          price, driver, extra=extra)
 
 
 class GCEProject(UuidMixin):


[3/3] git commit: image -> size and updated docstrings

Posted by to...@apache.org.
image -> size and updated docstrings

Signed-off-by: Tomaz Muraus <to...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/libcloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/libcloud/commit/71aff983
Tree: http://git-wip-us.apache.org/repos/asf/libcloud/tree/71aff983
Diff: http://git-wip-us.apache.org/repos/asf/libcloud/diff/71aff983

Branch: refs/heads/trunk
Commit: 71aff983c40a80f12f42bba5d2e59166743327b4
Parents: bee946e
Author: Chris DeRamus <ch...@divvycloud.com>
Authored: Sun Feb 2 15:50:31 2014 -0500
Committer: Tomaz Muraus <to...@apache.org>
Committed: Mon Feb 3 15:53:33 2014 +0100

----------------------------------------------------------------------
 libcloud/compute/base.py | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/libcloud/blob/71aff983/libcloud/compute/base.py
----------------------------------------------------------------------
diff --git a/libcloud/compute/base.py b/libcloud/compute/base.py
index 46cdefe..e901f34 100644
--- a/libcloud/compute/base.py
+++ b/libcloud/compute/base.py
@@ -276,28 +276,28 @@ class NodeSize(UuidMixin):
                  driver, extra=None):
         """
         :param id: Size ID.
-        :type id: ``str``
+        :type  id: ``str``
 
         :param name: Size name.
-        :type name: ``str``
+        :type  name: ``str``
 
         :param ram: Amount of memory (in MB) provided by this size.
-        :type ram: ``int``
+        :type  ram: ``int``
 
         :param disk: Amount of disk storage (in GB) provided by this image.
-        :type disk: ``int``
+        :type  disk: ``int``
 
         :param bandwidth: Amount of bandiwdth included with this size.
-        :type bandwidth: ``int``
+        :type  bandwidth: ``int``
 
         :param price: Price (in US dollars) of running this node for an hour.
-        :type price: ``float``
+        :type  price: ``float``
 
-        :param driver: Driver this image belongs to.
-        :type driver: :class:`.NodeDriver`
+        :param driver: Driver this size belongs to.
+        :type  driver: :class:`.NodeDriver`
 
         :param extra: Optional provider specific attributes associated with
-                      this node.
+                      this size.
         :type  extra: ``dict``
         """
         self.id = str(id)