Merge lp:~fwereade/pyjuju/block-legacy-constraints-usage into lp:~fwereade/pyjuju/shadow-trunk-1204
Proposed by
William Reade
Status: | Merged |
---|---|
Approved by: | William Reade |
Approved revision: | 518 |
Merged at revision: | 513 |
Proposed branch: | lp:~fwereade/pyjuju/block-legacy-constraints-usage |
Merge into: | lp:~fwereade/pyjuju/shadow-trunk-1204 |
Prerequisite: | lp:~fwereade/pyjuju/env-constraints |
Diff against target: |
125 lines (+54/-1) 5 files modified
juju/control/constraints_set.py (+4/-1) juju/control/deploy.py (+1/-0) juju/control/legacy.py (+15/-0) juju/control/tests/test_constraints_set.py (+13/-0) juju/control/tests/test_deploy.py (+21/-0) |
To merge this branch: | bzr merge lp:~fwereade/pyjuju/block-legacy-constraints-usage |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
William Reade | Pending | ||
Review via email: mp+99856@code.launchpad.net |
Description of the change
Block set-constraints, and deploy --constraints, in legacy deployments
To post a comment you must log in.
Reviewers: mp+99856_ code.launchpad. net,
Message:
Please take a look.
Description:
Block set-constraints, and deploy --constraints, in legacy deployments
https:/ /code.launchpad .net/~fwereade/ juju/block- legacy- constraints- usage/+ merge/99856
Requires: /code.launchpad .net/~fwereade/ juju/env- constraints/ +merge/ 99852
https:/
(do not edit description out of merge proposal)
Please review this at https:/ /codereview. appspot. com/5952045/
Affected files: constraints_ set.py deploy. py legacy. py tests/test_ constraints_ set.py tests/test_ deploy. py
A [revision details]
M juju/control/
M juju/control/
M juju/control/
M juju/control/
M juju/control/
Index: [revision details]
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision: <email address hidden>
+New revision: <email address hidden>
Index: juju/control/ constraints_ set.py constraints_ set.py' constraints_ set.py 2012-03-29 02:00:04 +0000 constraints_ set.py 2012-03-29 03:20:51 +0000
=== modified file 'juju/control/
--- juju/control/
+++ juju/control/
@@ -2,6 +2,7 @@
from twisted. internet. defer import inlineCallbacks
+from juju.control import legacy environment import EnvironmentStat eManager (options) environments, environment, options.service, constraints) environments, environment, options.service, constraints, options.log)
from juju.control.utils import get_environment
from juju.state.
from juju.state.service import ServiceStateManager
@@ -35,11 +36,13 @@
"""
environment = get_environment
return constraints_set(
- options.
options.
+ options.
+ options.
@inlineCallbacks set(env_ config, environment, service_name, set(env_ config, environment, service_name, constraint_strs, set.parse( constraint_ strs) check_constrain ts(client, constraint_strs) eManager( client) config_ state(env_ config, environment.name)
-def constraints_
constraint_strs):
+def constraints_
+ log):
"""
Machine constraints allow you to pick the hardware to which your
services
will be deployed. Examples:
@@ -86,6 +89,7 @@
constraints = constraint_
client = yield provider.connect()
try:
+ yield legacy.
esm = EnvironmentStat
yield esm.set_
if service_name is None:
Index: juju/control/ deploy. py deploy. py' deploy. py 2012-03-29 01:37:57 +0000 deploy. py 2012-03-29 03:20:51 +0000
=== modified file 'juju/control/
--- juju/control/
+++ juju/control/
@@ -138,6 +138,7 @@
client = yield provider.connect()
try: check_constrain ts(client, constraint_strs) check_environme nt(
client, provider. get_legacy_ config_ keys())
+ yield legacy.
yield legacy.
Index: juju/control/ legacy. py legacy. py' legacy. py 2012-03-28 19:48:24 +0000 legacy. py 2012-03-29 03:20:51 +0000 internet. defer import inlineCallbacks
=== modified file 'juju/control/
--- juju/control/
+++ juju/control/
@@ -1,8 +1,19 @@
+import logging
+import sys
+
from twisted.
from juju.errors import JujuError environment import Environm...
from juju.state.