-
Notifications
You must be signed in to change notification settings - Fork 924
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Libcloud 469 add reserved instance support #205
Libcloud 469 add reserved instance support #205
Conversation
Pulling in latest updates
@@ -559,6 +559,22 @@ def __repr__(self): | |||
% (self.name, self.zone_state, self.region_name)) | |||
|
|||
|
|||
class ExEC2ReservedNode(object): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can drop the Ex
prefix. I know one class in EC2 driver uses it, but that's mostly an artifact from the past.
Nowadays we only use ex prefix for methods and arguments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This class could potentially inherit from Node
and you can then just pass None
for public_ips
and private_ips
argument, right?
Adding docstrings for attributes which are not already present on the Node class would also be good (just by looking at the constructor, I don't know what the type
attribute represents).
Updated EC2ReservedNode to use the extra_attribute_map to allow for easier modifications to the extra dictionary Updated tests to reflect the class changes
I went ahead and made the requested changes. To inherit from Node I also had to set the name argument to None as reserved instances do not have names or tags where we can pull the Name key/value pair. |
Thanks! The PR looks mostly good, but I've made some minor changes after merging the patch:
|
Ah, thanks for that and good call on the list_sizes. |
No description provided.