libcloud-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pque...@apache.org
Subject svn commit: r926950 - /incubator/libcloud/trunk/libcloud/drivers/softlayer.py
Date Wed, 24 Mar 2010 06:38:59 GMT
Author: pquerna
Date: Wed Mar 24 06:38:59 2010
New Revision: 926950

URL: http://svn.apache.org/viewvc?rev=926950&view=rev
Log:
dont' set node.state to a random int, at least set it to the correct type

Modified:
    incubator/libcloud/trunk/libcloud/drivers/softlayer.py

Modified: incubator/libcloud/trunk/libcloud/drivers/softlayer.py
URL: http://svn.apache.org/viewvc/incubator/libcloud/trunk/libcloud/drivers/softlayer.py?rev=926950&r1=926949&r2=926950&view=diff
==============================================================================
--- incubator/libcloud/trunk/libcloud/drivers/softlayer.py (original)
+++ incubator/libcloud/trunk/libcloud/drivers/softlayer.py Wed Mar 24 06:38:59 2010
@@ -19,7 +19,7 @@ Softlayer driver
 import xmlrpclib
 
 import libcloud
-from libcloud.types import Provider, InvalidCredsException
+from libcloud.types import Provider, InvalidCredsException, NodeState
 from libcloud.base import NodeDriver, Node, NodeLocation
 
 DATACENTERS = {
@@ -111,7 +111,8 @@ class SoftLayerNodeDriver(NodeDriver):
         return Node(
             id=host['id'],
             name=host['hostname'],
-            state=host['statusId'],
+            # TODO: figure out how to get the correct power state
+            state=NodeState.UNKNOWN,
             public_ip=host['primaryIpAddress'],
             private_ip=host['primaryBackendIpAddress'],
             driver=self



Mime
View raw message