lp:~axwalk/juju-core/lp1176740-destroy-unit-short-circuit

Created by Andrew Wilkins and last modified
Get this branch:
bzr branch lp:~axwalk/juju-core/lp1176740-destroy-unit-short-circuit
Only Andrew Wilkins can upload to this branch. If you are Andrew Wilkins please log in for upload directions.

Branch merges

Related bugs

Related blueprints

Branch information

Owner:
Andrew Wilkins
Project:
juju-core
Status:
Development

Recent revisions

1605. By Andrew Wilkins

destroy-unit: respond to dying state in hook-failure

If the user invokes destroy-unit while a unit
is in a hook-error state, the uniter should
respond to the dying state as if it were in
steady state.

If the unit hasn't started yet (e.g. the install
hook failed), then the uniter should short-circuit
the termination handling.

1604. By Andrew Wilkins

[r=axwalk],[bug=1121914] cmd/juju: confirm destroy-environment

Fixes bug 1121914

https://codereview.appspot.com/12158043/

1603. By Sidnei da Silva

[r=sidnei],[bug=1203816] Fetch apt proxy config via host apt-config

Since we're passing custom userdata to the ubuntu-cloud lxc template, it ends
up not setting the apt_mirror to the MIRROR setting. Read apt proxy
configuration from the container's host instead via the apt-config command and
inject that into the container via apt_proxy cloud init setting for the http
proxy plus a runcmd that writes /etc/apt/apt.conf.d/99proxy-extra with the
same config as the host for the remaing settings not supported explicitly by
cloud-init at the moment.

https://codereview.appspot.com/12143043/

R=dimitern, rogpeppe, smoser

1602. By Dimiter Naydenov

[r=dimitern] apiserver: common AgentEntityWatcher mixin

Last step of Machiner API refactoring - extracted
the Watch method as a reusable AgentEntityWatcher
mixin and changed the machiner to use it. It will
be used by the upcoming Uniter API as well.

https://codereview.appspot.com/12464043/

R=gz, rogpeppe

1601. By Dimiter Naydenov

[r=dimitern] apiserver/common: DeadEnsurer + Machiner use it

Next step of extracing common API code, used by
the machiner and will be used by the uniter.
This introduces DeadEnsurer for entities with
EnsureDead method.

https://codereview.appspot.com/12461043/

R=gz, rogpeppe

1600. By Dimiter Naydenov

[r=dimitern] apiserver: StatusSetter common mixin

Extracted SetStatus handling from Machiner and created
a StatusSetter mixin in apiserver/common, using the
same model as for Remover and PasswordChanger. Also
refactored the Machiner facade to use it.

As a drive-by fix changed several test packages to
import gocheck aliased as "gc".

This is the first of several steps to extract common
API code from the machiner, so it can be used by the
upcoming Uniter facade.

https://codereview.appspot.com/12443044/

R=gz, rogpeppe

1599. By Jeroen T. Vermeulen

[r=jtv] uery Azure storage account key from Azure.

As per the planned phasing of the Azure provider, the environment's config
must currently still specify a key for the environment's Azure storage
account. The key is available from Azure itself, and here we replace the
configuration item with an automated query.

The query is performed on demand, and the result cached in a new field on
azureEnviron called storageAccountKey. I had wanted to query it immediately
when an azureEnviron is created, but that introduced an unexpected Azure
request in dozens of tests — some of which already routed such requests to a
fake http service but now needed an exta canned response inserted in the right
place (not always easy), and others needed extra code to create such a fake in
the first place. Not pleasant, so instead I went with on-demand querying, and
an update to makeEnviron() which ensures that this query is not needed by
default.

There were some complications with locking. Go's execution model does not
enable the conventional rule where a lock's current owner can grab the lock
again without deadlocking. This made it hard to get a handle on the Azure
management API from within a critical section, because locking is involved on
the lowest level. I used a well-known optimistic technique to get around
that, and it also lets us avoid a long-held lock while the Azure query is
underway.

1598. By Sidnei da Silva

[r=sidnei] Move addFile, addScripts to cloudinit.Config

Those were buried down into environs/cloudinit.go, and they will be useful
elsewhere for an upcoming branch of mine. Also changed usage of chmod to
'install -m', so the file is created with the correct mode first, and then
written to, which increases security a teensy bit.

https://codereview.appspot.com/12352043/

R=dimitern, natefinch

1597. By Julian Edwards

[r=julian-edwards] In the Azure provider, ensure that an absence of a storage container when doing a List() is interpreted as "no files" rather than a fatal error.

1596. By Andrew Wilkins

[r=axwalk],[bug=1027876] Support juju debug-hooks

This implementation is a departure from pyjuju, as we do not
have Zookeeper's ephemeral nodes to rely upon for locking.

The approach taken is described here:
  https://bugs.launchpad.net/juju-core/+bug/1027876/comments/11

Rather than periodically checking tmux, I've just gone for
a simple approach of calling "tmux has-session" each time a
hook is to be executed. If this proves to be too expensive,
then reassess.

https://codereview.appspot.com/12019043/

Branch metadata

Branch format:
Branch format 7
Repository format:
Bazaar repository format 2a (needs bzr 1.16 or later)
Stacked on:
lp:~go-bot/juju-core/trunk
This branch contains Public information 
Everyone can see this information.

Subscribers