Merge lp:~waigani/gomaasapi/faildeploy into lp:gomaasapi
| Status: | Merged |
|---|---|
| Approved by: | Ian Booth on 2015-06-02 |
| Approved revision: | 62 |
| Merge reported by: | Jesse Meek |
| Merged at revision: | not available |
| Proposed branch: | lp:~waigani/gomaasapi/faildeploy |
| Merge into: | lp:gomaasapi |
| Diff against target: |
66 lines (+30/-5) 2 files modified
enum.go (+26/-1) testservice.go (+4/-4) |
| To merge this branch: | bzr merge lp:~waigani/gomaasapi/faildeploy |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| juju hackers | 2015-06-02 | Pending | |
|
Review via email:
|
|||
Commit Message
Add missing node statuses, required to fix bug #1376246. There will be a follow up branch in juju-core which will use this commit to fix the bug.
Description of the Change
Add missing node statuses, required to fix bug #1376246. There will be a follow up branch in juju-core which will use this commit to fix the bug.
| Raphaël Badin (rvb) wrote : | # |
| Ian Booth (wallyworld) wrote : | # |
So in juju we are using the "deployment_status" API on the node to get it's status, which we assume is a string like "Deployed" or "Failed Deployment".
Will that work? I think that API is only on later MAAS's. So if we get a not implemented error, we jut ignore it.
| Raphaël Badin (rvb) wrote : | # |
> So in juju we are using the "deployment_status" API on the node to get it's status,
> which we assume is a string like "Deployed" or "Failed Deployment".
> Will that work? I think that API is only on later MAAS's. So if we get a not implemented
> error, we jut ignore it.
Right, this endpoint returns "Deployed", "Deploying", "Failed deployment", "Not in deployment".
The endpoint was added in revision 2633.

Fwiw, the 'status' field doesn't include the new statuses (for backward compatibility). To have access to the full ranges of 'in progress' statuses, use the 'substatus' field (the 'substatus' field was included in revision 3319).
Example: here is what a 'Deploying' node would look like:
{
"substatus" : 9,
"status": 6,
[...]
}