Paul,
The node.id is consistent, so I'll keep creation the way it is. The libcloud
user would have to check periodically if the VM is done provisioning. The
only thing that concerns me is that they'd have no way of knowing that a
provision failed. It's not common for that to happen though, so it should
be fine.
I made new nodes returned by create_node() be in the PENDING state when the
provision command is sent. I guess the returned node would only be used to
keep track of which nodes the libcloud user is waiting to be provisioned.
The reboot works by blocking so I'm leaving it that way.
Destroy doesn't actually check if the node was successfully deleted. Should
I do that? It seems unnecessary and slows down the call, but it would be
good for error checking. Actually, rebooting doesn't check if the node is
back to "running" either.
The problem with rebooting and destroying is that if rebooting fails to shut
down the node, it will be stuck waiting for it to turn off. Same with
destroying a node. I can set a timeout. Would 30 seconds sound reasonable? 1
minute? This can be cause problems if the connection is very slow.
I don't know where to find the Eucapliptus driver. I don't see eucaliptus.py
in trunk. Can you send me a link? I'm not sure I understand how you want me
to implement custom URLs.
Your states are:
RUNNING = 0
REBOOTING = 1
TERMINATED = 2
PENDING = 3
UNKNOWN = 4
Our states are:
running
off
paused
unknown
The only state that matches directly is "running".
The only time an ECP node is "rebooting" is in the middle of a node.reboot()
call. So basically the only time a node will be left in the "rebooting"
state is when it fails to start after being shut down (shouldn't happen).
I don't think TERMINATED matches our off state. I'm guessing TERMINATED is
the state a node goes into while waiting to be deleted. In ECP this is such
a short period of time that we don't have a state for it. In the driver it
is set when deleting a node.
I mentioned abode how I'm using PENDING.
I'm not sure if I should let the driver return nodes in the "unknown" state.
That statue usually indicates that the node is in the middle of
transitioning from one state to another or the machine it's running on is
not responding. The driver currently doesn't do that, but I can add it if
you think it is necessary.
It would be nice if there was support for turning nodes on and off because I
can imagine we're not the only ones who have this feature.
I've submitted the patch to jira.
https://issues.apache.org/jira/secure/ManageAttachments.jspa?id=12463218
- Viktor
On Tue, Apr 27, 2010 at 8:04 PM, Paul Querna <[email protected]> wrote:
> On Tue, Apr 27, 2010 at 12:15 PM, Viktor Stanchev <[email protected]>
> wrote:
> > Paul,
> > I made all the changes to the ECP driver that were suggested. They are in
> > the attached patch. I tested it live and everything appears to work
>
> Seems like the patch didn't make it to the list, maybe attach it to jira
> again?
>
> Thanks,
>
> Paul
>